You are not logged in.

#1 2022-11-01 10:22:02

sokuban
Member
Registered: 2006-11-11
Posts: 412

How to edit fontconfig? (to have a precedence order of fonts)

Basically, I want to be able to use the Google Noto fonts by default for every language I need (in just random text, that would not necessarily properly have language tags). The problem is the Noto fonts are separated into several fonts per language, so I can't just set one font as my system font and have everything work properly.

I have had Noto CJK HK set as my system font, and this works fine for Chinese etc. However, I also want to display Tamil text with the Noto Tamil font, but by default, the system falls back onto a different font (since Noto CJK HK doesn't have Tamil glyphs). I want to set an order of preference, by setting it so that if a glyph is not found in Noto CJK HK, the system will fall back and look at Noto Tamil, etc. I used to be able to do this decades ago by putting something like this in .fonts.conf

<alias>
    <family>Sans</family>
    <prefer>
        <family>Noto Sans CJK HK</family>
        <family>Noto Sans Tamil</family>
    </prefer>
</alias>

I am aware .fonts.conf is deprecated, so I'm using ~/.config/fontconfig/fonts.conf
I am also aware there needs to be a link in /etc/fonts/conf.d/ to /usr/share/fontconfig/conf.avail/50-user.conf

It just doesn't work anymore. What can I do to create a precedence order of fonts for the system to fallback on when glyphs are missing from a font?

Btw, I use KDE.

Offline

#2 2022-11-01 12:13:41

seth
Member
Registered: 2012-09-03
Posts: 50,012

Re: How to edit fontconfig? (to have a precedence order of fonts)

"Does not work" how?

fc-match -s :charset=0b89

(That should be "உ")

I am aware .fonts.conf is deprecated, so I'm using ~/.config/fontconfig/fonts.conf

The suggestion would be to use sth. like ~/.config/fontconfig/conf.d/99-weirdassnonlatinglyphorder.conf ;-)

Offline

#3 2022-11-02 01:39:33

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,131

Re: How to edit fontconfig? (to have a precedence order of fonts)

seth wrote:

I am aware .fonts.conf is deprecated, so I'm using ~/.config/fontconfig/fonts.conf

The suggestion would be to use sth. like ~/.config/fontconfig/conf.d/99-weirdassnonlatinglyphorder.conf ;-)

~/.config/fontconfig/fonts.conf should* also work according to 50-user.conf, provided it is symlinked from /etc/fonts/conf.d/ etc. wink

* Terms subject to ambiguity, equivocation, miscellaneous mischief and arbitrary conditions.


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#4 2022-11-02 07:25:52

seth
Member
Registered: 2012-09-03
Posts: 50,012

Re: How to edit fontconfig? (to have a precedence order of fonts)

Yeah, but the point of that scheme isn't so much to find a reason and way to channel frustration about the 8-bit wilderness that would not have happened if the roman or british empire or anybody else, really, had convinced the rest of the world to stop their silly attempts at not using latin glyphs and that in the end lead us to the devolution of ever more emojis (pretty much every cultural type set started as pictograms and for the most part our ancestors stopped that because they figured it's stupid…), but the /conf.d/99- part which makes it simpler and less error prone to juggle around configs than a single large fonts.conf that will sometimes have users introduce bash-style comments or other glitches that break the font configuration for some, but not all clients.
Depending on how robust forgiving the xml implementation is.

Offline

#5 2022-11-02 18:12:00

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,131

Re: How to edit fontconfig? (to have a precedence order of fonts)

seth wrote:

Yeah, but the point of that scheme isn't so much to find a reason and way to channel frustration about the 8-bit wilderness that would not have happened if the roman or british empire or anybody else, really, had convinced the rest of the world to stop their silly attempts at not using latin glyphs and that in the end lead us to the devolution of ever more emojis (pretty much every cultural type set started as pictograms and for the most part our ancestors stopped that because they figured it's stupid…), ...

Wrth gwrs, dylai pawb siarad Gymraeg.

Thanks for the link. I didn't know that about the different unicode formats. I'm rather used to the encoding tangles ....

seth wrote:

.... but the /conf.d/99- part which makes it simpler and less error prone to juggle around configs than a single large fonts.conf that will sometimes have users introduce bash-style comments or other glitches that break the font configuration for some, but not all clients.
Depending on how robust forgiving the xml implementation is.

Fair enough, but separate files can introduce confusion, too. But I really just meant that what the OP had should work.


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#6 2022-11-10 14:24:13

sokuban
Member
Registered: 2006-11-11
Posts: 412

Re: How to edit fontconfig? (to have a precedence order of fonts)

Tried the 99-, it didn't work either.

I mean what I mean is. I have set my system font to Noto Sans CJK HK. This font does not contain any Tamil glyphs. If I select the font "Sans" (or basically any other font that doesn't have Tamil glyphs, so also "Noto Sans CJK HK") and try to type some Tamil, the Tamil comes out in some random font, it's readable, but I don't like it (I think it's Mangal). I want the system to fall back onto Noto Sans Tamil instead of Mangal.

I tried writing those lines in fonts.conf or the ~/.config/fontconfig/conf.d/99-weirdassnonlatinglyphorder.conf as you suggested, and the system still falls back on Mangal instead of Noto Sans Tamil when I select "Sans" or "Noto Sans CJK HK" as my font.

How would I get it to fallback to Noto Sans Tamil when the selected font doesn't have any Tamil glyphs?

EDIT: My full fonts.conf file is:

<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "urn:fontconfig:fonts.dtd">
<fontconfig>
<alias>
    <family>Sans</family>
    <prefer>
        <family>Noto Sans Tamil</family>
    </prefer>
</alias>
</fontconfig>

Last edited by sokuban (2022-11-10 14:27:40)

Offline

#7 2022-11-10 14:39:37

seth
Member
Registered: 2012-09-03
Posts: 50,012

Re: How to edit fontconfig? (to have a precedence order of fonts)

We should not focus too much on where the config should be placed.
The canonical suggestion is to use the conf.d drop-in, but as discussed, ~/.config/fontconfig/fonts.conf will work fine.
I just pointed that out because I understood an implied "amidoinitrite?" in your elaborations on the config location.

Now:

seth more importantly wrote:

fc-match -s :charset=0b89

Offline

#8 2022-11-15 02:00:57

sokuban
Member
Registered: 2006-11-11
Posts: 412

Re: How to edit fontconfig? (to have a precedence order of fonts)

Here is my output from that command:

