mooons / TGLangID

Fix Telegram Desktop (Windows) Chinese font issue under non-Chinese locales (LangIDs).

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

TGLangID

Fix Telegram Desktop (Windows) Chinese font issue under non-Chinese locales (LangIDs).

Only 14 KB in final release binary size!

Inspired by FontMod.

Usage

  1. Install Visual Studio 2019, select Desktop development with C++
  2. Open TGLangID.sln
  3. Select menu Build -> Build Solution
  4. Locate version.dll under project root's Release folder
  5. Copy version.dll to the same folder as Telegram.exe
  6. Run Telegram.exe

What is this

This is a bare-bone DLL that can be loaded as version.dll which then hooks GetUserDefaultLangID, deceiving the modified Qt Telegram Windows uses that the user's language ID is 0x0804. Therefore, Qt would load the font set in the order I want.

Without the patch/hook, if the user language ID isn't 0x0804 or 0x1004, it could load Japanese fonts with higher priority, leading to funny Chinese characters displays.

About

Fix Telegram Desktop (Windows) Chinese font issue under non-Chinese locales (LangIDs).

License:MIT License


Languages

Language:C++ 76.7%Language:Assembly 23.3%