X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/6d167489bdf17d55d9bd11be834bc17277661063..6b0eebc537c0f96eab28295b4ae2c4e978a435a5:/src/common/gdicmn.cpp diff --git a/src/common/gdicmn.cpp b/src/common/gdicmn.cpp index 4f33ad414b..eb97decf64 100644 --- a/src/common/gdicmn.cpp +++ b/src/common/gdicmn.cpp @@ -50,7 +50,6 @@ #endif #endif -#if !USE_SHARED_LIBRARY IMPLEMENT_CLASS(wxColourDatabase, wxList) IMPLEMENT_DYNAMIC_CLASS(wxFontList, wxList) IMPLEMENT_DYNAMIC_CLASS(wxPenList, wxList) @@ -59,7 +58,6 @@ IMPLEMENT_DYNAMIC_CLASS(wxResourceCache, wxList) IMPLEMENT_ABSTRACT_CLASS(wxDCBase, wxObject) -#endif wxRect::wxRect(const wxPoint& topLeft, const wxPoint& bottomRight) { @@ -360,10 +358,17 @@ void wxInitializeStockObjects () // wxFontPool = new XFontPool; #endif - wxNORMAL_FONT = new wxFont (12, wxMODERN, wxNORMAL, wxNORMAL); - wxSMALL_FONT = new wxFont (10, wxSWISS, wxNORMAL, wxNORMAL); - wxITALIC_FONT = new wxFont (12, wxROMAN, wxITALIC, wxNORMAL); - wxSWISS_FONT = new wxFont (12, wxSWISS, wxNORMAL, wxNORMAL); + // why under MSW fonts shouldn't have the standard system size? +#ifdef __WXMSW__ + static const int sizeFont = 10; +#else + static const int sizeFont = 12; +#endif + + wxNORMAL_FONT = new wxFont (sizeFont, wxMODERN, wxNORMAL, wxNORMAL); + wxSMALL_FONT = new wxFont (sizeFont - 2, wxSWISS, wxNORMAL, wxNORMAL); + wxITALIC_FONT = new wxFont (sizeFont, wxROMAN, wxITALIC, wxNORMAL); + wxSWISS_FONT = new wxFont (sizeFont, wxSWISS, wxNORMAL, wxNORMAL); wxRED_PEN = new wxPen ("RED", 1, wxSOLID); wxCYAN_PEN = new wxPen ("CYAN", 1, wxSOLID); @@ -455,7 +460,6 @@ wxBitmapList::wxBitmapList () wxBitmapList::~wxBitmapList () { -#if defined(__WXMSW__) || defined(__WXMOTIF__) wxNode *node = First (); while (node) { @@ -465,13 +469,11 @@ wxBitmapList::~wxBitmapList () delete bitmap; node = next; } -#endif } // Pen and Brush lists wxPenList::~wxPenList () { -#if defined(__WXMSW__) || defined(__WXMOTIF__) wxNode *node = First (); while (node) { @@ -481,7 +483,6 @@ wxPenList::~wxPenList () delete pen; node = next; } -#endif } void wxPenList::AddPen (wxPen * pen) @@ -521,7 +522,6 @@ wxPen *wxPenList::FindOrCreatePen (const wxColour& colour, int width, int style) wxBrushList::~wxBrushList () { -#if defined(__WXMSW__) || defined(__WXMOTIF__) wxNode *node = First (); while (node) { @@ -531,7 +531,6 @@ wxBrushList::~wxBrushList () delete brush; node = next; } -#endif } void wxBrushList::AddBrush (wxBrush * brush)