X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/26bf1ce0bc3061bf7b1f237f2e0c62101cdef218..0470b1e6fe7a49bb87756006ef9fc232e3dbaaf8:/src/common/wincmn.cpp diff --git a/src/common/wincmn.cpp b/src/common/wincmn.cpp index 26181e21b2..9cad968ed4 100644 --- a/src/common/wincmn.cpp +++ b/src/common/wincmn.cpp @@ -119,8 +119,11 @@ void wxWindowBase::InitBase() m_backgroundColour = settings.GetSystemColour(wxSYS_COLOUR_BTNFACE); m_foregroundColour = *wxBLACK; // TODO take this from sys settings too? +#ifndef __WXMAC__ m_font = *wxSWISS_FONT; // and this? - +#else + m_font = settings.GetSystemFont(wxSYS_DEFAULT_GUI_FONT); +#endif // no style bits m_windowStyle = 0; @@ -351,7 +354,9 @@ void wxWindowBase::Centre(int direction) yNew += posParent.y; } - Move(xNew, yNew); + // move the centre of this window to this position (not the upper left + // corner as it was done before) + Move(xNew - width / 2, yNew - height / 2); } // fits the window around the children