Skip Menu |

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

Report information
The Basics
Id: 37825
Status: resolved
Priority: 0/
Queue: Font-FreeType

People
Owner: Nobody in particular
Requestors: TIMBRODY [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 0.04
Fixed in: 0.04



(With patch applied) I have 3 test cases failing that are all related to changes in how freetype interprets BDF fonts. # Failed test 'fixed size x resolution 75dpi' # at t/10metrics_5x7bdf.t line 87. # Failed test 'fixed size y resolution 75dpi' # at t/10metrics_5x7bdf.t line 88. It appears that freetype 2.1.9 introduced some changes to the API that change the way the number of glyphs and metrics of BDF fonts are calculated. Here's the current calculation of y_ppem: prop = bdf_get_font_property( font, "PIXEL_SIZE" ); if ( prop ) bsize->y_ppem = (FT_Short)prop->value.int32 << 6; And x_ppem: bsize->x_ppem = bsize->y_ppem * resolution_x / resolution_y; To me this looks like freetype is ignoring the DPI specified in the BDF file (except as a ratio), therefore I don't see how Font::FreeType can recover the DPI for BDF-type fonts? And got: '1837' # expected: '1836' Since 2.1.9 freetype includes a "default glyph" in the glyph count for BDF fonts, causing an off-by-one error for the test case. I don't feel I understand what is going on enough to offer solutions, just that this will hopefully save someone some debug time.
On Mon Jul 21 11:20:21 2008, TIMBRODY wrote: Show quoted text
> (With patch applied)
Show quoted text
> It appears that freetype 2.1.9 introduced some changes to the API that > change the way the number of glyphs and metrics of BDF fonts are calculated.
Thanks for the bug report. It seems that results for the failing tests are library-version depended. So, I decided to remove them at all. If you have better solution, patches/pull requests are welcome!