Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 0.4.0

Bug #16947 Font-size in GD (with GD2) incorrect
Submitted: 2009-12-27 01:08 UTC
From: neufeind Assigned: doconnor
Status: Closed Package: Image_Canvas (version SVN)
PHP Version: Irrelevant OS:
Roadmaps: (Not assigned)    
Subscription  
Comments Add Comment Add patch


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 3 + 4 = ?

 
 [2009-12-27 01:08 UTC] neufeind (Stefan Neufeind)
Description: ------------ API (phpdoc) says size is always given in pixels (px). That's true for GD1, but GD2 uses points (pt). So to be consistent across output-modules the size-value would need to be converted when using GD2. PS: To allow an easier migration maybe instead of an int/float e.g. 12 it could also be allowed to give as a size "12pt" (string), so everybody currently using "12" (in points, with GD2) has a migration-path - and people wanting to use round pt-values with GD2 don't run into conversion-problems (e.g. 12.0001 or so).

Comments

 [2009-12-27 01:16 UTC] neufeind (Stefan Neufeind)
-Status: Open +Status: Assigned -Package Version: CVS +Package Version: SVN
Work in progress. Current SVN contains a fix to now treat given values consistent across output-drivers (pixels everywhere). That means with GD2 the values are actually converted (pt to px). What still needs some thought before release is a migration-path for people using the "old behavior" (which was not according to API/phpdoc) and by that way maybe also to allow passing values like "pt" or so to e.g. the SVG-output-driver directly.
 [2012-01-02 06:37 UTC] doconnor (Daniel O'Connor)
-Status: Open +Status: Closed -Assigned To: +Assigned To: doconnor
Thank you for your bug report. This issue has been fixed in the latest released version of the package, which you can download at http://pear.php.net/get/ This would have gone out with the QA release 0.3.3