Interestingly, this output is different from what I would get if I put a Chinese character. For a Chinese character, Noto Sans CJK HK comes up first, but here, Noto Sans Tamil comes before it. It is still preceeded by Vijaya and latha, which I don't want though. I tried deleting my fonts.conf and 99-etcetc file, and I got the same output. So it seems that the fonts.conf files aren't doing anything.

vijaya.ttf: "Vijaya" "Regular"
latha.ttf: "Latha" "Regular"
NotoSansTamil-Regular.ttf: "Noto Sans Tamil" "Regular"
NotoSansCJK-Regular.ttc: "Noto Sans CJK HK" "Regular"
NotoSans-Regular.ttf: "Noto Sans" "Regular"
DejaVuSans.ttf: "DejaVu Sans" "Book"
DejaVuSans-Bold.ttf: "DejaVu Sans" "Bold"
DejaVuSans-Oblique.ttf: "DejaVu Sans" "Oblique"
DejaVuSans-BoldOblique.ttf: "DejaVu Sans" "Bold Oblique"
arial.ttf: "Arial" "Regular"
NimbusSans-Regular.otf: "Nimbus Sans" "Regular"
l_10646.ttf: "Lucida Sans Unicode" "Regular"
tahoma.ttf: "Tahoma" "Regular"
ms gothic.ttf: "MS Gothic" "Regular"
msyh.ttf: "微软雅黑" "Regular"
meiryo ui.ttf: "Meiryo UI" "Regular"
cambria math.ttf: "Cambria Math" "Regular"
msuighur.ttf: "Microsoft Uighur" "Regular"
andlso.ttf: "Andalus" "Regular"
gabriola.ttf: "Gabriola" "Regular"
trado.ttf: "Traditional Arabic" "Regular"
aparaj.ttf: "Aparajita" "Regular"
arabtype.ttf: "Arabic Typesetting" "Regular"
shonar.ttf: "Shonar Bangla" "Regular"
vani.ttf: "Vani" "Regular"
iskpota.ttf: "Iskoola Pota" "Regular"
kalinga.ttf: "Kalinga" "Regular"
kartika.ttf: "Kartika" "Regular"
ntailu.ttf: "Microsoft New Tai Lue" "Regular"
phagspa.ttf: "Microsoft PhagsPa" "Regular"
raavi.ttf: "Raavi" "Regular"
shruti.ttf: "Shruti" "Regular"
taile.ttf: "Microsoft Tai Le" "Regular"
tunga.ttf: "Tunga" "Regular"
nsimsun.ttf: "新宋体" "Regular"
david.ttf: "David" "Regular"
frank.ttf: "FrankRuehl" "Regular"
rod.ttf: "Rod" "Regular"
gulim.ttf: "Gulim" "Regular"
monbaiti.ttf: "Mongolian Baiti" "Regular"
mvboli.ttf: "MV Boli" "Regular"
seguisym.ttf: "Segoe UI Symbol" "Regular"
kaiu.ttf: "標楷體" "Regular"
DoulosSIL-R.ttf: "Doulos SIL" "Regular"
batang.ttf: "Batang" "Regular"
daunpenh.ttf: "DaunPenh" "Regular"
ebrima.ttf: "Ebrima" "Regular"
estre.ttf: "Estrangelo Edessa" "Regular"
euphemia.ttf: "Euphemia" "Regular"
himalaya.ttf: "Microsoft Himalaya" "Regular"
msyi.ttf: "Microsoft Yi Baiti" "Regular"
nyala.ttf: "Nyala" "Regular"
plantc.ttf: "Plantagenet Cherokee" "Regular"
simsunb.ttf: "SimSun-ExtB" "Regular"
Hack-Regular.ttf: "Hack" "Regular"
NotoNastaliqUrdu-Regular.ttf: "Noto Nastaliq Urdu" "Regular"
NotoSansAdlam-Regular.ttf: "Noto Sans Adlam" "Regular"
NotoSansWarangCiti-Regular.ttf: "Noto Sans Warang Citi" "Regular"
DejaVuMathTeXGyre.ttf: "DejaVu Math TeX Gyre" "Regular"
DejaVuSerif.ttf: "DejaVu Serif" "Book"
NotoSerifTangut-Regular.ttf: "Noto Serif Tangut" "Regular"
NotoKufiArabic-Regular.ttf: "Noto Kufi Arabic" "Regular"
NotoSansMyanmar-Regular.ttf: "Noto Sans Myanmar" "Regular"
NotoSerifMalayalam-Regular.ttf: "Noto Serif Malayalam" "Regular"
NotoSansGujarati-Regular.ttf: "Noto Sans Gujarati" "Regular"
NotoSansLisu-Regular.ttf: "Noto Sans Lisu" "Regular"
NotoSerifTibetan-Regular.ttf: "Noto Serif Tibetan" "Regular"
NotoSansEthiopic-Regular.ttf: "Noto Sans Ethiopic" "Regular"
NotoSansHanifiRohingya-Regular.ttf: "Noto Sans Hanifi Rohingya" "Regular"
NotoSansSoraSompeng-Regular.ttf: "Noto Sans Sora Sompeng" "Regular"
LiberationSerif-Regular.ttf: "Liberation Serif" "Regular"
SourceCodePro-Regular.otf: "Source Code Pro" "Regular"
NotoNaskhArabic-Regular.ttf: "Noto Naskh Arabic" "Regular"
NotoSansArabic-Regular.ttf: "Noto Sans Arabic" "Regular"
NotoSansMono-Regular.ttf: "Noto Sans Mono" "Regular"
NotoSansArmenian-Regular.ttf: "Noto Sans Armenian" "Regular"
NotoSansNewa-Regular.ttf: "Noto Sans Newa" "Regular"
NotoSansSharada-Regular.ttf: "Noto Sans Sharada" "Regular"
NotoSansCaucasianAlbanian-Regular.ttf: "Noto Sans Caucasian Albanian" "Regular"
NotoSansElbasan-Regular.ttf: "Noto Sans Elbasan" "Regular"
NotoSansJavanese-Regular.ttf: "Noto Sans Javanese" "Regular"
NotoSansLepcha-Regular.ttf: "Noto Sans Lepcha" "Regular"
NotoSansManichaean-Regular.ttf: "Noto Sans Manichaean" "Regular"
NotoSansOldHungarian-Regular.ttf: "Noto Sans Old Hungarian" "Regular"
NotoSansSignWriting-Regular.ttf: "Noto Sans SignWriting" "Regular"
NotoSansSymbols2-Regular.ttf: "Noto Sans Symbols2" "Regular"
NotoSerifAhom-Regular.ttf: "Noto Serif Ahom" "Regular"
NotoSerifGrantha-Regular.ttf: "Noto Serif Grantha" "Regular"
NotoSansBalinese-Regular.ttf: "Noto Sans Balinese" "Regular"
NotoSansBengali-Regular.ttf: "Noto Sans Bengali" "Regular"
NotoSansBrahmi-Regular.ttf: "Noto Sans Brahmi" "Regular"
NotoSansChakma-Regular.ttf: "Noto Sans Chakma" "Regular"
NotoSansDevanagari-Regular.ttf: "Noto Sans Devanagari" "Regular"
NotoSansGurmukhi-Regular.ttf: "Noto Sans Gurmukhi" "Regular"
NotoSansHanunoo-Regular.ttf: "Noto Sans Hanunoo" "Regular"
NotoSansInscriptionalPahlavi-Regular.ttf: "Noto Sans Inscriptional Pahlavi" "Regular"
NotoSansKannada-Regular.ttf: "Noto Sans Kannada" "Regular"
NotoSansKharoshthi-Regular.ttf: "Noto Sans Kharoshthi" "Regular"
NotoSansKhojki-Regular.ttf: "Noto Sans Khojki" "Regular"
NotoSansKhudawadi-Regular.ttf: "Noto Sans Khudawadi" "Regular"
NotoSansLimbu-Regular.ttf: "Noto Sans Limbu" "Regular"
NotoSansMahajani-Regular.ttf: "Noto Sans Mahajani" "Regular"
NotoSansMarchen-Regular.ttf: "Noto Sans Marchen" "Regular"
NotoSansMendeKikakui-Regular.ttf: "Noto Sans Mende Kikakui" "Regular"
NotoSansOlChiki-Regular.ttf: "Noto Sans Ol Chiki" "Regular"
NotoSansOldItalic-Regular.ttf: "Noto Sans Old Italic" "Regular"
NotoSansSinhala-Regular.ttf: "Noto Sans Sinhala" "Regular"
NotoSansTakri-Regular.ttf: "Noto Sans Takri" "Regular"
NotoSansTelugu-Regular.ttf: "Noto Sans Telugu" "Regular"
NotoSansTifinagh-Regular.ttf: "Noto Sans Tifinagh" "Regular"
NotoSansTirhuta-Regular.ttf: "Noto Sans Tirhuta" "Regular"
NotoSansZanabazarSquare-Regular.ttf: "Noto Sans Zanabazar Square" "Regular"
NotoTraditionalNushu-Regular.ttf: "Noto Traditional Nushu" "Regular"
NotoMusic-Regular.ttf: "Noto Music" "Regular"
NotoSansAvestan-Regular.ttf: "Noto Sans Avestan" "Regular"
NotoSansBassaVah-Regular.ttf: "Noto Sans Bassa Vah" "Regular"
NotoSansBatak-Regular.ttf: "Noto Sans Batak" "Regular"
NotoSansBhaiksuki-Regular.ttf: "Noto Sans Bhaiksuki" "Regular"
NotoSansCanadianAboriginal-Regular.ttf: "Noto Sans Canadian Aboriginal" "Regular"
NotoSansCham-Regular.ttf: "Noto Sans Cham" "Regular"
NotoSansCoptic-Regular.ttf: "Noto Sans Coptic" "Regular"
NotoSansGeorgian-Regular.ttf: "Noto Sans Georgian" "Regular"
NotoSansInscriptionalParthian-Regular.ttf: "Noto Sans Inscriptional Parthian" "Regular"
NotoSansKaithi-Regular.ttf: "Noto Sans Kaithi" "Regular"
NotoSansKayahLi-Regular.ttf: "Noto Sans Kayah Li" "Regular"
NotoSansLao-Regular.ttf: "Noto Sans Lao" "Regular"
NotoSansLinearB-Regular.ttf: "Noto Sans Linear B" "Regular"
NotoSansMandaic-Regular.ttf: "Noto Sans Mandaic" "Regular"
NotoSansMath-Regular.ttf: "Noto Sans Math" "Regular"
NotoSansMeeteiMayek-Regular.ttf: "Noto Sans Meetei Mayek" "Regular"
NotoSansMiao-Regular.ttf: "Noto Sans Miao" "Regular"
NotoSansModi-Regular.ttf: "Noto Sans Modi" "Regular"
NotoSansMongolian-Regular.ttf: "Noto Sans Mongolian" "Regular"
NotoSansNKo-Regular.ttf: "Noto Sans NKo" "Regular"
NotoSansOsage-Regular.ttf: "Noto Sans Osage" "Regular"
NotoSansRunic-Regular.ttf: "Noto Sans Runic" "Regular"
NotoSansSiddham-Regular.ttf: "Noto Sans Siddham" "Regular"
NotoSansSundanese-Regular.ttf: "Noto Sans Sundanese" "Regular"
NotoSansSylotiNagri-Regular.ttf: "Noto Sans Syloti Nagri" "Regular"
NotoSansSymbols-Regular.ttf: "Noto Sans Symbols" "Regular"
NotoSansTaiTham-Regular.ttf: "Noto Sans Tai Tham" "Regular"
NotoSansTaiViet-Regular.ttf: "Noto Sans Tai Viet" "Regular"
NotoSansTamilSupplement-Regular.ttf: "Noto Sans Tamil Supplement" "Regular"
andalemo.ttf: "Andale Mono" "Regular"
NotoSansAnatolianHieroglyphs-Regular.ttf: "Noto Sans Anatolian Hieroglyphs" "Regular"
NotoSansBamum-Regular.ttf: "Noto Sans Bamum" "Regular"
NotoSansBuginese-Regular.ttf: "Noto Sans Buginese" "Regular"
NotoSansBuhid-Regular.ttf: "Noto Sans Buhid" "Regular"
NotoSansCarian-Regular.ttf: "Noto Sans Carian" "Regular"
NotoSansCherokee-Regular.ttf: "Noto Sans Cherokee" "Regular"
NotoSansCuneiform-Regular.ttf: "Noto Sans Cuneiform" "Regular"
NotoSansCypriot-Regular.ttf: "Noto Sans Cypriot" "Regular"
NotoSansDuployan-Regular.ttf: "Noto Sans Duployan" "Regular"
NotoSansEgyptianHieroglyphs-Regular.ttf: "Noto Sans Egyptian Hieroglyphs" "Regular"
NotoSansGlagolitic-Regular.ttf: "Noto Sans Glagolitic" "Regular"
NotoSansHatran-Regular.ttf: "Noto Sans Hatran" "Regular"
NotoSansImperialAramaic-Regular.ttf: "Noto Sans Imperial Aramaic" "Regular"
NotoSansIndicSiyaqNumbers-Regular.ttf: "Noto Sans Indic Siyaq Numbers" "Regular"
NotoSansLinearA-Regular.ttf: "Noto Sans Linear A" "Regular"
NotoSansLycian-Regular.ttf: "Noto Sans Lycian" "Regular"
NotoSansLydian-Regular.ttf: "Noto Sans Lydian" "Regular"
NotoSansMeroitic-Regular.ttf: "Noto Sans Meroitic" "Regular"
NotoSansMro-Regular.ttf: "Noto Sans Mro" "Regular"
NotoSansMultani-Regular.ttf: "Noto Sans Multani" "Regular"
NotoSansNabataean-Regular.ttf: "Noto Sans Nabataean" "Regular"
NotoSansOldNorthArabian-Regular.ttf: "Noto Sans Old North Arabian" "Regular"
NotoSansOldPermic-Regular.ttf: "Noto Sans Old Permic" "Regular"
NotoSansOldPersian-Regular.ttf: "Noto Sans Old Persian" "Regular"
NotoSansOldSogdian-Regular.ttf: "Noto Sans Old Sogdian" "Regular"
NotoSansOldSouthArabian-Regular.ttf: "Noto Sans Old South Arabian" "Regular"
NotoSansOriya-Regular.ttf: "Noto Sans Oriya" "Regular"
NotoSansPahawhHmong-Regular.ttf: "Noto Sans Pahawh Hmong" "Regular"
NotoSansPalmyrene-Regular.ttf: "Noto Sans Palmyrene" "Regular"
NotoSansPauCinHau-Regular.ttf: "Noto Sans Pau Cin Hau" "Regular"
NotoSansPhoenician-Regular.ttf: "Noto Sans Phoenician" "Regular"
NotoSansPsalterPahlavi-Regular.ttf: "Noto Sans Psalter Pahlavi" "Regular"
NotoSansRejang-Regular.ttf: "Noto Sans Rejang" "Regular"
NotoSansSamaritan-Regular.ttf: "Noto Sans Samaritan" "Regular"
NotoSansSaurashtra-Regular.ttf: "Noto Sans Saurashtra" "Regular"
NotoSansShavian-Regular.ttf: "Noto Sans Shavian" "Regular"
NotoSansSogdian-Regular.ttf: "Noto Sans Sogdian" "Regular"
NotoSansSoyombo-Regular.ttf: "Noto Sans Soyombo" "Regular"
NotoSansTagalog-Regular.ttf: "Noto Sans Tagalog" "Regular"
NotoSansTagbanwa-Regular.ttf: "Noto Sans Tagbanwa" "Regular"
NotoSansUgaritic-Regular.ttf: "Noto Sans Ugaritic" "Regular"
NotoSansWancho-Regular.ttf: "Noto Sans Wancho" "Regular"
NotoSerifToto-Regular.ttf: "Noto Serif Toto" "Regular"
NotoSansTangsa-Regular.ttf: "Noto Sans Tangsa" "Regular"
NotoSansCyproMinoan-Regular.ttf: "Noto Sans Cypro Minoan" "Regular"
NotoSerifDogra-Regular.ttf: "Noto Serif Dogra" "Regular"
NotoSerifVithkuqi-Regular.ttf: "Noto Serif Vithkuqi" "Regular"
NotoSansMasaramGondi-Regular.ttf: "Noto Sans Masaram Gondi" "Regular"
NotoSansGunjalaGondi-Regular.ttf: "Noto Sans Gunjala Gondi" "Regular"
NotoSansChorasmian-Regular.ttf: "Noto Sans Chorasmian" "Regular"
NotoSansMedefaidrin-Regular.ttf: "Noto Sans Medefaidrin" "Regular"
NotoSerifOldUyghur-Regular.ttf: "Noto Serif Old Uyghur" "Regular"
SyrCOMKharput.otf: "Serto Kharput" "Regular"
NotoLoopedLao-Regular.ttf: "Noto Looped Lao" "Regular"
NotoLoopedThai-Regular.ttf: "Noto Looped Thai" "Regular"
NotoSansElymaic-Regular.ttf: "Noto Sans Elymaic" "Regular"
NotoSansNandinagari-Regular.ttf: "Noto Sans Nandinagari" "Regular"
NotoSerifDivesAkuru-Regular.ttf: "Noto Serif Dives Akuru" "Regular"
NotoSerifMakasar-Regular.ttf: "Noto Serif Makasar" "Regular"
NotoSerifNyiakengPuachueHmong-Regular.ttf: "Noto Serif Hmong Nyiakeng" "Regular"
NotoSerifYezidi-Regular.ttf: "Noto Serif Yezidi" "Regular"
KanjiStrokeOrders.ttf: "KanjiStrokeOrders" "Medium"
font.ttf: "SILDoulosIPA" "Regular"
DejaVuSerif-Italic.ttf: "DejaVu Serif" "Italic"
LiberationSerif-Italic.ttf: "Liberation Serif" "Italic"
12x13ja.pcf.gz: "Misc Fixed Wide" "ja"
6x13.pcf.gz: "Misc Fixed" "SemiCondensed"
9x15.pcf.gz: "Misc Fixed" "Regular"
cu-alt12.pcf.gz: "MUTT ClearlyU Alternate Glyphs Wide" "Regular"
cu-pua12.pcf.gz: "MUTT ClearlyU PUA" "Regular"
cu12.pcf.gz: "MUTT ClearlyU Wide" "Regular"
NotoColorEmoji.ttf: "Noto Color Emoji" "Regular"
symbol.ttf: "Symbol" "Regular"

