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

Bug #16834 Column width error, small PHP typo (fix incl.)
Submitted: 2009-11-25 00:06 UTC
From: mpetrov Assigned: neufeind
Status: Closed Package: Image_Graph (version CVS)
PHP Version: 5.3.0 OS: Mac OSX
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 : 10 + 13 = ?

 
 [2009-11-25 00:06 UTC] mpetrov (Michael Petrov)
Description: ------------ Line 386 of /Image/Graph/Plot.php calculates the COLUMN_WIDTH of a marker point. This calculation currently does not properly take the absolute value of the X1 X2 difference due to a typo in PHP. Current code: $point['COLUMN_WIDTH'] = abs($point['MARKER_X2'] - ($point['MARKER_X1']) / count($this->_dataset)); Should be: $point['COLUMN_WIDTH'] = abs($point['MARKER_X2'] - $point['MARKER_X1']) / count($this->_dataset); This error causes markers to be placed at very random locations throughout the graph on a bar graph. This sample from your site demonstrates this issue as well: http://pear.veggerby.dk/samples/show/id/plot_bar_multiple/

Comments

 [2009-12-02 05:03 UTC] doconnor (Daniel O'Connor)
-Status: Open +Status: Feedback
A small executable test case will get you a lot further, I'd suggest.
 [2009-12-06 08:25 UTC] neufeind (Stefan Neufeind)
-Status: Feedback +Status: Closed -Assigned To: +Assigned To: neufeind
This bug has been fixed in SVN. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better. Yes of course, you're right. Thank you for pointing that out.