[Fontconfig] Query for unknown font with spacing=mono returns sans-serif font
akira at tagoh.org
Wed Nov 10 10:38:01 UTC 2021
On Wed, Nov 10, 2021 at 2:14 PM Christian Weiske <cweiske at cweiske.de> wrote:
> Hello Akira,
> > Speaking of your example, the problem there is RFont3 isn't a known
> > font for your system and fontconfig doesn't also know what it is and
> > what the generic family they are. if RFont3 is the monospaced font,
> > the proper fix here would be to have a config file like:
> > <alias>
> > <family>RFont3</family>
> > <default><family>monospace</family></default>
> > </alias>
> > Or do they have different spacing with one family name?
> RFont3 is a monospaced font in one PDF file, but non-monospaced (sans
> serif) in the next PDF file. So a hard mapping like you showed here is
> not possible.
> But poppler also sends the hint to fontconfig that it wants a
> monospaced font ("$ fc-match RFont3:spacing=mono").
> Shouldn't fontconfig use that hint and return a monospaced font?
In theory, yes. We may need similar things for :spacing=charcell and
> Regards/Mit freundlichen Grüßen
> Christian Weiske
> -=≡ Geeking around in the name of science since 1982 ≡=-
More information about the Fontconfig