Last edited by sokuban (2022-11-15 02:29:35)

Offline

#9 2022-11-15 07:38:30

seth
Member
Registered: 2012-09-03
Posts: 50,012

Re: How to edit fontconfig? (to have a precedence order of fonts)

There's probably another config in the way that prefers those fonts.
Let's see

fc-conflist

Offline

#10 2022-11-18 07:32:13

sokuban
Member
Registered: 2006-11-11
Posts: 412

Re: How to edit fontconfig? (to have a precedence order of fonts)

+ /etc/fonts/conf.d/10-hinting-slight.conf: Set hintslight to hintstyle
+ /etc/fonts/conf.d/10-scale-bitmap-fonts.conf: Bitmap scaling
+ /etc/fonts/conf.d/10-sub-pixel-rgb.conf: Enable sub-pixel rendering with the RGB stripes layout
+ /etc/fonts/conf.d/10-yes-antialias.conf: Enable antialiasing
+ /etc/fonts/conf.d/11-lcdfilter-default.conf: Use lcddefault as default for LCD filter
+ /etc/fonts/conf.d/20-ttf-win7-fonts-japanese.conf: No description
+ /etc/fonts/conf.d/20-ttf-win7-fonts-korean.conf: No description
+ /etc/fonts/conf.d/20-ttf-win7-fonts-latin.conf: No description
+ /etc/fonts/conf.d/20-ttf-win7-fonts-zh_cn.conf: No description
+ /etc/fonts/conf.d/20-ttf-win7-fonts-zh_tw.conf: No description
+ /etc/fonts/conf.d/20-unhint-small-dejavu-lgc-sans-mono.conf: No description
+ /etc/fonts/conf.d/20-unhint-small-dejavu-lgc-sans.conf: No description
+ /etc/fonts/conf.d/20-unhint-small-dejavu-lgc-serif.conf: No description
+ /etc/fonts/conf.d/20-unhint-small-dejavu-sans-mono.conf: No description
+ /etc/fonts/conf.d/20-unhint-small-dejavu-sans.conf: No description
+ /etc/fonts/conf.d/20-unhint-small-dejavu-serif.conf: No description
+ /etc/fonts/conf.d/20-unhint-small-vera.conf: Disable hinting for Bitstream Vera fonts when the size is less than 8ppem
+ /etc/fonts/conf.d/30-metric-aliases.conf: Set substitutions for similar/metric-compatible families
+ /etc/fonts/conf.d/30-win32-aliases.conf: No description
+ /etc/fonts/conf.d/40-nonlatin.conf: Set substitutions for non-Latin fonts
+ /etc/fonts/conf.d/45-generic.conf: Set substitutions for emoji/math fonts
+ /etc/fonts/conf.d/45-latin.conf: Set substitutions for Latin fonts
+ /etc/fonts/conf.d/46-noto-mono.conf: No description
+ /etc/fonts/conf.d/46-noto-sans.conf: No description
+ /etc/fonts/conf.d/46-noto-serif.conf: No description
+ /etc/fonts/conf.d/48-spacing.conf: Add mono to the family when spacing is 100
+ /etc/fonts/conf.d/49-sansserif.conf: Add sans-serif to the family when no generic name
+ /home/ganyi/.fonts.conf: No description
+ /etc/fonts/conf.d/50-user.conf: Load per-user customization files
+ /etc/fonts/conf.d/51-local.conf: Load local customization file
+ /etc/fonts/conf.d/57-dejavu-sans-mono.conf: No description
+ /etc/fonts/conf.d/57-dejavu-sans.conf: No description
+ /etc/fonts/conf.d/57-dejavu-serif.conf: No description
+ /etc/fonts/conf.d/58-dejavu-lgc-sans-mono.conf: No description
+ /etc/fonts/conf.d/58-dejavu-lgc-sans.conf: No description
+ /etc/fonts/conf.d/58-dejavu-lgc-serif.conf: No description
+ /etc/fonts/conf.d/60-generic.conf: Set preferable fonts for emoji/math fonts
+ /etc/fonts/conf.d/60-latin.conf: Set preferable fonts for Latin
+ /etc/fonts/conf.d/65-fonts-persian.conf: No description
+ /etc/fonts/conf.d/65-nonlatin.conf: Set preferable fonts for non-Latin
+ /etc/fonts/conf.d/66-noto-mono.conf: No description
+ /etc/fonts/conf.d/66-noto-sans.conf: No description
+ /etc/fonts/conf.d/66-noto-serif.conf: No description
+ /etc/fonts/conf.d/69-unifont.conf: No description
+ /etc/fonts/conf.d/69-urw-bookman.conf: No description
+ /etc/fonts/conf.d/69-urw-c059.conf: No description
+ /etc/fonts/conf.d/69-urw-d050000l.conf: No description
+ /etc/fonts/conf.d/69-urw-fallback-backwards.conf: No description
+ /etc/fonts/conf.d/69-urw-fallback-generics.conf: No description
+ /etc/fonts/conf.d/69-urw-fallback-specifics.conf: No description
+ /etc/fonts/conf.d/69-urw-gothic.conf: No description
+ /etc/fonts/conf.d/69-urw-nimbus-mono-ps.conf: No description
+ /etc/fonts/conf.d/69-urw-nimbus-roman.conf: No description
+ /etc/fonts/conf.d/69-urw-nimbus-sans.conf: No description
+ /etc/fonts/conf.d/69-urw-p052.conf: No description
+ /etc/fonts/conf.d/69-urw-standard-symbols-ps.conf: No description
+ /etc/fonts/conf.d/69-urw-z003.conf: No description
+ /etc/fonts/conf.d/70-noto-cjk.conf: No description
+ /etc/fonts/conf.d/80-delicious.conf: No description
+ /etc/fonts/conf.d/90-synthetic.conf: No description
+ /etc/fonts/fonts.conf: Default configuration file
- /usr/share/fontconfig/conf.avail/05-reset-dirs-sample.conf: Re-define fonts dirs sample
- /usr/share/fontconfig/conf.avail/09-autohint-if-no-hinting.conf: Enable autohinter if font doesn't have any hinting
- /usr/share/fontconfig/conf.avail/10-autohint.conf: Enable autohinter
- /usr/share/fontconfig/conf.avail/10-hinting-full.conf: Set hintfull to hintstyle
- /usr/share/fontconfig/conf.avail/10-hinting-medium.conf: Set hintmedium to hintstyle
- /usr/share/fontconfig/conf.avail/10-hinting-none.conf: Set hintnone to hintstyle
- /usr/share/fontconfig/conf.avail/10-hinting-slight.conf: Set hintslight to hintstyle
- /usr/share/fontconfig/conf.avail/10-no-antialias.conf: Disable antialiasing
- /usr/share/fontconfig/conf.avail/10-no-sub-pixel.conf: Disable sub-pixel rendering
- /usr/share/fontconfig/conf.avail/10-scale-bitmap-fonts.conf: Bitmap scaling
- /usr/share/fontconfig/conf.avail/10-sub-pixel-bgr.conf: Enable sub-pixel rendering with the BGR stripes layout
- /usr/share/fontconfig/conf.avail/10-sub-pixel-rgb.conf: Enable sub-pixel rendering with the RGB stripes layout
- /usr/share/fontconfig/conf.avail/10-sub-pixel-vbgr.conf: Enable sub-pixel rendering with the vertical BGR stripes layout
- /usr/share/fontconfig/conf.avail/10-sub-pixel-vrgb.conf: Enable sub-pixel rendering with the vertical RGB stripes layout
- /usr/share/fontconfig/conf.avail/10-unhinted.conf: Disable hinting
- /usr/share/fontconfig/conf.avail/10-yes-antialias.conf: Enable antialiasing
- /usr/share/fontconfig/conf.avail/11-lcdfilter-default.conf: Use lcddefault as default for LCD filter
- /usr/share/fontconfig/conf.avail/11-lcdfilter-legacy.conf: Use lcdlegacy as default for LCD filter
- /usr/share/fontconfig/conf.avail/11-lcdfilter-light.conf: Use lcdlight as default for LCD filter
- /usr/share/fontconfig/conf.avail/20-unhint-small-dejavu-lgc-sans-mono.conf: No description
- /usr/share/fontconfig/conf.avail/20-unhint-small-dejavu-lgc-sans.conf: No description
- /usr/share/fontconfig/conf.avail/20-unhint-small-dejavu-lgc-serif.conf: No description
- /usr/share/fontconfig/conf.avail/20-unhint-small-dejavu-sans-mono.conf: No description
- /usr/share/fontconfig/conf.avail/20-unhint-small-dejavu-sans.conf: No description
- /usr/share/fontconfig/conf.avail/20-unhint-small-dejavu-serif.conf: No description
- /usr/share/fontconfig/conf.avail/20-unhint-small-vera.conf: Disable hinting for Bitstream Vera fonts when the size is less than 8ppem
- /usr/share/fontconfig/conf.avail/25-unhint-nonlatin.conf: Disable hinting for CJK fonts
- /usr/share/fontconfig/conf.avail/30-metric-aliases.conf: Set substitutions for similar/metric-compatible families
- /usr/share/fontconfig/conf.avail/30-win32-aliases.conf: No description
- /usr/share/fontconfig/conf.avail/35-lang-normalize.conf: No description
- /usr/share/fontconfig/conf.avail/40-nonlatin.conf: Set substitutions for non-Latin fonts
- /usr/share/fontconfig/conf.avail/45-generic.conf: Set substitutions for emoji/math fonts
- /usr/share/fontconfig/conf.avail/45-latin.conf: Set substitutions for Latin fonts
- /usr/share/fontconfig/conf.avail/46-noto-mono.conf: No description
- /usr/share/fontconfig/conf.avail/46-noto-sans.conf: No description
- /usr/share/fontconfig/conf.avail/46-noto-serif.conf: No description
- /usr/share/fontconfig/conf.avail/48-spacing.conf: Add mono to the family when spacing is 100
- /usr/share/fontconfig/conf.avail/49-sansserif.conf: Add sans-serif to the family when no generic name
- /usr/share/fontconfig/conf.avail/50-user.conf: Load per-user customization files
- /usr/share/fontconfig/conf.avail/51-local.conf: Load local customization file
- /usr/share/fontconfig/conf.avail/57-dejavu-sans-mono.conf: No description
- /usr/share/fontconfig/conf.avail/57-dejavu-sans.conf: No description
- /usr/share/fontconfig/conf.avail/57-dejavu-serif.conf: No description
- /usr/share/fontconfig/conf.avail/58-dejavu-lgc-sans-mono.conf: No description
- /usr/share/fontconfig/conf.avail/58-dejavu-lgc-sans.conf: No description
- /usr/share/fontconfig/conf.avail/58-dejavu-lgc-serif.conf: No description
- /usr/share/fontconfig/conf.avail/60-generic.conf: Set preferable fonts for emoji/math fonts
- /usr/share/fontconfig/conf.avail/60-latin.conf: Set preferable fonts for Latin
- /usr/share/fontconfig/conf.avail/65-fonts-persian.conf: No description
- /usr/share/fontconfig/conf.avail/65-khmer.conf: No description
- /usr/share/fontconfig/conf.avail/65-nonlatin.conf: Set preferable fonts for non-Latin
- /usr/share/fontconfig/conf.avail/66-noto-mono.conf: No description
- /usr/share/fontconfig/conf.avail/66-noto-sans.conf: No description
- /usr/share/fontconfig/conf.avail/66-noto-serif.conf: No description
- /usr/share/fontconfig/conf.avail/69-unifont.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-bookman.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-c059.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-d050000l.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-fallback-backwards.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-fallback-generics.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-fallback-specifics.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-gothic.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-nimbus-mono-ps.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-nimbus-roman.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-nimbus-sans.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-p052.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-standard-symbols-ps.conf: No description
- /usr/share/fontconfig/conf.avail/69-urw-z003.conf: No description
- /usr/share/fontconfig/conf.avail/70-no-bitmaps.conf: Reject bitmap fonts
- /usr/share/fontconfig/conf.avail/70-noto-cjk.conf: No description
- /usr/share/fontconfig/conf.avail/70-yes-bitmaps.conf: Accept bitmap fonts
- /usr/share/fontconfig/conf.avail/80-delicious.conf: No description
- /usr/share/fontconfig/conf.avail/90-synthetic.conf: No description

