Closed Coxxs closed 4 years ago
Please read: #5368 (TL;DR; it will broke arabic fonts)
Thank you for the link. It's true that CJK fonts in the system do not contain semi-bold style. Is it possible to use bold version of CJK fonts when semi-bold font is requested?
Is it possible to use bold version of CJK fonts when semi-bold font is requested?
No, at least without patching of Open Sans :(
Are bold characters from this artifact readable for you? https://github.com/ilya-fedin/tdesktop/actions/runs/94518612
Yes, perfectly readable. It's a little too thick compared to semi-bold characters, but still better than no bold.
Before:
Still have some minor issue, Telegram is using Light Italic
to display Regular Italic
text, and using Regular Italic
to display Bold Italic
text. This behavior seems already exists in old versions, maybe it's better to open another issue after fixing bold font issue.
After testing several different system locales, it turns out it only happens on Microsoft YaHei
font[1], not on Malgun Gothic
, Yu Gothic UI
or Microsoft JhengHei UI
.
[1] First & third column on the picture is using Microsoft YaHei
, as YaHei also includes some Japanese characters
it turns out it only happens on
Microsoft YaHei
font
Maybe Telegram should use Microsoft YaHei UI? :thinking:
It's ugly and not quite readable for me
@Coxxs looks like no bold font for you :(
I adjusted to 125% scaling (used to be 200%), here's the result:
Telegram 2.1.1:
actions/runs/94518612
:
Microsoft Word:
Chrome:
~It seems that Chrome might have some sort of rendering optimize.~
Sorry, I forgot I've set Source Han Sans
as my default font in Chrome. Above screenshot has been updated.
Telegram just renders the same as Microsoft & Chrome does, when using exact same font size.
Telegram just renders the same as Microsoft & Chrome does, when using exact same font size.
Yeah, I agree @NekoInverter's Chrome screenshot looks for me more unreadable, than his Telegram screenshot
A try with Microsoft YaHei UI, I hope this will fix light weight issue https://github.com/ilya-fedin/tdesktop/actions/runs/94904040
it's built
Looks good now!
Ok, I added the fix for light weight to the PR with korean fonts fix And created a PR with bold fix: https://github.com/desktop-app/lib_ui/pull/12 But the final decision is up to @john-preston
Chinese fonts are now broken on Windows 7man_facepalming
how are they then rendered in the rest of the system?
Microsoft Yahei UI was introduced in Windows 8 and doesn't exists on Windows 7
Oh, Ihought it Windows Vista+
Add fallback to Microsoft Yahei probably fix the issue
Does Microsoft JhengHei UI exist on Windows 7?
Which fonts are right, with UI or without? Different Chinese people says different things.
From Wikipedia
This doesn't answer the second question, something like a table with default fons for different Windows versions (Vista-10) is needed
Also, what about Yu Gothic UI and Malgun Gothic?
Looks like this is related to the new DirectWrite font database which is not ready yet. Sounds horrible.
Also, looks like this function only selects default font for application when custom font is not set (but tdesktop uses open sans) and doesn't manage fallbacks
I hope that no one will say "it is not so difficult to fix" about CJK font fallback anymore
You can call SystemParametersInfo directly to get system default font and set it as fallback
Stop, this won't fix the fallback for non-CJK OS
Ok, I replaced all fonts with non-UI ones, so that they are shouldn't have diefferent weight and should be from WIndows Vista. For Japanese I also added Meiryo, since Yu Gothic is from Windows 10. Please test.
https://github.com/ilya-fedin/tdesktop/actions/runs/97374407
The lightweight issue for Italic comes back again in runs/97374407
, maybe we could set tryFonts like this?
... "Microsoft YaHei UI", "Microsoft YaHei", "Arial", "Microsoft JhengHei UI", "Microsoft JhengHei", ...
How it looks like? Japanese should be light too and there are shouldn't be difference :thinking:
runs/97374407
with Chinese locale:
Microsoft YaHei
runs/97374407
with Japanese locale:
2.1.2
with Japanese locale:
Ok, I'll try to add the UI ones
It's built
Telegram 2.1.2 / Windows 7 / Simplified Chinese locale / 100% scaling:
runs/97476086
/ Windows 7 / Simplified Chinese locale / 100% scaling:
runs/97476086
/ Windows 7 / Japanese locale / 100% scaling:
runs/97476086
/ Windows 7 / Traditional Chinese locale / 100% scaling:
runs/97476086
/ Windows 10 / Simplified Chinese locale / 200% scaling:
runs/97476086
/ Windows 7 / Japanese locale / 100% scaling:
What happend to the italic? Is it the same on 2.1.2 with Japanese locale? 😨
Ah, it's Windows 7. So, this is Meiryo, probably :thinking:
When italicized, only Latin characters are slanted, not CJK characters and kana. CJK characters use other methods of emphasis or quotation indication; thus differing from, for example, the typefaces of Romance languages (unrelated distinctions between cursive and non-cursive and other traditional writing styles do exist). Nowadays, however, italicization is used in advertising but usually combined with other, common forms of emphasis, such as bold weight, exclamation marks, and, in Japanese, katakana use.
https://en.wikipedia.org/wiki/Meiryo
So, this is OK :thinking:
runs/97476086
/ Windows 7 / Traditional Chinese locale / 100% scaling:
Unfortunately, there are no Microsoft YaHei UI on Windows 7 to fix that. But this is better than nothing, right?
Microsoft YaHei Light is not introduced until Windows 8.1, so I think Qt is unable to pick a wrong font weight for YaHei in Windows 7 ;)
Vista (& Windows 7) also had Meiryo UI font, but I'm not sure if we should use it...
Vista (& Windows 7) also had Meiryo UI font, but I'm not sure if we should use it...
But it is Japanese font, when Microsoft YaHei is Chinese font
runs/97476086
/ Windows 7 / Japanese locale / 100% scaling:
(using Meiryo
)
runs/97476086
/ Windows 7 / Japanese locale / 100% scaling:
replace Meiryo
with Meiryo UI
using FontMod:
Perhaps only Japanese native speaker can tell which style is better...
Wow, Meiryo UI looks closer to Yu Gothic UI. Perhaps I should add it :)
Microsoft YaHei Light is not introduced until Windows 8.1, so I think Qt is unable to pick a wrong font weight for YaHei in Windows 7 ;)
Then maybe Qt just renders Microsoft YaHei wrongly :(
@Coxxs can you say how do you check which font is used to help to debug #7823?
I'm only familiar with CJK font, and I checked commit history to find out which font is used...
But I think #7823 is not a issue related to font, but a issue related to UI design. Actually if you look at Windows & Chrome, they do not use lots of bold fonts in software UI. The intention of this issue is to fix the bold support for chat content area, when opening this issue, I didn't consider that the UI would also changes.
According to https://github.com/microsoft/vscode/pull/79735, most Japanese people prefer narrow style for kana for UI. I think the order of Japanese fonts should be:
"Yu Gothic UI", "Meiryo UI", "Yu Gothic", "Meiryo"
or just:
"Yu Gothic UI", "Meiryo UI"
Windows 7 already had Meiryo UI, Windows 8.1 shipped Yu Gothic, Windows 10 1507 shipped Yu Gothic UI, changing the order can provide users with different system version a consistent experience.
Ok, thanks
runs/97843908
(#7823) / Windows 7 / Japanese locale / 100% scaling:
Also not found any issues for other CJK locale so far.
I'll give other build when a solution for persian issue will be found
https://github.com/ilya-fedin/tdesktop/actions/runs/98306815 (it's already built)
https://github.com/ilya-fedin/tdesktop/actions/runs/98306815 (it's already built)
Tested on Windows 7 & Windows 10 with different CJK locale, all looks good.
Ok, thanks
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Steps to reproduce
Expected behaviour
(Telegram for Android)
Actual behaviour
(Telegram Desktop 2.1.1)
Configuration
Operating system: Windows 10 19041.207 (2004) Version of Telegram Desktop: 2.1.1 (However, this issue has been around for a long time.) Used theme: Default