X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/dd05139a8023fd3e30476409fafbe04221c6d627..63e1921d0be4956ab729735189ccf637773a7e27:/src/cocoa/settings.mm diff --git a/src/cocoa/settings.mm b/src/cocoa/settings.mm index 0b87a457af..0f6ffb05f0 100644 --- a/src/cocoa/settings.mm +++ b/src/cocoa/settings.mm @@ -19,8 +19,10 @@ #endif #include "wx/cocoa/autorelease.h" +#include "wx/cocoa/private/fontfactory.h" #import +#import // ---------------------------------------------------------------------------- // wxSystemSettingsNative @@ -106,8 +108,10 @@ wxColour wxSystemSettingsNative::GetColour(wxSystemColour index) wxFont wxSystemSettingsNative::GetFont(wxSystemFont index) { -// return a nonworking font object, crash from wxInitializeStockObjects - return wxFont(); + // Return the system font for now + { wxAutoNSAutoreleasePool pool; + return wxCocoaFontFactory::InstanceForNSFont([NSFont systemFontOfSize:0.0], false); + } switch (index) { case wxSYS_ANSI_VAR_FONT :