Bug 82125

Summary: Creates bogus 'bold' entries in fonts.scale
Product: [Retired] Red Hat Raw Hide Reporter: Enrico Scholz <rh-bugzilla>
Component: ttmkfdirAssignee: Yu Shao <yshao>
Status: CLOSED RAWHIDE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 1.0CC: eng-i18n-bugs
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2003-01-19 23:51:15 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Enrico Scholz 2003-01-17 21:37:13 UTC
Description of problem:

'ttmkfdir' creates bold *and* medium entries for regular fonts:

-----
## install e.g. ttfonts-ja
$ cp /usr/share/fonts/ja/TrueType/kochi-gothic.ttf .
$ ttmkfdir
$ cat fonts.scale
...
kochi-gothic.ttf -misc-Kochi Gothic-bold-r-normal--0-0-0-0-c-0-adobe-standard
...
kochi-gothic.ttf -misc-Kochi Gothic-medium-r-normal--0-0-0-0-c-0-adobe-standard
...
-----

This seems to happens with any regular ttf font and is bad because application
which are trying to display bold fonts are using the medium style.



Version-Release number of selected component (if applicable):

ttmkfdir-3.0.7-1

Comment 1 Yu Shao 2003-01-18 13:12:02 UTC
Yeah, that is intented behavior, but right now, ttmkfdir will only do that for X
FreeType backend. 

The reason we do it this way is current FreeType backend still can not generate
bold and italic fonts, with those extra bogus entries, applications can be more
robust.     

There was one old KDE bug(also in bugzilla, couldn't find it now) that if there
are no bold or italic entries, the corresponding bold or italic characters will
be unreadable. Not sure if the bug is still with KDE, but I think there are
other applictions still can not handle it.

Comment 2 Enrico Scholz 2003-01-18 16:09:10 UTC
This new behavior causes problems when both regular and bold fonts are
installed. E.g. when using M$ webfonts, I have arial-medium in arial.ttf and
arial-bold in arialbd.ttf. 'ttmkfdir' creates the following entries in fonts.scale:

| arial.ttf -monotype-Arial-medium-r-normal--0-0-0-0-p-0-ascii-0
| ...
| arial.ttf   -monotype-Arial-bold-r-normal--0-0-0-0-p-0-ascii-0
| arialbd.ttf -monotype-Arial-bold-r-normal--0-0-0-0-p-0-ascii-0

When having an application which wants to use 'arial-bold', xfs chooses the
first matching entry. In this case this is the regular font from arial.ttf and
the application will display the information non-boldly although a bold font is
available.

I think that applications should be fixed which are not robust without
bold/italic fonts. On the first glance, omitting additional 'bold' entries seems
to prevent this problem but this does not work when 'arial.ttf' and
'arialbd.ttf' are in different directories.

Comment 3 Yu Shao 2003-01-19 23:51:15 UTC
Yeah, I thought about this before, but if there are fonts like those, I will
revert it. Thanks!