Is 65-nonlatin.conf the culprit?

<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "urn:fontconfig:fonts.dtd">
<fontconfig>
  <description>Set preferable fonts for non-Latin</description>
	<alias>
		<family>serif</family>
		<prefer>
			<family>Artsounk</family> <!-- armenian -->
			<family>BPG UTF8 M</family> <!-- georgian -->
			<family>Kinnari</family> <!-- thai -->
			<family>Norasi</family> <!-- thai -->
			<family>Frank Ruehl</family> <!-- hebrew -->
			<family>Dror</family>  <!-- hebrew -->
			<family>JG LaoTimes</family>  <!-- lao -->
			<family>Saysettha Unicode</family>  <!-- lao -->
			<family>Pigiarniq</family> <!-- canadian syllabics -->
			<family>B Davat</family> <!-- arabic (fa) -->
			<family>B Compset</family>  <!-- arabic (fa) -->
			<family>Kacst-Qr</family> <!-- arabic (ar) -->
			<family>Urdu Nastaliq Unicode</family> <!-- arabic (ur) -->
			<family>Raghindi</family> <!-- devanagari -->
			<family>Mukti Narrow</family> <!-- bengali -->
			<family>malayalam</family> <!-- malayalam -->
			<family>Sampige</family> <!-- kannada -->
			<family>padmaa</family> <!-- gujarati -->
			<family>Hapax Berbère</family> <!-- tifinagh -->
			<family>MS Mincho</family> <!-- han (ja) -->
			<family>SimSun</family> <!-- han (zh-cn,zh-tw) -->
			<family>PMingLiu</family> <!-- han (zh-tw) -->
			<family>WenQuanYi Zen Hei</family> <!-- han (zh-cn,zh-tw) -->
			<family>WenQuanYi Bitmap Song</family> <!-- han (zh-cn,zh-tw) -->
			<family>AR PL ShanHeiSun Uni</family> <!-- han (ja,zh-cn,zh-tw) -->
			<family>AR PL New Sung</family> <!-- han (zh-cn,zh-tw) -->
			<family>ZYSong18030</family> <!-- han (zh-cn,zh-tw) -->
			<family>HanyiSong</family> <!-- han (zh-cn,zh-tw) -->
			<family>MgOpen Canonica</family>
			<family>Sazanami Mincho</family>
			<family>IPAMonaMincho</family>
			<family>IPAMincho</family>
			<family>Kochi Mincho</family>
			<family>AR PL SungtiL GB</family>
			<family>AR PL Mingti2L Big5</family>
 			<family>AR PL Zenkai Uni</family>
			<family>MS 明朝</family>
 			<family>ZYSong18030</family>
			<family>NanumMyeongjo</family> <!-- hangul (ko) -->
			<family>UnBatang</family> <!-- hangul (ko) -->
			<family>Baekmuk Batang</family> <!-- hangul (ko) -->
 			<family>KacstQura</family>
 			<family>Frank Ruehl CLM</family>
			<family>Lohit Bengali</family>
 			<family>Lohit Gujarati</family>
 			<family>Lohit Hindi</family>
			<family>Lohit Marathi</family>
			<family>Lohit Maithili</family>
			<family>Lohit Kashmiri</family>
			<family>Lohit Konkani</family>
			<family>Lohit Nepali</family>
			<family>Lohit Sindhi</family>
 			<family>Lohit Punjabi</family>
 			<family>Lohit Tamil</family>
			<family>Rachana</family>
			<family>Lohit Malayalam</family>
 			<family>Lohit Kannada</family>
 			<family>Lohit Telugu</family>
 			<family>Lohit Oriya</family>
 			<family>LKLUG</family>
		</prefer>
	</alias>
	<alias>
		<family>sans-serif</family>
		<prefer>
			<family>Nachlieli</family> <!-- hebrew -->
			<family>Lucida Sans Unicode</family>
			<family>Yudit Unicode</family>
			<family>Kerkis</family> <!-- greek -->
			<family>ArmNet Helvetica</family> <!-- armenian -->
			<family>Artsounk</family> <!-- armenian -->
			<family>BPG UTF8 M</family> <!-- georgian -->
			<family>Waree</family> <!-- thai -->
			<family>Loma</family> <!-- thai -->
			<family>Garuda</family> <!-- thai -->
			<family>Umpush</family> <!-- thai -->
			<family>Saysettha Unicode</family> <!-- lao? -->
			<family>JG Lao Old Arial</family> <!-- lao -->
			<family>GF Zemen Unicode</family> <!-- ethiopic -->
			<family>Pigiarniq</family> <!-- canadian syllabics -->
			<family>B Davat</family> <!-- arabic (fa) -->
			<family>B Compset</family> <!-- arabic (fa) -->
			<family>Kacst-Qr</family> <!-- arabic (ar) -->
			<family>Urdu Nastaliq Unicode</family> <!-- arabic (ur) -->
			<family>Raghindi</family> <!-- devanagari -->
			<family>Mukti Narrow</family> <!-- bengali -->
			<family>malayalam</family> <!-- malayalam -->
			<family>Sampige</family> <!-- kannada -->
			<family>padmaa</family> <!-- gujarati -->
			<family>Hapax Berbère</family> <!-- tifinagh -->
			<family>MS Gothic</family> <!-- han (ja) -->
			<family>UmePlus P Gothic</family> <!-- han (ja) -->
			<family>Microsoft YaHei</family> <!-- han (zh-cn,zh-tw) -->
			<family>Microsoft JhengHei</family> <!-- han (zh-tw) -->
			<family>WenQuanYi Zen Hei</family> <!-- han (zh-cn,zh-tw) -->
			<family>WenQuanYi Bitmap Song</family> <!-- han (zh-cn,zh-tw) -->
			<family>AR PL ShanHeiSun Uni</family> <!--han (ja,zh-cn,zh-tw) -->
			<family>AR PL New Sung</family> <!-- han (zh-cn,zh-tw) -->
			<family>MgOpen Modata</family>
			<family>VL Gothic</family>
			<family>IPAMonaGothic</family>
			<family>IPAGothic</family>
			<family>Sazanami Gothic</family>
			<family>Kochi Gothic</family>
			<family>AR PL KaitiM GB</family>
			<family>AR PL KaitiM Big5</family>
 			<family>AR PL ShanHeiSun Uni</family>
 			<family>AR PL SungtiL GB</family>
 			<family>AR PL Mingti2L Big5</family>
			<family>MS ゴシック</family>
			<family>ZYSong18030</family> <!-- han (zh-cn,zh-tw) -->
			<family>TSCu_Paranar</family> <!-- tamil -->
			<family>NanumGothic</family> <!-- hangul (ko) -->
			<family>UnDotum</family> <!-- hangul (ko) -->
			<family>Baekmuk Dotum</family> <!-- hangul (ko) -->
 			<family>Baekmuk Gulim</family> <!-- hangul (ko) -->
 			<family>KacstQura</family>
			<family>Lohit Bengali</family>
 			<family>Lohit Gujarati</family>
 			<family>Lohit Hindi</family>
			<family>Lohit Marathi</family>
			<family>Lohit Maithili</family>
			<family>Lohit Kashmiri</family>
			<family>Lohit Konkani</family>
			<family>Lohit Nepali</family>
			<family>Lohit Sindhi</family>
 			<family>Lohit Punjabi</family>
 			<family>Lohit Tamil</family>
			<family>Meera</family>
 			<family>Lohit Malayalam</family>
 			<family>Lohit Kannada</family>
 			<family>Lohit Telugu</family>
 			<family>Lohit Oriya</family>
 			<family>LKLUG</family>
		</prefer>
	</alias>
	<alias>
		<family>monospace</family>
		<prefer>
			<family>Miriam Mono</family> <!-- hebrew -->
			<family>VL Gothic</family>
			<family>IPAMonaGothic</family>
			<family>IPAGothic</family>
			<family>Sazanami Gothic</family>
			<family>Kochi Gothic</family>
			<family>AR PL KaitiM GB</family>
			<family>MS Gothic</family> <!-- han (ja) -->
			<family>UmePlus Gothic</family> <!-- han (ja) -->
			<family>NSimSun</family> <!-- han (zh-cn,zh-tw) -->
			<family>MingLiu</family> <!-- han (zh-tw) -->
			<family>AR PL ShanHeiSun Uni</family> <!-- han (ja,zh-cn,zh-tw) -->
			<family>AR PL New Sung Mono</family> <!-- han (zh-cn,zh-tw) -->
			<family>HanyiSong</family> <!-- han (zh-cn) -->
			<family>AR PL SungtiL GB</family>
			<family>AR PL Mingti2L Big5</family>
			<family>ZYSong18030</family> <!-- han (zh-cn,zh-tw) -->
			<family>NanumGothicCoding</family> <!-- hangul (ko) -->
			<family>NanumGothic</family> <!-- hangul (ko) -->
			<family>UnDotum</family> <!-- hangul (ko) -->
			<family>Baekmuk Dotum</family> <!-- hangul (ko) -->
			<family>Baekmuk Gulim</family> <!-- hangul (ko) -->
			<family>TlwgTypo</family> <!-- thai -->
			<family>TlwgTypist</family> <!-- thai -->
			<family>TlwgTypewriter</family> <!-- thai -->
			<family>TlwgMono</family> <!-- thai -->
			<family>Hasida</family> <!-- hebrew -->
			<family>GF Zemen Unicode</family> <!-- ethiopic -->
			<family>Hapax Berbère</family> <!-- tifinagh -->
			<family>Lohit Bengali</family>
			<family>Lohit Gujarati</family>
			<family>Lohit Hindi</family>
			<family>Lohit Marathi</family>
			<family>Lohit Maithili</family>
			<family>Lohit Kashmiri</family>
			<family>Lohit Konkani</family>
			<family>Lohit Nepali</family>
			<family>Lohit Sindhi</family>
			<family>Lohit Punjabi</family>
			<family>Lohit Tamil</family>
			<family>Meera</family>
			<family>Lohit Malayalam</family>
			<family>Lohit Kannada</family>
			<family>Lohit Telugu</family>
			<family>Lohit Oriya</family>
			<family>LKLUG</family>
		</prefer>
	</alias>
