mirror of
https://github.com/reactos/reactos.git
synced 2025-04-27 09:00:27 +00:00
[NOTEPAD] CJK font workaround
Far East Asian users may not have suitable fixed-pitch fonts. CORE-11700
This commit is contained in:
parent
2d725449d2
commit
5ecf017ce2
1 changed files with 10 additions and 8 deletions
|
@ -184,19 +184,21 @@ void NOTEPAD_LoadSettingsFromRegistry(void)
|
||||||
|
|
||||||
ZeroMemory(&Globals.lfFont, sizeof(Globals.lfFont));
|
ZeroMemory(&Globals.lfFont, sizeof(Globals.lfFont));
|
||||||
Globals.lfFont.lfCharSet = DEFAULT_CHARSET;
|
Globals.lfFont.lfCharSet = DEFAULT_CHARSET;
|
||||||
Globals.lfFont.lfClipPrecision = CLIP_STROKE_PRECIS;
|
|
||||||
Globals.lfFont.lfEscapement = 0;
|
|
||||||
LoadString(Globals.hInstance, STRING_DEFAULTFONT, Globals.lfFont.lfFaceName,
|
LoadString(Globals.hInstance, STRING_DEFAULTFONT, Globals.lfFont.lfFaceName,
|
||||||
ARRAY_SIZE(Globals.lfFont.lfFaceName));
|
ARRAY_SIZE(Globals.lfFont.lfFaceName));
|
||||||
Globals.lfFont.lfItalic = FALSE;
|
|
||||||
Globals.lfFont.lfOrientation = 0;
|
|
||||||
Globals.lfFont.lfOutPrecision = OUT_STRING_PRECIS;
|
|
||||||
Globals.lfFont.lfPitchAndFamily = FIXED_PITCH | FF_MODERN;
|
Globals.lfFont.lfPitchAndFamily = FIXED_PITCH | FF_MODERN;
|
||||||
Globals.lfFont.lfQuality = PROOF_QUALITY;
|
|
||||||
Globals.lfFont.lfStrikeOut = FALSE;
|
|
||||||
Globals.lfFont.lfUnderline = FALSE;
|
|
||||||
Globals.lfFont.lfWeight = FW_NORMAL;
|
Globals.lfFont.lfWeight = FW_NORMAL;
|
||||||
Globals.lfFont.lfHeight = HeightFromPointSize(100);
|
Globals.lfFont.lfHeight = HeightFromPointSize(100);
|
||||||
|
|
||||||
|
/* WORKAROUND: Far East Asian users may not have suitable fixed-pitch fonts. */
|
||||||
|
switch (PRIMARYLANGID(GetUserDefaultLangID()))
|
||||||
|
{
|
||||||
|
case LANG_CHINESE:
|
||||||
|
case LANG_JAPANESE:
|
||||||
|
case LANG_KOREAN:
|
||||||
|
Globals.lfFont.lfPitchAndFamily = DEFAULT_PITCH | FF_DONTCARE;
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
hFont = CreateFontIndirect(&Globals.lfFont);
|
hFont = CreateFontIndirect(&Globals.lfFont);
|
||||||
|
|
Loading…
Reference in a new issue