Here is what we know:
If running Windows 10 Pro the Windows System Locale is set to "Chinese
Simplified (China)", which indirectly sets Windows' default code page
to 936.
If we run: SetFont("Fixedsys",12,0)
It will not set Fixedsys, but rather goes to Courier New.
before (v4.50.13) Font:Fixedsys Size:12 Flags:0
after (v4.50.16) Font:Courier New Size:12 Flags:0
and actually shows font Courier New but Fixedsys was requested.
Here are the code changes for fonts from .13 to .16:
----------
.13:
lf.lfCharSet = DEFAULT_CHARSET;
if ((font_charset >= 1 && font_charset < 0xffff) || (font_flags &
_FONT_CHARSET_))
lf.lfCharSet = font_charset;
lf.lfPitchAndFamily = FIXED_PITCH | FF_MODERN;
----------
.16:
lf.lfCharSet = ANSI_CHARSET;
if ((font_charset > 1 && font_charset < 0xffff) || ((font_flags &
_FONT_CHARSET_) && (font_charset != DEFAULT_CHARSET)))
lf.lfCharSet = font_charset;
else if (strcmp(face_name, "Terminal") == 0)
lf.lfCharSet = DEFAULT_CHARSET;
lf.lfPitchAndFamily = FIXED_PITCH | FF_MODERN;
lf.lfQuality = CLEARTYPE_NATURAL_QUALITY;
Notes: font_charset and font_flags are the SetFont() parameters.
Your macro used: SetFont("Fixedsys",12,0)
So font_flags and font_charset are 0.
Values from Windows header files:
ANSI_CHARSET: 0
DEFAULT_CHARSET: 1
OEM_CHARSET: 255
Only two differences I see that might impact this are:
1) v.16 uses ANSI_CHARSET as the charset, instead of DEFAULT_CHARSET
in v.13, when charset is not passed.
2) v.16 adds the lfQuality = CLEARTYPE_NATURAL_QUALITY
So it may be both of those or one of them causing the problem.
The lfCharSet change was to fix the font bug originally reported by Carlo.
The lfQuality change was based on something I read in the Windows documentation.
I'll continue to cipher on this.
> --
>
> ---
> You received this message because you are subscribed to the Google Groups "SemWare TSE Pro text editor" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
semware+u...@googlegroups.com.
> To view this discussion visit
https://groups.google.com/d/msgid/semware/348e6b59-c51b-4bd1-912f-98c21dfcc5f9n%40googlegroups.com.