Bug 1009350 - generated output looks not correct
Summary: generated output looks not correct
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: xorg-x11-fonts
Version: 19
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Hans de Goede
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 1007493
TreeView+ depends on / blocked
 
Reported: 2013-09-18 09:18 UTC by Akira TAGOH
Modified: 2014-11-13 18:14 UTC (History)
7 users (show)

Fixed In Version: xorg-x11-fonts-7.5-11.fc21
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-11-01 16:37:53 UTC


Attachments (Terms of Use)
proposed patch to avoid checking the undefined character range. (565 bytes, patch)
2014-10-16 10:19 UTC, Akira TAGOH
no flags Details | Diff
fix for jisx0201.1976-0.enc.gz (279 bytes, patch)
2014-10-17 06:33 UTC, Akira TAGOH
no flags Details | Diff

Description Akira TAGOH 2013-09-18 09:18:24 UTC
Description of problem:
This is output with sazanami fonts:
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-ascii-0
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-iso10646-1
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-iso8859-1
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-iso8859-15
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-iso8859-9
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-jisx0208.1983-0
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-jisx0208.1990-0

Apparently there are no jisx0201.1976-0 for that.

Version-Release number of selected component (if applicable):
ttmkfdir-3.0.9-39.fc19.x86_64

How reproducible:
always

Steps to Reproduce:
1.ttmkfdir -d /path/to/sazanami/font
2.see the generated fonts.scale
3.

Actual results:
no jisx0201.1976-0

Expected results:
should be there

Additional info:
http://en.wikipedia.org/wiki/JIS_X_0201 for more details of JIS X 0201
1976 is a revision number for this spec.

Comment 1 Parag Nemade 2013-09-19 09:00:47 UTC
when I try to reproduce this I got fonts.scale with its contents as
5
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-ascii-0
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-iso10646-1
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-iso8859-1
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-iso8859-15
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-iso8859-9

whereas stock fonts.scale on system is
7
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-ascii-0
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-iso10646-1
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-iso8859-1
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-iso8859-15
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-iso8859-9
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-jisx0208.1983-0
sazanami-gothic.ttf -misc-Sazanami Gothic-medium-r-normal--0-0-0-0-c-0-jisx0208.1990-0

so exactly what is missing or required? this bug description says no entry for jisx0201.1976-0 in fonts.scale whereas other bug https://bugzilla.redhat.com/show_bug.cgi?id=1007493#c4

Comment 2 Akira TAGOH 2013-09-19 09:38:49 UTC
Did you try that with xorg-x11-fonts-misc installed?

Anyway, I see the same result to the system's here and of course presuming that is missing jisx0201.1976-0 as I mentioned the above.

Comment 3 Parag Nemade 2013-09-19 10:21:37 UTC
Thanks. I have installed now xorg-x11-fonts-misc package. Now, I got the same output as system installed fonts.scale

Comment 4 Akira TAGOH 2014-10-16 09:56:11 UTC
got back to investigate this issue. after taking a look at this a bit, I noticed that the problem is ttmkfdir is going to check the undefined area in the encoding maps. for instance, jisx0201.1976-0.enc.gz has:

STARTMAPPING unicode
0x5C    0x00A5  # YEN SIGN
0x7E    0x203E  # OVERLINE
0x00A1 0x00DF 0xFF61
ENDMAPPING

this defines 65 characters on the map but ttmkfdir tries to check the undefined ranges like between 0x5d and 0x7d, and between 0x7f and 0xa0. this is the unexpected behavior.

Comment 5 Akira TAGOH 2014-10-16 10:19:06 UTC
Created attachment 947548 [details]
proposed patch to avoid checking the undefined character range.

I don't have too much testing with it. there might be a regression perhaps.

Comment 6 Pravin Satpute 2014-10-17 05:51:28 UTC
I think we need to create some test cases to avoid regression.

1. Generating fonts.scale for all installed fonts. 

2. Generating fonts.scale for all installed fonts with updated ttmkfdir.

3. Comparing them for possible regression.

How do you find this idea?

Comment 7 Akira TAGOH 2014-10-17 06:31:25 UTC
Oh, wrong patch. the document for the format of the encoding files says, "Codes not listed are assumed to map through the identity (i.e. to the same numerical value). In order to override this default mapping, you may specify a range of codes to be undefined by using an `UNDEFINE' line"

So where we need to fix seems the encoding file then.

Comment 8 Akira TAGOH 2014-10-17 06:33:34 UTC
Created attachment 947790 [details]
fix for jisx0201.1976-0.enc.gz

Comment 9 Hans de Goede 2014-10-23 12:02:41 UTC
(In reply to Akira TAGOH from comment #8)
> Created attachment 947790 [details]
> fix for jisx0201.1976-0.enc.gz

Thanks, I'm preparing an updated xorg-x11-fonts package with this patch included, and I'll also send it upstream.

Comment 10 Fedora Update System 2014-10-23 12:20:31 UTC
xorg-x11-fonts-7.5-11.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/xorg-x11-fonts-7.5-11.fc21

Comment 11 Fedora Update System 2014-10-23 16:21:16 UTC
Package xorg-x11-fonts-7.5-11.fc21:
* should fix your issue,
* was pushed to the Fedora 21 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing xorg-x11-fonts-7.5-11.fc21'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-13532/xorg-x11-fonts-7.5-11.fc21
then log in and leave karma (feedback).

Comment 12 Fedora Update System 2014-11-01 16:37:53 UTC
xorg-x11-fonts-7.5-11.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 13 Akira TAGOH 2014-11-10 08:55:14 UTC
Is it possible to backport the fix for f20 too?

Comment 14 Simone Caronni 2014-11-10 09:43:14 UTC
(In reply to Akira TAGOH from comment #13)
> Is it possible to backport the fix for f20 too?

Doing it now.

Comment 15 Fedora Update System 2014-11-10 10:10:26 UTC
xorg-x11-fonts-7.5-10.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/xorg-x11-fonts-7.5-10.fc20

Comment 16 Fedora Update System 2014-11-13 18:14:06 UTC
xorg-x11-fonts-7.5-10.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.


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