<!--
  system-ui
-->
	<alias>
		<family>system-ui</family>
		<prefer>
			<family>Noto Sans Arabic UI</family><!-- ar -->
			<family>Noto Sans Bengali UI</family><!-- bn -->
			<family>Noto Sans Devanagari UI</family><!-- hi, mai, mr -->
			<family>Noto Sans Gujarati UI</family><!-- gu -->
			<family>Noto Sans Gurmukhi UI</family><!-- pa -->
			<family>Noto Sans Kannada UI</family><!-- kn -->
			<family>Noto Sans Khmer UI</family><!-- km -->
			<family>Noto Sans Lao UI</family><!-- lo -->
			<family>Noto Sans Malayalam UI</family><!-- ml -->
			<family>Noto Sans Myanmar UI</family><!-- my -->
			<family>Noto Sans Oriya UI</family><!-- or -->
			<family>Noto Sans Sinhala UI</family><!-- si -->
			<family>Noto Sans Tamil UI</family><!-- ta -->
			<family>Noto Sans Telugu UI</family><!-- te -->
			<family>Noto Sans Thai UI</family><!-- th -->
			<family>Leelawadee UI</family><!-- bug, th, jv, km, lo -->
			<family>Nirmala UI</family><!-- Indic -->
			<family>Yu Gothic UI</family><!-- han (ja) -->
			<family>Meiryo UI</family><!-- han (ja) -->
			<family>MS UI Gothic</family><!-- han (ja) -->
			<family>Khmer UI</family><!-- km -->
			<family>Lao UI</family><!-- lo -->
			<family>Microsoft YaHei UI</family><!-- han (zh-cn) -->
			<family>Microsoft JhengHei UI</family><!-- han (zh-tw) -->
		</prefer>
	</alias>

