]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/mgl/private/fontmgr.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/mgl/private/fontmgr.h
3 // Purpose: font management for MGL
4 // Author: Vaclav Slavik
7 // Copyright: (c) 2001-2002 SciTech Software, Inc. (www.scitechsoft.com)
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
11 #ifndef _WX_MGL_PRIVATE_FONTMGR_H_
12 #define _WX_MGL_PRIVATE_FONTMGR_H_
18 class wxFontInstance
: public wxFontInstanceBase
21 wxFontInstance(float ptSize
, bool aa
, font_lib_t
*fontLib
);
22 virtual ~wxFontInstance();
24 struct font_t
*GetMGLfont_t() const { return m_font
; }
30 class wxFontFace
: public wxFontFaceBase
33 wxFontFace(const wxString
& filename
)
34 : m_fontLib(NULL
), m_fileName(filename
) {}
36 virtual void Acquire();
37 virtual void Release();
39 virtual wxFontInstance
*GetFontInstance(float ptSize
, bool aa
);
42 wxFontInstance
*CreateFontInstance(float ptSize
, bool aa
);
45 font_lib_t
*m_fontLib
;
49 class wxFontBundle
: public wxFontBundleBase
52 wxFontBundle(const font_info_t
*fontInfo
);
54 virtual wxString
GetName() const
55 { return wxString::FromAscii(m_fontInfo
->familyName
); }
57 virtual bool IsFixed() const { return m_fontInfo
->isFixed
; }
59 const font_info_t
*GetInfo() const { return m_fontInfo
; }
62 const font_info_t
*m_fontInfo
;
65 class wxFontsManager
: public wxFontsManagerBase
68 wxFontsManager() { AddAllFonts(); }
70 virtual wxString
GetDefaultFacename(wxFontFamily family
) const;
73 // adds all fonts using AddBundle()
77 #endif // _WX_MGL_PRIVATE_FONTMGR_H_