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

Bug #5415 Axis's wrong when plot is Dot/Scatter
Submitted: 2005-09-15 15:14 UTC
From: james dot kilbride at gd-ais dot com Assigned: nosey
Status: Closed Package: Image_Graph
PHP Version: 5.0.5 OS: Red Hat Linux 7.3
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 : 5 - 4 = ?

 
 [2005-09-15 15:14 UTC] james dot kilbride at gd-ais dot com
Description: ------------ The axis do not seem to be putting values in the correct locations on the axis, causing overlaps of values making the axis unreadable. This happens on both the X and Y axis. There are no errors in the log file. Test script: --------------- Change test file category.php near end to read: ... * which they exist "before" in the dataset on their first occurence) */ $Plot =& $Plotarea->addNew('scatter', $DS); $Marker =& Image_Graph::factory('Image_Graph_Marker_Cross'); $Marker->setFillColor('blue'); $Marker->setLineColor('black'); // set a line color $Plot->setMarker($Marker); $Graph->done(); Expected result: ---------------- I expect the axis to be well ordered without gaps and no overlapping. Actual result: -------------- Odd gaps are formed and there is overlapping displays of text which makes it unreadable and useless.

Comments

 [2005-09-15 17:42 UTC] nosey
Hmmm... this is weird. What seems to happen is that if you have _2_ plots it actually works, but if you have only 1 then it shows very wrong!
 [2005-09-15 17:57 UTC] james dot kilbride at gd-ais dot com
This is not purely a 1 plot issue. I can provide you with code that has dual plots(both scatters) which reproduces the issues. I'll put togethor a data set that does it. I have a suspicion it has something to do with the datasets themselves and how the axis are created from the data sets.
 [2005-09-15 18:08 UTC] james dot kilbride at gd-ais dot com
Change data set in category.php to: $DS =& Image_Graph::factory('dataset'); $DS->addPoint('Apache', 'Open Source'); $DS->addPoint('BSD', 'Open Source'); $DS->addPoint('Linux', 'Open Source'); $DS->addPoint('Microsoft', 'Proprietary'); $DS->addPoint('Micro', 'Proprietary'); $DS->addPoint('Minisoft', 'Proprie'); $DS->addPoint('Millisoft', 'Prop'); $DS2 =& Image_Graph::factory('dataset'); $DS->addPoint('Apache', 'Open Source'); $DS->addPoint('BSD', 'Open Source'); $DS->addPoint('Linux', 'Open Source'); $DS->addPoint('Microsoft', 'Proprietary'); $DS->addPoint('Micro', 'Proprietary'); $DS->addPoint('Minisoft', 'Proprie'); $DS->addPoint('Miniority', 'Proprias'); And change plot code to: $Plot =& $Plotarea->addNew('scatter', $DS); //$Plot->setLineColor('red'); $Plot2 =& $Plotarea->addNew('scatter', $DS2); //$Plot2->setLineColor('blue'); $Marker =& Image_Graph::factory('Image_Graph_Marker_Cross'); $Marker->setFillColor('blue'); $Marker->setLineColor('black'); // set a line color $Plot->setMarker($Marker); $Marker =& Image_Graph::factory('Image_Graph_Marker_Cross'); $Marker->setFillColor('red'); $Marker->setLineColor('black'); // set a line color $Plot2->setMarker($Marker); $Graph->done(); This duplicates the problem with 2 plots.
 [2005-10-02 19:25 UTC] nosey
This bug has been fixed in CVS. 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.