X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/85ab460e7d62b52b105b3dc0bbdd36cebc14fb4b..ee5aa9d44fa75e88bce9981d7d02dea9f6d5f3c4:/src/os2/font.cpp?ds=sidebyside diff --git a/src/os2/font.cpp b/src/os2/font.cpp index 9871769c77..4ed240007c 100644 --- a/src/os2/font.cpp +++ b/src/os2/font.cpp @@ -20,12 +20,13 @@ // headers // ---------------------------------------------------------------------------- +#include "wx/font.h" + #ifndef WX_PRECOMP #include #include "wx/list.h" #include "wx/utils.h" #include "wx/app.h" - #include "wx/font.h" #include "wx/log.h" #endif // WX_PRECOMP @@ -50,7 +51,7 @@ class WXDLLEXPORT wxFontRefData: public wxGDIRefData public: wxFontRefData() { - Init(-1, wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_NORMAL, FALSE, + Init(-1, wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_NORMAL, false, wxEmptyString, wxFONTENCODING_DEFAULT); } @@ -296,6 +297,8 @@ protected: bool m_bInternalPS; // Internally generated PS? }; // end of CLASS wxFontRefData +#define M_FONTDATA ((wxFontRefData*)m_refData) + // ============================================================================ // implementation // ============================================================================ @@ -854,7 +857,7 @@ wxString wxNativeFontInfo::ToString() const fa.usCodePage, fa.lMatch, fn.usWeightClass, - fa.szFacename); + (char *)fa.szFacename); return sStr; } // end of wxNativeFontInfo::ToString @@ -947,7 +950,7 @@ bool wxFont::FreeResource( bool WXUNUSED(bForce) ) return false; } // end of wxFont::FreeResource -WXHANDLE wxFont::GetResourceHandle() +WXHANDLE wxFont::GetResourceHandle() const { return GetHFONT(); } // end of wxFont::GetResourceHandle @@ -1135,19 +1138,14 @@ const wxNativeFontInfo* wxFont::GetNativeFontInfo() const // // Internal use only method to set the FONTMETRICS array // -void wxFont::SetFM( - PFONTMETRICS pFM -, int nNumFonts -) +void wxFont::SetFM( PFONTMETRICS pFM, int nNumFonts ) { M_FONTDATA->SetFM(pFM); M_FONTDATA->SetNumFonts(nNumFonts); } // end of wxFont::SetFM -void wxFont::SetPS( - HPS hPS -) +void wxFont::SetPS( HPS hPS ) { Unshare();