Created
June 11, 2022 10:20
-
-
Save siddhpant/8de5df38b437372d0e9fd80b9332e7a0 to your computer and use it in GitHub Desktop.
Change the Devanagari font 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
<?xml version="1.0"?> | |
<!DOCTYPE fontconfig SYSTEM "fonts.dtd"> | |
<fontconfig> | |
<!-- Set Mukta as the Devanagari font. --> | |
<!-- We will remove Devanagari characters from all fonts except Mukta. --> | |
<!-- Idea courtesy: https://stackoverflow.com/a/47614324 --> | |
<!-- Pseudo code: --> | |
<!-- for font in fonts: --> | |
<!-- if "Mukta" not in font.family --> | |
<!-- font.charset = charset.all - charset.devanagari --> | |
<match target="scan"> | |
<test qual="any" name="family" compare="not_eq"> | |
<string>Mukta</string> | |
</test> | |
<edit name="charset" mode="assign"> <!-- Edit the charset. --> | |
<minus> <!-- Remove chars from charset. --> | |
<name>charset</name> | |
<charset> | |
<range> | |
<!-- Devanagari (Normal) --> | |
<int>0x0900</int> | |
<int>0x097F</int> | |
</range> | |
<range> | |
<!-- Devanagari Extended --> | |
<int>0xA8E0</int> | |
<int>0xA8FF</int> | |
</range> | |
</charset> | |
</minus> | |
</edit> | |
</match> | |
</fontconfig> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Change
Mukta
to any font you like.