]>
Commit | Line | Data |
---|---|---|
b3c86150 VS |
1 | ///////////////////////////////////////////////////////////////////////////// |
2 | // Name: wx/dfb/font.h | |
3 | // Author: Vaclav Slavik | |
4 | // Purpose: wxFont declaration | |
5 | // Created: 2006-08-08 | |
6 | // RCS-ID: $Id$ | |
7 | // Copyright: (c) 2006 REA Elektronik GmbH | |
8 | // Licence: wxWindows licence | |
9 | ///////////////////////////////////////////////////////////////////////////// | |
10 | ||
11 | #ifndef _WX_DFB_FONT_H_ | |
12 | #define _WX_DFB_FONT_H_ | |
13 | ||
52c8d32a | 14 | #include "wx/dfb/dfbptr.h" |
b3c86150 VS |
15 | |
16 | wxDFB_DECLARE_INTERFACE(IDirectFBFont); | |
17 | ||
18 | // ---------------------------------------------------------------------------- | |
19 | // wxFont | |
20 | // ---------------------------------------------------------------------------- | |
21 | ||
22 | class WXDLLIMPEXP_CORE wxFont : public wxFontBase | |
23 | { | |
24 | public: | |
25 | wxFont() {} | |
26 | wxFont(const wxNativeFontInfo& info) { Create(info); } | |
27 | wxFont(int size, | |
28 | int family, | |
29 | int style, | |
30 | int weight, | |
31 | bool underlined = false, | |
32 | const wxString& face = wxEmptyString, | |
33 | wxFontEncoding encoding = wxFONTENCODING_DEFAULT) | |
34 | { | |
35 | Create(size, family, style, weight, underlined, face, encoding); | |
36 | } | |
37 | ||
38 | bool Create(int size, | |
39 | int family, | |
40 | int style, | |
41 | int weight, | |
42 | bool underlined = false, | |
43 | const wxString& face = wxEmptyString, | |
44 | wxFontEncoding encoding = wxFONTENCODING_DEFAULT); | |
45 | bool Create(const wxNativeFontInfo& fontinfo); | |
46 | ||
47 | // implement base class pure virtuals | |
48 | virtual int GetPointSize() const; | |
49 | virtual int GetFamily() const; | |
50 | virtual int GetStyle() const; | |
51 | virtual int GetWeight() const; | |
52 | virtual wxString GetFaceName() const; | |
53 | virtual bool GetUnderlined() const; | |
54 | virtual wxFontEncoding GetEncoding() const; | |
55 | virtual bool IsFixedWidth() const; | |
56 | virtual const wxNativeFontInfo *GetNativeFontInfo() const; | |
57 | ||
58 | virtual void SetPointSize(int pointSize); | |
59 | virtual void SetFamily(int family); | |
60 | virtual void SetStyle(int style); | |
61 | virtual void SetWeight(int weight); | |
62 | virtual bool SetFaceName(const wxString& faceName); | |
63 | virtual void SetUnderlined(bool underlined); | |
64 | virtual void SetEncoding(wxFontEncoding encoding); | |
65 | ||
66 | // implementation from now on: | |
52c8d32a | 67 | wxIDirectFBFontPtr GetDirectFBFont() const; |
b3c86150 VS |
68 | |
69 | protected: | |
70 | // ref counting code | |
71 | virtual wxObjectRefData *CreateRefData() const; | |
72 | virtual wxObjectRefData *CloneRefData(const wxObjectRefData *data) const; | |
73 | ||
74 | private: | |
75 | DECLARE_DYNAMIC_CLASS(wxFont) | |
76 | }; | |
77 | ||
78 | #endif // _WX_DFB_FONT_H_ |