don't lose fonts underlined flag in ReInit() (bug fix for the change in rev. 1.76)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26093 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -448,13 +448,22 @@ wxFontRefData::wxFontRefData(const wxString& fontname)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifndef __WXGTK20__
|
#ifndef __WXGTK20__
|
||||||
|
|
||||||
void wxFontRefData::ReInit(const wxString& fontname)
|
void wxFontRefData::ReInit(const wxString& fontname)
|
||||||
{
|
{
|
||||||
|
// calling InitFromNative() resets m_underlined flag as X11 fonts are never
|
||||||
|
// underlined, but we don't want to lose its old value here so save it ...
|
||||||
|
bool underlined = m_underlined;
|
||||||
|
|
||||||
m_nativeFontInfo.SetXFontName(fontname);
|
m_nativeFontInfo.SetXFontName(fontname);
|
||||||
|
|
||||||
InitFromNative();
|
InitFromNative();
|
||||||
|
|
||||||
|
// ... and restore it now
|
||||||
|
m_underlined = underlined;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
#endif // !__WXGTK20__
|
||||||
|
|
||||||
void wxFontRefData::ClearGdkFonts()
|
void wxFontRefData::ClearGdkFonts()
|
||||||
{
|
{
|
||||||
|
@@ -448,13 +448,22 @@ wxFontRefData::wxFontRefData(const wxString& fontname)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifndef __WXGTK20__
|
#ifndef __WXGTK20__
|
||||||
|
|
||||||
void wxFontRefData::ReInit(const wxString& fontname)
|
void wxFontRefData::ReInit(const wxString& fontname)
|
||||||
{
|
{
|
||||||
|
// calling InitFromNative() resets m_underlined flag as X11 fonts are never
|
||||||
|
// underlined, but we don't want to lose its old value here so save it ...
|
||||||
|
bool underlined = m_underlined;
|
||||||
|
|
||||||
m_nativeFontInfo.SetXFontName(fontname);
|
m_nativeFontInfo.SetXFontName(fontname);
|
||||||
|
|
||||||
InitFromNative();
|
InitFromNative();
|
||||||
|
|
||||||
|
// ... and restore it now
|
||||||
|
m_underlined = underlined;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
#endif // !__WXGTK20__
|
||||||
|
|
||||||
void wxFontRefData::ClearGdkFonts()
|
void wxFontRefData::ClearGdkFonts()
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user