</fontconfig>

Last edited by sokuban (2022-11-18 07:37:31)

Offline

#11 2022-11-18 08:01:59

seth
Member
Registered: 2012-09-03
Posts: 50,012

Re: How to edit fontconfig? (to have a precedence order of fonts)

It mentiones neither "Vijaya" nor  "Latha"
Incidentally:

fc-list | grep -i vijaya
grep -i vijaya /etc/fonts/conf.d/* /etc/fonts/fonts.conf /home/ganyi/.fonts.conf

Offline

#12 2022-11-23 11:26:38

sokuban
Member
Registered: 2006-11-11
Posts: 412

Re: How to edit fontconfig? (to have a precedence order of fonts)

I was wondering if I just got the font wrong (I thought it was Vijaya, but I'm really not 100% sure).

$ fc-list | grep -i vijaya
/usr/share/fonts/TTF/vijayab.ttf: Vijaya:style=Bold
/usr/share/fonts/TTF/vijaya.ttf: Vijaya:style=Regular
$ grep -i vijaya /etc/fonts/conf.d/* /etc/fonts/fonts.conf /home/ganyi/.fonts.conf
grep: /etc/fonts/conf.d/49-sansserif.conf.backup: No such file or directory

Yes, that's actually what the second command returns...

Offline

#13 2022-11-23 15:03:35

seth
Member
Registered: 2012-09-03
Posts: 50,012

Re: How to edit fontconfig? (to have a precedence order of fonts)

stat /etc/fonts/conf.d/49-sansserif.conf.backup
ls -l /etc/fonts/conf.d | grep "49-sansserif.conf.backup"

But that's hardly the problem/what gets vijaya resolved.
I missed

sokuban wrote:

<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "urn:fontconfig:fonts.dtd">
<fontconfig>
<alias>
    <family>Sans</family>
    <prefer>
        <family>Noto Sans Tamil</family>
    </prefer>
</alias>
</fontconfig>

The canonical generic name is "sans-serif", there should be an alias for "sans", "Sans" is wrong.

Offline

Board footer

Powered by FluxBB