// accessors and modifiers for the font elements
int GetPointSize() const;
+#ifdef __WXMSW__
wxSize GetPixelSize() const;
+#endif
wxFontStyle GetStyle() const;
wxFontWeight GetWeight() const;
bool GetUnderlined() const;
wxFontEncoding GetEncoding() const;
void SetPointSize(int pointsize);
+#ifdef __WXMSW__
void SetPixelSize(const wxSize& pixelSize);
+#endif
void SetStyle(wxFontStyle style);
void SetWeight(wxFontWeight weight);
void SetUnderlined(bool underlined);
wxFontEncoding encoding=wxFONTENCODING_DEFAULT);
~wxFont();
- %name(FontFromNativeInfo) wxFont(const wxNativeFontInfo& info);
+ %RenameCtor(FontFromNativeInfo, wxFont(const wxNativeFontInfo& info));
%extend {
- %name(FontFromNativeInfoString) wxFont(const wxString& info) {
+ %RenameCtor(FontFromNativeInfoString, wxFont(const wxString& info))
+ {
wxNativeFontInfo nfi;
nfi.FromString(info);
return new wxFont(nfi);
}
- %name(Font2) wxFont(int pointSize,
- wxFontFamily family,
- int flags = wxFONTFLAG_DEFAULT,
- const wxString& face = wxPyEmptyString,
- wxFontEncoding encoding = wxFONTENCODING_DEFAULT) {
+ %RenameCtor(Font2, wxFont(int pointSize,
+ wxFontFamily family,
+ int flags = wxFONTFLAG_DEFAULT,
+ const wxString& face = wxPyEmptyString,
+ wxFontEncoding encoding = wxFONTENCODING_DEFAULT))
+ {
return wxFont::New(pointSize, family, flags, face, encoding);
}
}
// There is a real ctor for this on wxMSW, but not the others, so just use
// the factory funciton in all cases.
%extend {
- %name(FontFromPixelSize) wxFont(const wxSize& pixelSize,
- int family,
- int style,
- int weight,
- bool underlined = false,
- const wxString& face = wxEmptyString,
- wxFontEncoding encoding = wxFONTENCODING_DEFAULT) {
+ %RenameCtor(FontFromPixelSize, wxFont(const wxSize& pixelSize,
+ int family,
+ int style,
+ int weight,
+ bool underlined = false,
+ const wxString& face = wxEmptyString,
+ wxFontEncoding encoding = wxFONTENCODING_DEFAULT))
+ {
return wxFontBase::New(pixelSize, family,
style, weight, underlined,
face, encoding);
virtual void SetUnderlined( bool underlined );
virtual void SetEncoding(wxFontEncoding encoding);
void SetNativeFontInfo(const wxNativeFontInfo& info);
- %name(SetNativeFontInfoFromString) void SetNativeFontInfo(const wxString& info);
+ %Rename(SetNativeFontInfoFromString, void, SetNativeFontInfo(const wxString& info));
void SetNativeFontInfoUserDesc(const wxString& info);
// translate the fonts into human-readable string (i.e. GetStyleString()
MustHaveApp(wxPyFontEnumerator);
-%name(FontEnumerator) class wxPyFontEnumerator {
+%rename(FontEnumerator) wxPyFontEnumerator;
+class wxPyFontEnumerator {
public:
%pythonAppend wxPyFontEnumerator "self._setCallbackInfo(self, FontEnumerator, 0)"