[Fontconfig] Search for fonts by full name
Evgeniy Stepanov
eugeni.stepanov at gmail.com
Sun Jun 8 11:46:29 PDT 2008
Hi,
I'd like to be able to use full font names in match pattern. The first
attached patch implements this. It is to be applied on top of Isaiah
Beerbower's patch (the one with postscript names).
There is a problem with it that also happens when matching fonts by postscript
names. Not every font have a full name or a postscript name. Such fonts get a
score of 0 (the best possible), while fonts that have a non-matching name get
a score of 100. This results in fonts being selected based on other
parameters (because both fonts with matching name and without a name get 0
for full name test).
To fix this, the second patch gives the worst possible score to those match
values that were not updated. Alternatively, the third patch makes sure that
every font has a full name, making it up from it's family and style if
needed. Either one of them is enough to make this feature work.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 01-score-missing-elements-as-1e99
Type: text/x-diff
Size: 972 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/fontconfig/attachments/20080608/fb5cfb6c/attachment.diff
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 02-search-by-fullname
Type: text/x-diff
Size: 4352 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/fontconfig/attachments/20080608/fb5cfb6c/attachment-0001.diff
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 03-always-set-fullname
Type: text/x-diff
Size: 911 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/fontconfig/attachments/20080608/fb5cfb6c/attachment-0002.diff
More information about the Fontconfig
mailing list