]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/gtk1/font.h
fix MDI child sizing, which was working more or less by accident before I broke it...
[wxWidgets.git] / include / wx / gtk1 / font.h
index 2465dc3554bd4654ae689b66c81130d430fb1dc7..6936e530f3415f161730e168ce9cbf5a58255aa6 100644 (file)
@@ -1,5 +1,5 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        font.h
+// Name:        wx/gtk1/font.h
 // Purpose:
 // Author:      Robert Roebling
 // Id:          $Id$
 #ifndef __GTKFONTH__
 #define __GTKFONTH__
 
-#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
-    #pragma interface
-#endif
-
 #include "wx/hash.h"
 
 // ----------------------------------------------------------------------------
 // classes
 // ----------------------------------------------------------------------------
 
-class wxDC;
-class wxPaintDC;
-class wxWindow;
+class WXDLLIMPEXP_FWD_CORE wxDC;
+class WXDLLIMPEXP_FWD_CORE wxPaintDC;
+class WXDLLIMPEXP_FWD_CORE wxWindow;
 
-class wxFont;
+class WXDLLIMPEXP_FWD_CORE wxFont;
 
 // ----------------------------------------------------------------------------
 // wxFont
 // ----------------------------------------------------------------------------
 
-class wxFont : public wxFontBase
+class WXDLLIMPEXP_CORE wxFont : public wxFontBase
 {
 public:
     // ctors and such
-    wxFont() { Init(); }
-    wxFont(const wxFont& font) : wxFontBase() { Init(); Ref(font); }
+    wxFont() { }
 
     // wxGTK-specific
     wxFont(const wxString& fontname)
     {
-        Init();
-
         Create(fontname);
     }
 
@@ -51,12 +44,10 @@ public:
            int family,
            int style,
            int weight,
-           bool underlined = FALSE,
+           bool underlined = false,
            const wxString& face = wxEmptyString,
            wxFontEncoding encoding = wxFONTENCODING_DEFAULT)
     {
-        Init();
-
         (void)Create(size, family, style, weight, underlined, face, encoding);
     }
 
@@ -64,17 +55,14 @@ public:
                 int family,
                 int style,
                 int weight,
-                bool underlined = FALSE,
+                bool underlined = false,
                 const wxString& face = wxEmptyString,
                 wxFontEncoding encoding = wxFONTENCODING_DEFAULT);
 
     // wxGTK-specific
     bool Create(const wxString& fontname);
 
-    ~wxFont();
-
-    // assignment
-    wxFont& operator=(const wxFont& font);
+    virtual ~wxFont();
 
     // implement base class pure virtuals
     virtual int GetPointSize() const;
@@ -84,35 +72,30 @@ public:
     virtual wxString GetFaceName() const;
     virtual bool GetUnderlined() const;
     virtual wxFontEncoding GetEncoding() const;
-    virtual wxNativeFontInfo *GetNativeFontInfo() const;
+    virtual const wxNativeFontInfo *GetNativeFontInfo() const;
     virtual bool IsFixedWidth() const;
 
     virtual void SetPointSize( int pointSize );
     virtual void SetFamily( int family );
     virtual void SetStyle( int style );
     virtual void SetWeight( int weight );
-    virtual void SetFaceName( const wxString& faceName );
+    virtual bool SetFaceName( const wxString& faceName );
     virtual void SetUnderlined( bool underlined );
     virtual void SetEncoding(wxFontEncoding encoding);
 
-    virtual void SetNoAntiAliasing( bool no = TRUE );
-    virtual bool GetNoAntiAliasing();
+    virtual void SetNoAntiAliasing( bool no = true );
+    virtual bool GetNoAntiAliasing() const ;
 
     // implementation from now on
     void Unshare();
 
-#ifndef __WXGTK20__
     GdkFont* GetInternalFont(float scale = 1.0) const;
-#endif
 
     // no data :-)
 
 protected:
     virtual void DoSetNativeFontInfo( const wxNativeFontInfo& info );
 
-    // common part of all ctors
-    void Init();
-
 private:
     DECLARE_DYNAMIC_CLASS(wxFont)
 };