rizonesoft / Notepad3

Notepad like text editor based on the Scintilla source code. Notepad3 based on code from Notepad2 and MiniPath on code from metapath. Download Notepad3:
https://www.rizonesoft.com/downloads/notepad3/
Other
4.79k stars 323 forks source link

Some questions about the use of FontLink #5221

Open kidzgy opened 2 weeks ago

kidzgy commented 2 weeks ago

Open regedit.exe, locate "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontLink\SystemLink", New value type: "REG_MULTI_SZ", name “Consolas”, data “SarasaGothicSC-Regular.TTF, Sarasa Gothic SC”.Log off or restart your computer.

The font used is: https://github.com/be5invis/Sarasa-Gothic/releases/download/v1.0.13/SarasaGothicSC-TTF-1.0.13.7z

For usage see: https://learn.microsoft.com/en-us/globalization/fonts-layout/fonts#font-linking-and-gdi

338873455-61ee089e-674b-42d1-83b4-5419ba17c23b

By setting it this way, when I select Consolas as the default font in Notepad, the Sarasa Gothic SC font is used for all parts except for the Numbers/Letters.

However, Notepad must have "GDI (no ligatures)" checked or it won't work. 2024-06-12_165737

If the other three options of "DirectWrite" are checked, all fonts other than Western fonts will be "Microsoft Yahei UI" instead of "Sarasa Gothic SC".

In this issue, I'm certainly not asking for hope that notepad will support multiple fonts, as this has been discussed in previous issues.

I just have the following questions: 1, Why is the FontLink setting in the registry only used when GDI is checked? 2, Why is it that when DirectWrite is checked, except for Numbers/Letters which are Consolas, why are the other fonts "Microsoft Yahei UI", and can I use the registry settings in Windows to set "Microsoft Yahei UI" as other fonts?

Testing environment: Windows 10 x64 19044.1741, Notepad 6.24.601.1 rc3