Habeeb on Nostr: If you use XFCE terminal or maybe other terminals, and you changed the font to ...
If you use XFCE terminal or maybe other terminals, and you changed the font to something like JetBrains Mono, you will notice that Arabic is broken. To fix this, I did the following:
In ~/.config/fontconfig/fonts.conf I have the following:
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "urn:fontconfig:fonts.dtd">
<fontconfig>
<alias>
<family>monospace</family> <!-- Font family -->
<prefer>
<family>JetBrains Mono</family> <!-- The font you want to use -->
<family>Hack</family> <!-- Fallback -->
<family>Symbols Nerd Font Mono</family> <!-- Fallback -->
</prefer>
</alias>
</fontconfig>
The order is important! JetBrains Mono doesn't contain Arabic characters, so you have to use Hack, DejaVu Sans Mono, or any other font as a fallback for characters that are not included.
Log out and log in, and change the font of the terminal to Monospace. The font you chose in fonts.conf will be selected. Note that this font is also applied to other applications like Firefox.
#Linux #Arabic
Published at
2024-11-04 17:47:41Event JSON
{
"id": "0797fa539ddb6d0ba7af1298e2643172f4b76a913349220e605645774920eded",
"pubkey": "0328f24b55099f3da8dced4e04d20dccd6e8286fd0131905b474edbedc2fb5e2",
"created_at": 1730742461,
"kind": 1,
"tags": [
[
"t",
"Linux"
],
[
"t",
"Arabic"
]
],
"content": "If you use XFCE terminal or maybe other terminals, and you changed the font to something like JetBrains Mono, you will notice that Arabic is broken. To fix this, I did the following:\n\nIn ~/.config/fontconfig/fonts.conf I have the following:\n\n\u003c?xml version=\"1.0\"?\u003e\n\u003c!DOCTYPE fontconfig SYSTEM \"urn:fontconfig:fonts.dtd\"\u003e\n\u003cfontconfig\u003e\n\t\u003calias\u003e\n\t\t\u003cfamily\u003emonospace\u003c/family\u003e \u003c!-- Font family --\u003e\n\t\t\u003cprefer\u003e\n\t\t\t\u003cfamily\u003eJetBrains Mono\u003c/family\u003e \u003c!-- The font you want to use --\u003e\n\t\t\t\u003cfamily\u003eHack\u003c/family\u003e \u003c!-- Fallback --\u003e\n\t\t\t\u003cfamily\u003eSymbols Nerd Font Mono\u003c/family\u003e \u003c!-- Fallback --\u003e\n\t\t\u003c/prefer\u003e\n\t\u003c/alias\u003e\n\u003c/fontconfig\u003e\n\nThe order is important! JetBrains Mono doesn't contain Arabic characters, so you have to use Hack, DejaVu Sans Mono, or any other font as a fallback for characters that are not included.\n\nLog out and log in, and change the font of the terminal to Monospace. The font you chose in fonts.conf will be selected. Note that this font is also applied to other applications like Firefox.\n\nhttps://m.primal.net/LscU.png \nhttps://m.primal.net/LscV.png \n\n#Linux #Arabic",
"sig": "8f77384a2f2ebe485c366639ae923a6f6c18b49cd5926a7963e9874dbf58f7414d65e0c1216fb81fdf85994445aeb0a9655df13682320c26d4bbfe944fb79389"
}