]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/mac/carbon/font.h
f513354e3545b43a03066b7efee561ed6674e4b6
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxFont class
4 // Author: Julian Smart
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
15 // ----------------------------------------------------------------------------
17 // ----------------------------------------------------------------------------
19 class WXDLLEXPORT wxFont
: public wxFontBase
29 bool underlined
= FALSE
,
30 const wxString
& face
= wxEmptyString
,
31 wxFontEncoding encoding
= wxFONTENCODING_DEFAULT
)
33 (void)Create(size
, family
, style
, weight
, underlined
, face
, encoding
);
36 wxFont(const wxNativeFontInfo
& info
)
41 wxFont(const wxString
& fontDesc
);
47 bool underlined
= FALSE
,
48 const wxString
& face
= wxEmptyString
,
49 wxFontEncoding encoding
= wxFONTENCODING_DEFAULT
);
51 bool Create(const wxNativeFontInfo
& info
);
53 bool MacCreateThemeFont( wxUint16 themeFontID
) ;
57 // implement base class pure virtuals
58 virtual int GetPointSize() const;
59 virtual int GetFamily() const;
60 virtual int GetStyle() const;
61 virtual int GetWeight() const;
62 virtual bool GetUnderlined() const;
63 virtual wxString
GetFaceName() const;
64 virtual wxFontEncoding
GetEncoding() const;
65 virtual const wxNativeFontInfo
*GetNativeFontInfo() const;
67 virtual void SetPointSize(int pointSize
);
68 virtual void SetFamily(int family
);
69 virtual void SetStyle(int style
);
70 virtual void SetWeight(int weight
);
71 virtual void SetFaceName(const wxString
& faceName
);
72 virtual void SetUnderlined(bool underlined
);
73 virtual void SetEncoding(wxFontEncoding encoding
);
75 // implementation only from now on
76 // -------------------------------
78 virtual bool RealizeResource();
80 // Unofficial API, don't use
81 virtual void SetNoAntiAliasing( bool noAA
= TRUE
) ;
82 virtual bool GetNoAntiAliasing() const ;
84 // Mac-specific, risks to change, don't use in portable code
86 // 'old' Quickdraw accessors
88 short MacGetFontNum() const;
89 short MacGetFontSize() const;
90 wxByte
MacGetFontStyle() const;
92 // 'new' ATSUI accessors
94 wxUint32
MacGetATSUFontID() const;
95 wxUint32
MacGetATSUAdditionalQDStyles() const;
96 wxUint16
MacGetThemeFontID() const ;
97 // Returns an ATSUStyle not ATSUStyle*
98 void* MacGetATSUStyle() const ;
104 DECLARE_DYNAMIC_CLASS(wxFont
)