git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71810
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
bool wxFont::IsFixedWidth() const
{
bool wxFont::IsFixedWidth() const
{
- wxCHECK_MSG( M_FONTDATA != NULL , wxFONTWEIGHT_MAX, wxT("invalid font") );
+ wxCHECK_MSG( M_FONTDATA != NULL , false, wxT("invalid font") );
+ // cast away constness otherwise lazy font resolution is not possible
+ const_cast<wxFont *>(this)->RealizeResource();
+
return M_FONTDATA->IsFixedWidth();
}
return M_FONTDATA->IsFixedWidth();
}