-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove the default font of subtitle grid; use system UI font when config font is empty #139
base: feature
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As a Microsoft Windows user, I appreciate your analysis of the Windows font-related mechanics.
For me, the build generated from this PR works as expected on Windows 11 (build 26100). I reset the Aegisub config files and used the new build.
…I got a better idea. We can just read the system UI font face name from wxNORMAL_FONT when the config font name is blank. Now in Chinese (China) locale, it would be displayed in the precise UI font (Microsoft YaHei UI in the screenshot) rather than the composite Segoe UI font. If any user wanna switch from custom font to system UI font, they can just remove the font name in the text ctrl. The placeholder text added in this PR will prompt the user that this entry have fallbacked to the system font, plus to what font. While any typical Europe-language-locale Windows would display the placeholder in “Segoe UI”, I encourge Chinese (Taiwan), Japanese, Korean and Thai users to check if your placeholder is “Microsoft JhengHei UI”, “Yu Gothic UI”, “Malgun Gothic” and “Leelawadee UI”, respectively. |
Great idea! I guess I will do some testing on Windows later. By the way, GHA builds triggered by new commits seem to fail... |
Btw, there's still two “Verdana” left, one is the font of Audio/karaoke, another is hard-coded in: Aegisub/src/visual_tool_cross.cpp Line 83 in 80491ba
Both of them are only used to display numbers and punctuations so Verdana should be fine across different locales in Windows/macOS. But I'll probably open another PR, turning the hard-coded font face into a user option, and making Verdana the “platform-specific” default rather than generic default. |
One of the first batch of things that any new Chinese user of Aegisub does after installing the software is to change the font of the subtitle grid. The default typeface, Tahoma, will fallback to SimSun (宋体) / MingLiU (新細明體) under Chinese locales, which looks quite bizarre.
According to Microsoft's documentation, this is a composite font defined in
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontLink\SystemLink
. The value in it seems to be some ancient settings date back to Windows 2000.I strongly recommend using different default fonts for each platform. Considering that the current Windows version requirement is Windows 7, using the Segoe UI should result in a good fallback sequence across locales. For example, on Windows 10/11 it could fallback to Microsoft YaHei UI, the default system UI font on zh-cn locale.
In addition, the default font size is too small for Chinese. This PR has increased the default font size from 8pt to 10pt.
I have no mac to test so I'm not sure if SF Pro is variable, and whether it can be displayed in proper font weight in Aegisub. Looking for feedbacks from mac users.
As on Linux, I'm quite unsure. KDE users will have Noto installed (I use KDE only), but what about GNOME or XFCE or any other desktop environments? Or, can we use the generic font name "Sans" on wxGTK?