Re: fc-match for monospace?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ah, excellent, "fc-match mono", that works.

However, I'm confused as to what exactly the pattern syntax is there.
I thought patterns had to be in :foo=bar form, or repetitions thereof.
Since "fc-match mono" gave me "Bitstream Vera Sans Mono", I thought
that perhaps it was doing a caseless substring match on the text
"mono" in the font name. So, I did an "fc-match DejaVu" to test this
theory, but it failed to return any of the DejaVu fonts on my system.

Thought it's working now, I'm still very confused as to what is going on.

What is "fc-match mono" doing, _exactly_?

Is this pattern syntax documented anywhere? I tried looking to the
FcNameParse() documentation for help, but no luck.

-Patrick


On Fri, Sep 25, 2009 at 9:36 PM, Behdad Esfahbod <behdad@xxxxxxxxxx> wrote:
> On 09/25/2009 06:25 PM, Patrick M. Rutkowski wrote:
>>
>> I'm very confused about how "fc-match" is supposed to work.
>>
>> I run something like: `fc-match :spacing=mono`, or the synonym
>> `fc-match :spacing=100`, yet it does NOT give me a monospace font as I
>> expected. I instead get:
>>
>> Vera.ttf "Bitstream Vera Sans" "Roamn"
>>
>> At the same time, `fc-list :spacing=mono fullname` shows that there
>> are indeed monospace fonts on the system
>> ...
>> :fullname=Free Monospaced
>> :fullname=DejaVu Sans Mono
>> ...
>>
>> What's the deal here?
>
> If you check fcmatch.c, you see that FC_SPACING has a lower priority than
> FC_FAMILY, so that's matched first.
>
>> I want to integrate libfreetype in my application for font searching
>> in the Linux port. Is it really the case that I won't be able to do
>> things like allow the user to ask for a monospace font and ACTUALLY
>> GET ONE? (instead of Bitstream Vera Sans).
>
> The right way to do that is to "fc-match monospace"
>
> Cheers,
> behdad
>
>> Many thanks in advance
>> -Patrick
>
_______________________________________________
Fontconfig mailing list
Fontconfig@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/fontconfig

[Index of Archives]     [Fedora Fonts]     [Fedora Users]     [Fedora Cloud]     [Kernel]     [Fedora Packaging]     [Fedora Desktop]     [PAM]     [Gimp Graphics Editor]     [Yosemite News]

  Powered by Linux