$lineplot->Setcolor("blue");
had no result. Nor did
$lineplot->SetWeight(2);
Eventually, I sent off an enquiry to jpGraph - and back came a very prompt reply (from the Far East):
in version 3.5.0b1, methods to change designs of each plot should be used after $graph->add($plot) method.
This is really counter-intuitive. But it works.
So it goes like this
$bplot = new BarPlot($data1y);
$graph->Add($bplot);
// NOW change properties of the plot - these work ONLY after calling Add()
$bplot->SetWeight(0);
$bplot->SetFillGradient('#FFAAAA:0.7', '#FFAAAA:1.2', GRAD_VER);
There is a note in the documentation included as part of the package, at:
jpgraph-3.5.0b1/docs/chunkhtml/ch29s02.html
7 comments:
Thank you!
Thank you. This really helped me out.
Thank you. I just wish I had found your very useful post much earlier!
I've bookmarked your blog on the strength of this, and will keep it in mind whenever I run into problems - thanks again.
Thanks. Their included example files have it wrong, so this helped heaps :)
Thank you, found a solution via google at stackoverflow and then here. Began doubting my own sanity.
thanks :)
Super helpful, many thanks
Post a Comment