Bug 26718 - "fc-match sans file" doesn't work
Summary: "fc-match sans file" doesn't work
Alias: None
Product: fontconfig
Classification: Unclassified
Component: fc-match (show other bugs)
Version: 2.7
Hardware: Other All
: medium normal
Assignee: Keith Packard
QA Contact: Behdad Esfahbod
Depends on:
Reported: 2010-02-23 13:26 UTC by Behdad Esfahbod
Modified: 2011-09-04 18:14 UTC (History)
3 users (show)

See Also:
i915 platform:
i915 features:


Note You need to log in before you can comment on or make changes to this bug.
Description Behdad Esfahbod 2010-02-23 13:26:59 UTC
Don't remember exactly why (I did track it down once).  Anyway, should switch the utilities to FcPatternFormat().
Comment 1 Akira TAGOH 2011-01-07 00:52:40 UTC
That looks like because FcNameUnparse() ignores FC_FILE only. what's wrong with simply getting rid of "!strcmp (o->object, FC_FILE)" from the expression?

Using FcPatternFormat() may be an idea. but the issue would be how to get the better "format" string against the FcObjectSet.

Once getting rid of the above code, the result looks like:
% ./fc-match/fc-match sans file
Comment 3 Behdad Esfahbod 2011-06-20 08:12:33 UTC
That's not enough.  I guess your change breaks fc-list.  I'll fix by switching fc-list et al. to using FcPatternFormat() I guess.
Comment 4 Behdad Esfahbod 2011-06-20 08:23:44 UTC
commit e0be405a1dd5765e36152c754a47c8ad7ff0ab85
Author: Behdad Esfahbod <behdad@behdad.org>
Date:   Mon Jun 20 11:22:17 2011 -0400

    Bug 26718 - "fc-match sans file" doesn't work
    - Do not throw away FC_FILE in FcNameUnparse
    - Update the builtin "fclist" format to remove FC_FILE properly instead
    - Switch fc-list to use FcPatternFormat()
    Note that I had previously broken fc-list and it was not showing the
    file name anymore.  No one noticed that it seems!  Now fixed.
Comment 5 Akira TAGOH 2011-06-20 19:45:30 UTC
Aha, thanks. works fine for me.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.