Last active
May 9, 2023 15:16
-
-
Save ryuukk/78ca2865fc192c9007bb8293344de8cd to your computer and use it in GitHub Desktop.
Improve chromium font rendering on linux
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- a/skia/BUILD.gn | |
+++ b/skia/BUILD.gn | |
@@ -150,12 +150,19 @@ | |
} | |
# Settings for text blitting, chosen to approximate the system browser. | |
- if (is_linux || is_chromeos) { | |
+ if (is_chromeos) { | |
defines += [ | |
"SK_GAMMA_EXPONENT=1.2", | |
"SK_GAMMA_CONTRAST=0.2", | |
] | |
- } else if (is_android) { | |
+ } else if (is_linux) { | |
+ defines += [ | |
+ "SK_GAMMA_APPLY_TO_A8", | |
+ "SK_GAMMA_EXPONENT=2.2", | |
+ "SK_GAMMA_CONTRAST=0.0", | |
+ ] | |
+ } | |
+ else if (is_android) { | |
defines += [ | |
"SK_GAMMA_APPLY_TO_A8", | |
"SK_GAMMA_EXPONENT=1.4", |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment