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

Bug #11898 SVG background fill does not fill to the edge
Submitted: 2007-08-23 14:16 UTC
From: sandermarechal Assigned:
Status: Open Package: Image_Graph (version 0.7.2)
PHP Version: 5.2.0 OS: Linux (Debian Etch)
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 : 8 - 3 = ?

 
 [2007-08-23 14:16 UTC] sandermarechal (Sander Marechal)
Description: ------------ When I create an SVG graph and specify that the background must be filled, Image_Graph does not fill all the way to the edge. There remains a little transparent edge on the right and bottom side. Run the test script below and view the resulting SVG file. Make sure that in your viewer you select something like bright red to show transparent areas. You can see a red line at the right and bottom edge. Test script: --------------- #!/usr/bin/php -q <?php require_once('Image/Graph.php'); $graph =& Image_Graph::factory('graph', array(array('width' => 400, 'height' => 300, 'canvas' => 'svg'))); $graph->setBackgroundColor('white'); $graph->add($plotarea = Image_Graph::factory('plotarea')); $color_array =& Image_Graph::factory('Image_Graph_Fill_Array'); $color_array->addColor('red'); $color_array->addColor('green'); $color_array->addColor('blue'); $dataset =& Image_Graph::factory('dataset'); $dataset->addPoint(0, 8); $dataset->addPoint(1, 7); $dataset->addPoint(2, 9); $plot =& $plotarea->addNew('bar', array(array($dataset), 'stacked')); $plot->setFillStyle($color_array); $graph->done(array('filename' => 'test.svg')); ?> Expected result: ---------------- A graph with the entire background white. Actual result: -------------- A graph where the bottom and right edge are transparent.

Comments