Skip Menu |

This queue is for tickets about the Font-TTF CPAN distribution.

Report information
The Basics
Id: 42553
Status: resolved
Priority: 0/
Queue: Font-TTF

People
Owner: Nobody in particular
Requestors: pjt47 [...] cam.ac.uk
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: 0.47



Subject: maxp version number parsed incorrectly
Date: Tue, 20 Jan 2009 09:52:02 +0000
To: bug-Font-TTF [...] rt.cpan.org
From: Philip Taylor <pjt47 [...] cam.ac.uk>
http://www.microsoft.com/typography/otspec/otff.htm says: "When a Fixed number is used as a version, the upper 16 bits comprise a major version number, and the lower 16 bits a minor. ... For example, the version number of 'maxp' table version 0.5 is 0x00005000." Font::TTF::Maxp does not take this into account. 0x00005000 is parsed as 0.3125 (i.e. 5/16), and then compared against 0.5, which is wrong and breaks. The same issue applies when writing the version number out again. I haven't checked if any other tables have fractional version numbers that will break in the same way. -- Philip Taylor pjt47@cam.ac.uk
Subject: Re: [rt.cpan.org #42553] maxp version number parsed incorrectly
Date: Mon, 26 Jan 2009 15:09:48 +0700
To: bug-Font-TTF [...] rt.cpan.org
From: Martin Hosken <martin_hosken [...] sil.org>
Dear Philip, Thank you for all these bug reports, it's great to nail them. Fixed by adding a new TTF_unpack('v', $dat) type parsing. Can't say I'm entirely sure about the FontRevision in the head table, but I think this is still of type 'f'. I'll get a new version out with these fixes shortly. If you want to monitor the pre-release code there is svn available at http://scripts.sil.org/svn-public/utilities/Font-TTF/trunk On Tue, 20 Jan 2009 04:52:29 -0500 "Philip Taylor via RT" <bug-Font-TTF@rt.cpan.org> wrote: Show quoted text
> Tue Jan 20 04:52:28 2009: Request 42553 was acted upon. > Transaction: Ticket created by pjt47@cam.ac.uk > Queue: Font-TTF > Subject: maxp version number parsed incorrectly > Broken in: (no value) > Severity: (no value) > Owner: Nobody > Requestors: pjt47@cam.ac.uk > Status: new > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=42553 > > > > http://www.microsoft.com/typography/otspec/otff.htm says: "When a Fixed > number is used as a version, the upper 16 bits comprise a major version > number, and the lower 16 bits a minor. ... For example, the version > number of 'maxp' table version 0.5 is 0x00005000." > > Font::TTF::Maxp does not take this into account. 0x00005000 is parsed as > 0.3125 (i.e. 5/16), and then compared against 0.5, which is wrong and > breaks. The same issue applies when writing the version number out again. > > I haven't checked if any other tables have fractional version numbers > that will break in the same way. > > -- > Philip Taylor > pjt47@cam.ac.uk >
Subject: Re: [rt.cpan.org #42553] maxp version number parsed incorrectly
Date: Mon, 26 Jan 2009 16:15:29 +0700
To: bug-Font-TTF [...] rt.cpan.org
From: Martin Hosken <martin_hosken [...] sil.org>
Fixed in 0.46
Subject: Re: [rt.cpan.org #42553] maxp version number parsed incorrectly
Date: Mon, 26 Jan 2009 09:47:48 +0000
To: bug-Font-TTF [...] rt.cpan.org
From: Philip Taylor <pjt47 [...] cam.ac.uk>
martin_hosken@sil.org via RT wrote: Show quoted text
> <URL: http://rt.cpan.org/Ticket/Display.html?id=42553 > > > Dear Philip, > > Thank you for all these bug reports, it's great to nail them.
Thanks for the quick response! Show quoted text
> Fixed by adding a new TTF_unpack('v', $dat) type parsing.
Minor nitpicking: 'eval("0x$frac")' looks a bit nasty - 'hex($frac)' would be safer and more efficient. Show quoted text
> I'll get a new version out with these fixes shortly.
In case it's relevant for release planning, I have a few more bug reports I intend to file within the next few days (hopefully today if I get time). -- Philip Taylor pjt47@cam.ac.uk
On Mon Jan 26 05:35:00 2009, pjt47@cam.ac.uk wrote: Show quoted text
> martin_hosken@sil.org via RT wrote:
> > <URL: http://rt.cpan.org/Ticket/Display.html?id=42553 > > > > > Dear Philip, > > > > Thank you for all these bug reports, it's great to nail them.
> > Thanks for the quick response! >
> > Fixed by adding a new TTF_unpack('v', $dat) type parsing.
> > Minor nitpicking: 'eval("0x$frac")' looks a bit nasty - 'hex($frac)' > would be safer and more efficient. >
> > I'll get a new version out with these fixes shortly.
> > In case it's relevant for release planning, I have a few more bug > reports I intend to file within the next few days (hopefully today if I > get time). >