Bug 518161 - "contains" expression seems not working on the fontconfig rule
Summary: "contains" expression seems not working on the fontconfig rule
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: fontconfig
Version: 12
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Behdad Esfahbod
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 517635
TreeView+ depends on / blocked
 
Reported: 2009-08-19 08:59 UTC by Akira TAGOH
Modified: 2010-11-24 05:16 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-11-24 05:16:25 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
sample fontconfig rule (1.17 KB, text/plain)
2009-08-19 08:59 UTC, Akira TAGOH
no flags Details


Links
System ID Private Priority Status Summary Last Updated
FreeDesktop.org 23419 0 None None None Never

Description Akira TAGOH 2009-08-19 08:59:06 UTC
Created attachment 357904 [details]
sample fontconfig rule

Description of problem:
Even if the pattern contains strings that the rule specifies with "contains" expression, it doesn't match.

Version-Release number of selected component (if applicable):
fontconfig-2.7.1-1.fc12

How reproducible:
always

Steps to Reproduce:
1.install lohit-hindi-fonts and lohit-marathi-fonts
2.put the attached rule into /etc/fonts/conf.d
3.fc-match "sans-serif:lang=mr"
4.fc-match "sans-serif:lang=mr-in"
  
Actual results:
3. lohit_mr.ttf: "Lohit Marathi" "Regular"
4. lohit_hi.ttf: "Lohit Hindi" "Regular"

Expected results:
the result of 3 and 4 should be:
lohit_mr.ttf: "Lohit Marathi" "Regular"


Additional info:
From a debug log:
FcConfigSubstitute test pattern any lang Contains "mr"
FcLangSet mr-in contains mr
        Missing bitmap ku-am
No match

I'm not really sure why fontconfig refers ku-am map here but apparently it looks like fontconfig doesn't know what mr-in is.

Anyway, if no explicit lang pattern is given and applications calls FcDefaultSubstitute(), lang will be set like mr-in from current locale mr_IN.UTF-8 say.

Comment 1 Behdad Esfahbod 2009-08-19 17:05:36 UTC
Upstream please.

Comment 2 Matthias Clasen 2009-08-29 04:33:57 UTC
Behdad, this is fixed now, no ?

Comment 3 Behdad Esfahbod 2009-08-30 20:51:58 UTC
Fixed as far as I'm concerned.  I can't get any of the reporters to confirm it though.

Not in a release yet.  I'll make a fontconfig release with the fix today.

Comment 4 Parag Nemade 2009-08-31 09:18:51 UTC
waiting for upstream release as well as Fedora release and yes I am still not sure about this fix. I thought someone will explain what is difference between
"fc-match" and "fc-match :lang=mr" commands when executed in mr_IN locale. But anyway I have reported one more upstream bug 23601.

Comment 5 Parag Nemade 2009-08-31 09:19:46 UTC
FYI, we have pushed fontconfig rules for lohit-fonts in rawhide now.

Comment 6 Behdad Esfahbod 2009-08-31 19:06:42 UTC
(In reply to comment #4)
> waiting for upstream release as well as Fedora release

So you want me to make a release and push in Fedora, just so you can test the fix and possibly tell me it's not working?

> and yes I am still not sure about this fix.

Then just try it and become sure.

> I thought someone will explain what is difference between
> "fc-match" and "fc-match :lang=mr" commands when executed in mr_IN locale.

As I said upstream numerous times, I have major issues understanding what you were reporting.

> But anyway I have reported one more upstream bug 23601.  

More bugs don't fix anything in themselves.

Comment 7 Behdad Esfahbod 2009-08-31 21:58:09 UTC
Built for f11 and devel.  Pushing update out on f11.  Not sure if I should make any request for f12.

Comment 8 Fedora Update System 2009-08-31 21:59:10 UTC
fontconfig-2.7.2-1.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/fontconfig-2.7.2-1.fc11

Comment 9 Parag Nemade 2009-09-01 04:12:14 UTC
Thanks and now we can see some more input for further request/bug based on new fontconfig release.
we have also got new lohit-fonts with fontconfig rules in rawhide now. So I will test and report back here.

Comment 10 Fedora Update System 2009-09-01 18:08:27 UTC
fontconfig-2.7.2-1.fc11 has been pushed to the Fedora 11 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update fontconfig'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F11/FEDORA-2009-9225

Comment 11 Parag Nemade 2009-09-02 03:16:27 UTC
I confirm my comment #4. fc-match command failed to show "Lohit Marathi" in Marathi locale.

Comment 12 Bug Zapper 2009-11-16 11:32:34 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 12 development cycle.
Changing version to '12'.

More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 13 Jens Petersen 2010-11-04 02:58:41 UTC
Any better with current fontconfig-2.8.0 packages?

Comment 14 Bug Zapper 2010-11-04 10:27:30 UTC
This message is a reminder that Fedora 12 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 12.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '12'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 12's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 12 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 15 Akira TAGOH 2010-11-24 05:16:25 UTC
Since lohit-hindi-fonts and lohit-marathi-fonts merged into lohit-devanagari-fonts, I have no idea to reproduce this. even though lohit-devanagari-fonts still uses "contains" in their config file, I don't see "Missing bitmap" message in Additional Info at comment#0 at least on rawhide.

So let's close this so far and reopen if it still has any issues.

Thanks,


Note You need to log in before you can comment on or make changes to this bug.