miunsi63 / gflot

Automatically exported from code.google.com/p/gflot
0 stars 0 forks source link

Setwidth not working #28

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.Use one of the classes from the example (e.g. SimplePlot)
2.Set width to 100%

What is the expected output? What do you see instead?
At least 1024px width plot. The plot is always 600x300px

What version of the product are you using? On what operating system?
GWT 2.0.0 and flot 1.0.0

Please provide any additional information below.
Maybe I'm doing something wrong? There's no additional documentation for me so 
I thought I'd file an issue...

Original issue reported on code.google.com by pkacz...@gmail.com on 2 Aug 2010 at 4:51

GoogleCodeExporter commented 9 years ago
Edit: only setWidth(String) is not working properly. setWidth(int) is ok...

Original comment by pkacz...@gmail.com on 3 Aug 2010 at 8:06

GoogleCodeExporter commented 9 years ago
setWidth("300px") is working. If you want to define a width in percentage, you 
have to set the width of the parent. The following code is working for me :

SimplePlot plot = new SimplePlot( model, plotOptions );
plot.setWidth( "80%" );
plot.setHeight( "40%" );
SimplePanel panel = new SimplePanel(plot);
panel.setSize( "800px", "800px" );

Original comment by nmr.morel on 4 Jan 2012 at 9:14