git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@28130
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
// set up fonts and colours
InheritAttributes();
// set up fonts and colours
InheritAttributes();
- SetFont(GetDefaultAttributes().font);
+ if (!m_hasFont)
+ SetFont(GetDefaultAttributes().font);
// set the size now if no initial size specified
SetInitialBestSize(size);
// set the size now if no initial size specified
SetInitialBestSize(size);
if ( ret )
{
SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE));
if ( ret )
{
SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE));
- SetFont(wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT));
}
m_hDC = (WXHDC) ::GetDC((HWND) GetHWND());
}
m_hDC = (WXHDC) ::GetDC((HWND) GetHWND());
if ( ret )
{
SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE));
if ( ret )
{
SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE));
- SetFont(wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT));
}
m_hDC = (WXHDC) ::GetDC((HWND) GetHWND());
}
m_hDC = (WXHDC) ::GetDC((HWND) GetHWND());
if ( ret )
{
SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE));
if ( ret )
{
SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE));
- SetFont(wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT));
}
m_hDC = (WXHDC) ::GetDC((HWND) GetHWND());
}
m_hDC = (WXHDC) ::GetDC((HWND) GetHWND());
wxDC dc;
dc.SetHDC((WXHDC)hdc);
wxDC dc;
dc.SetHDC((WXHDC)hdc);
- dc.SetFont(wxSystemSettings::GetFont(wxSYS_ANSI_VAR_FONT));
pStruct->itemHeight = dc.GetCharHeight() + 2*OWNER_DRAWN_LISTBOX_EXTRA_SPACE;
pStruct->itemWidth = dc.GetCharWidth();
pStruct->itemHeight = dc.GetCharHeight() + 2*OWNER_DRAWN_LISTBOX_EXTRA_SPACE;
pStruct->itemWidth = dc.GetCharWidth();
// set up fonts and colours (This is nomally done in MSWCreateControl)
InheritAttributes();
// set up fonts and colours (This is nomally done in MSWCreateControl)
InheritAttributes();
- SetFont(GetDefaultAttributes().font);
+ if (!m_hasFont)
+ SetFont(GetDefaultAttributes().font);
// set the size of the text window - can do it only now, because we
// couldn't call DoGetBestSize() before as font wasn't set
// set the size of the text window - can do it only now, because we
// couldn't call DoGetBestSize() before as font wasn't set
SetFieldsCount(1);
SubclassWin(m_hWnd);
SetFieldsCount(1);
SubclassWin(m_hWnd);
SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_MENUBAR));
SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_MENUBAR));