-
Notifications
You must be signed in to change notification settings - Fork 6.3k
windows: Improve font rendering #32933
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
Conversation
|
I looked into a bunch of implementations when I implemented this, mainly Also, one of the issues with Hopefully next time we can have a quick discussion before jumping into PR, I think it’ll help us stay aligned and avoid back-and-forth. |
|
The current implementation is too blurry, adding antialiasing to the whole glyph when downscaling does not look very good. The text system should closely follow the platform implementation to give users a similar experience. So I believe following how the Windows terminal does it is better rather than trying to make it look like macOS.
I don't see this issue, it just seems like the interpolation done to the glyphs in the current implementation has made all the letters thicker than they should be. |
1180ebf to
8f4f52c
Compare
8f4f52c to
91cdebf
Compare
|
I personally like the current look, it does look a little more like MacOS which i prefer since i personally think Windows font rendering is horrible. |
|
@vipexv This change isn't about opinion, it's about platform conformity. I am curious if you have tried the PR with your settings to see the changes on your device, if you are on a higher DPI screen or use larger font sizes the difference should be minimal. Some screenshots of the difference you are viewing would be more helpful. |
I also feel like if this is something that is going to be merged, we should also have a settings option to keep the current look for people who prefer the "MacOS" style. And i haven't personally tried this PR, i'm just going off the screenshot above. |
Going off the screenshot may not represent what It will look like on your device. I suggest you try this change and see if there is a difference with your own settings, if there is some difference some screenshots would be appreciated.
As for having a option to adjust the rendering I am not sure how that would look like, some finer grained options would be needed rather than a single option for this specific type of rendering you prefer, there is a issue that tracks that #8503. |
|
I believe this work has been superseded by work the windows team is taking on, thanks for the contribution though! |




Improves font rendering on Windows by using
IDWriteGlyphRunAnalysis::CreateAlphaTextureinstead ofID2D1DeviceContext4::DrawGlyphRunfor non emoji glyphs. This should also slightly improve performance as a Direct2D bitmap and bitmap scaler is not used anymore for non emoji glyphs. This implementation now aligns with how non emoji glyphs are done in many other applications like the Windows 11 Terminal, and some others projects listed in this #9403 (comment).Closes #14113
Before on the left and after on the right. The images may not give a accurate representation of what the text will look like as it is dependent on the resolution you view the images at.
The most noticeable changes can be seen on smaller text with darker backgrounds, the text is slightly sharper.
While this is a improvement, subpixel antialiasing is still missing but that will require some much larger changes to GPUI and all the platform text systems.
Release Notes: