Comments (10)
Yeah, it works even for the official Telegram Desktop 4.0.2. Here is my regedit config for changing fonts to non-cleartype style (ofcourse you need to disable cleartype in Windows beforehand):
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontSubstitutes]
"DAOpenSansRegular"="Arial"
"DAVazirRegular"="Arial"
"DAOpenSansRegularItalic"="Arial"
"DAOpenSansSemibold"="Arial"
"DAVazirMedium"="Arial"
"DAOpenSansSemiboldItalicAsBold"="Arial"
On 1080p screen my fonts look awesomely clear as I think.
On 4K screen my fonts look not so great than via FontMod+quality:3 (method described below), but still better than default.
Also you still can use FontMod (it works for Windows and Wine). Just download FontMod dll version 2.1 (version 3.0.1 won't change fonts) -> rename dll to winmm.dll
-> place it in 64Gram folder -> launch 64Gram, so the FontMod.yaml
config appears in the folder -> exit 64Gram -> edit fonts in FontMod.yaml
-> launch 64Gram.
I even achieved changing fonts to non-cleartype style. Here are the configs for 4K (200% UI scaling) and 1080p screens: FontMod Telegram clear fonts.zip / alternative download link.
P.S. if someone doesn't like bold font I have set in aforementioned 4K config, you can delete "quality" and "size" strings in this fragment:
DAOpenSansSemibold:
replace: DAOpenSansSemibold
quality: 3
size: 37
thus you will get default Telegram bold font.
upd. Changing font size via FontMod 2.1 stopped working since 64gram version 1.0.64 (tg 4.6.1), discussion is in #81.
from fontmod.
How did you find out what font telegram is using? (in case of future changes)
maybe cleaned the Telegram client folder -> launched client from scratch -> opened log.txt
file -> looked for messages like Font: from ':/gui/fonts/DAOpenSansRegular.ttf' loaded 'DAOpenSansRegular'
?
from fontmod.
@Kyogre Thanks!
I got the following lines:
Font: from ':/gui/fonts/DAOpenSansRegular.ttf' loaded 'DAOpenSansRegular'
Font: from ':/gui/fonts/DAOpenSansRegularItalic.ttf' loaded 'DAOpenSansRegularItalic'
Font: from ':/gui/fonts/DAOpenSansSemiboldAsBold.ttf' loaded 'DAOpenSansSemibold'
Font: from ':/gui/fonts/DAOpenSansSemiboldItalicAsBold.ttf' loaded 'DAOpenSansSemiboldItalic'
Font: from ':/gui/fonts/DAVazirRegular.ttf' loaded 'DAVazirRegular'
Font: from ':/gui/fonts/DAVazirMediumAsBold.ttf' loaded 'DAVazirMedium'
and I think OP @rocco-xyz made a mistake, e.g. substitution should use font name DAOpenSansSemiboldItalic
not font file name DAOpenSansSemiboldItalicAsBold
, which is the reason why OP did not successfully change the bold fonts.
Note: It does not change «ALL» the fonts.
I guess for the non-custom fonts Telegram will just load them from system with font name as query term, like Consolas
for Consolas.
from fontmod.
All telegram fonts can be found in lib_ui and implementaion of font selection is here.
My final reg version:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontSubstitutes]
"DAOpenSans"="Tahoma"
"DAOpenSansBold"="Tahoma"
"DAOpenSansBoldItalic"="Tahoma"
"DAOpenSansRegular"="Tahoma"
"DAOpenSansRegularItalic"="Tahoma"
"DAOpenSansSemibold"="Tahoma"
"DAOpenSansSemiboldItalic"="Tahoma"
"DAVazir"="Tahoma"
"DAVazirBold"="Tahoma"
"DAVazirMedium"="Tahoma"
"DAVazirRegular"="Tahoma"
;; Priority font resolving: "Cascadia Mono", "Consolas", "Liberation Mono", "Menlo", "Courier"
;; Override monospace font:
"Cascadia Mono"="Fixedsys"
from fontmod.
Maybe someone will find it helpful.
If you just replace the font, you can get a issue that the line height of the font and emoji are different, so when you add emoji to the text, it is shifted down.
I patched the standard Segoe UI font, fixed vertical metrics.
Now telegram looks perfect for me as on macos.
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontSubstitutes]
"DAOpenSans"="VSegoe UI"
"DAOpenSansBold"="VSegoe UI Bold"
"DAOpenSansBoldItalic"="VSegoe UI Bold Italic"
"DAOpenSansRegular"="VSegoe UI"
"DAOpenSansRegularItalic"="VSegoe UI Italic"
"DAOpenSansSemibold"="VSegoe UI Semibold"
"DAOpenSansSemiboldItalic"="VSegoe UI Semibold Italic"
"DAVazir"="VSegoe UI"
"DAVazirBold"="VSegoe UI Bold"
"DAVazirMedium"="VSegoe UI Semibold"
"DAVazirRegular"="VSegoe UI"
;; Priority font resolving: "Cascadia Mono", "Consolas", "Liberation Mono", "Menlo", "Courier"
;; Override monospace font:
"Cascadia Mono"="JetBrains Mono"
Patched font
fixed.zip
from fontmod.
It seems Telegram updates them font, so the above ones not working anymore.
How to track which font uses Telegram?
Now you can change default font family in chat settings 🥳
from fontmod.
Worked for me, thanks!
On Windows11 21H2 x64
Telegram Desktop 3.6.0 x64
from fontmod.
How did you find out what font telegram is using? (in case of future changes)
from fontmod.
With some testing, substituting Consolas
will change the monospace font in Telegram, despite the higher priority of Monaco
or Menlo
in the source code:
code, kbd, pre, samp {
font-family: Menlo,Monaco,Consolas,"Courier New",monospace;
}
Maybe the query term is not Monaco
? Just like the query term for Open Sans is DAOpenSansRegular
not Open Sans
or something more reasonable (again, how did you find out the correct query term for Open Sans?).
This is my registry file:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontSubstitutes]
"DAOpenSans"="Sarasa UI SC Light"
"DAOpenSansItalic"="Sarasa UI SC Light Italic"
"DAOpenSansRegular"="Sarasa UI SC"
"DAOpenSansRegularItalic"="Sarasa UI SC Italic"
"DAOpenSansSemibold"="Sarasa UI SC Bold"
"DAOpenSansSemiboldItalic"="Sarasa UI SC Bold Italic"
"DAOpenSansBold"="Sarasa UI SC Bold"
"DAOpenSansBoldItalic"="Sarasa UI SC Bold Italic"
"Consolas"="Sarasa Mono SC"
I am using Sarasa UI SC Bold
for DAOpenSansSemibold
because the semibold variant of Sarasa UI are not visually distinctive enough.
from fontmod.
It seems Telegram updates them font, so the above ones not working anymore.
How to track which font uses Telegram?
from fontmod.
Related Issues (20)
- [Question] How to use the overridings ? HOT 7
- [Feature Request] Support GDI+ HOT 9
- 请问FontMod64.dll和FontMod32.dll,Win10 64位专业版用哪个?还是两个一起用? HOT 5
- TG Desktop 2.8.5 Beta 不允许 DLL 注入了 HOT 6
- Telegram 2.8.8 stable breaks everything HOT 1
- Telegram 2.8.8 似乎不再载入 `winmm.dll` HOT 2
- Telegram 2.8.5+ don't allow any .dll-s near Telegram.exe HOT 5
- 用在最新telegram上不起作用 HOT 5
- 无法修改字体大小,不会自动生成配置文件FontMod.yaml HOT 1
- MyGetStockObject 方法遗漏了 DEFAULT_GUI_FONT
- Linux Arch HOT 1
- 無法替換為特定字型
- fonts won't apply on FontMod v3 HOT 5
- font can not be changed in newest telegram version(x64 v4.6.1) HOT 6
- 英文系统,telegram修复不管用呀
- [Request] Enable GitHub Discussions for sharing experiences and working examples HOT 1
- Fontmod 3.x
- exe程序无法应用Fonts文件夹的字体文件 HOT 19
- Registry font-editing does not working anymore. Is there any workaround about that? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fontmod.