diff --git a/NEWS.md b/NEWS.md index 4f0d2e7b..d91293e4 100644 --- a/NEWS.md +++ b/NEWS.md @@ -5,6 +5,7 @@ Version 0.10.4 For Dev-C++ 7 Beta - change: press shift+tab when there are selections will do unindent - enhancement: press home will switch between begin of line and the position of fisrt non-space char - enhancement: press end will switch between end of line and the position of last non-space char + - enhancement: use "Microsoft Yahei" as the default UI font whe running in Simplified Chinese Windows Version 0.10.3 For Dev-C++ 7 Beta - enhancement: treat files ended with ".C" or ".CPP" as C++ files diff --git a/RedPandaIDE/settings.cpp b/RedPandaIDE/settings.cpp index 78751f5b..ec709366 100644 --- a/RedPandaIDE/settings.cpp +++ b/RedPandaIDE/settings.cpp @@ -2708,7 +2708,16 @@ void Settings::Environment::doLoad() { //Appearence mTheme = stringValue("theme","dark"); - mInterfaceFont = stringValue("interface font","Segoe UI"); + QString defaultFontName = "Segoe UI"; + if (QLocale::system().name() == "zh_CN") { + QString fontName; + fontName = "Microsoft Yahei"; + QFont font(fontName); + if (font.exactMatch()) { + defaultFontName = fontName; + } + } + mInterfaceFont = stringValue("interface font",defaultFontName); mInterfaceFontSize = intValue("interface font size",10); mLanguage = stringValue("language", QLocale::system().name());