Search found 1087 matches

by skunk
Mon Nov 29, 2010 7:14 pm
Forum: JFreeChart
Topic: plot background change 8 to 13
Replies: 3
Views: 3651

Re: plot background change 8 to 13

Code: Select all

ChartFactory.setChartTheme(ChartTheme.createLegacyTheme());
should restore the old defaults.
Also search the list. There are a few isolated cases (like shadows on bar charts) that require further code changes.
by skunk
Fri Nov 26, 2010 6:21 pm
Forum: JFreeChart
Topic: line that goes back on itself
Replies: 1
Views: 2369

Re: line that goes back on itself

Use this constructor instead

Code: Select all

public XYSeries(java.lang.Comparable key, boolean autoSort)
and pass false for the autoSort parameter
by skunk
Fri Nov 26, 2010 3:34 pm
Forum: JFreeChart
Topic: Text font size resized when the chart panel is reized
Replies: 4
Views: 6048

Re: Text font size resized when the chart panel is reized

This "feature" is affected by these ChartPanel methods

Code: Select all

public void setMaximumDrawHeight(int height)
public void setMinimumDrawHeight(int height)
public void setMaximumDrawWidth(int width)
public void setMinimumDrawWidth(int width)
Adjust accordingly if you want better control over font sizing
by skunk
Wed Nov 24, 2010 10:12 pm
Forum: JFreeChart - Stockmarket
Topic: how to creeate IE 6 friendly png graphics??
Replies: 3
Views: 11056

Re: how to creeate IE 6 friendly png graphics??

ChartUtilities contains two different methods to generate a PNG file from a chart public static void saveChartAsPNG(java.io.File file, JFreeChart chart, int width, int height, ChartRenderingInfo info) throws java.io.IOException and public static void saveChartAsPNG(java.io.File file, JFreeChart char...
by skunk
Tue Nov 23, 2010 6:48 pm
Forum: JFreeChart
Topic: Clickable imagemap/tooltip for Axes (or ValueAxis) labels
Replies: 1
Views: 2566

Re: Clickable imagemap/tooltip for Axes (or ValueAxis) labels

If you look at the implementation of this method in org.jfree.chart.axis.NumberAxis public AxisState draw(java.awt.Graphics2D g2, double cursor, java.awt.geom.Rectangle2D plotArea, java.awt.geom.Rectangle2D dataArea, org.jfree.ui.RectangleEdge edge, PlotRenderingInfo plotState) You will see that the...
by skunk
Mon Nov 22, 2010 5:38 pm
Forum: JFreeChart
Topic: How to change the XYDotRenderer default colors?
Replies: 2
Views: 3428

Re: How to change the XYDotRenderer default colors?

Subclass the renderer and override this method

Code: Select all

public java.awt.Paint getItemPaint(int row, int column)
to return whatever value you want. Use the row(=series) and column(=index) arguments to look up the data value being plotted.

http://www.jfree.org/phpBB2/viewtopic.php?f=3&t=17397
by skunk
Sat Nov 20, 2010 11:13 pm
Forum: JFreeChart
Topic: Showing Tick for CatagoryAxis
Replies: 1
Views: 2569

Re: Showing Tick for CatagoryAxis

Any time you need to skip category axis labels is a sign that you should be using an XYPlot instead of a CategoryPlot. There are some hackish solutions posted on this list but in my opinion you would be better off using the correct classes instead.
by skunk
Sat Nov 20, 2010 11:09 pm
Forum: JFreeChart
Topic: How to set the height of a bar chart to a minimum data value
Replies: 2
Views: 4656

Re: How to set the height of a bar chart to a minimum data value

Assuming I understand your requirements correctly, I don't believe what you are looking for is supported out of the box rangeAxis.setRange(0, 5); will always use 5 as the maximum, even if the maximum is 10. If you wanted to use 5 as the maximum except when the real maximum is > 5, then you would nee...
by skunk
Fri Nov 19, 2010 12:39 am
Forum: JFreeChart
Topic: XYDrawableAnnotation Bug - Set MarkerDemo1 to HorizontalMode
Replies: 3
Views: 4944

Re: XYDrawableAnnotation Bug - Set MarkerDemo1 to HorizontalMode

The draw() method of XYDrawableAnnotation looks like it needs to be modified Currently it contains these lines float j2DX = (float) domainAxis.valueToJava2D(this.x, dataArea, domainEdge); float j2DY = (float) rangeAxis.valueToJava2D(this.y, dataArea, rangeEdge); Perhaps this would work better float ...
by skunk
Wed Nov 17, 2010 10:25 pm
Forum: JFreeChart
Topic: is it possible to set the zoom possibility on the frame?
Replies: 1
Views: 2285

Re: is it possible to set the zoom possibility on the frame?

Sure. Add the button to the container of the chart. Then call whichever of the many zoom*() methods defined in org.jfree.chart.plot.CategoryPlot and org.jfree.chart.plot.XYPlot is appropriate depending on whether you wish to zoom in/out by a certain fixed amount.
by skunk
Wed Nov 17, 2010 2:59 pm
Forum: JFreeChart
Topic: Question on DateAxis set with lowerMargin and upperMargin
Replies: 4
Views: 4464

Re: Question on DateAxis set with lowerMargin and upperMargin

setMimumumDate() and setMaximumDate() end up calling ValueAxis::setRange(...), you need to call ValueAxis::setRangeWithMargins(...) instead. I have never tried this and hopefully it will do the right thing with a segmentedTimeLine.
by skunk
Wed Nov 17, 2010 2:46 pm
Forum: JFreeChart
Topic: Ignoring Zero values in Line Graph
Replies: 6
Views: 6922

Re: Ignoring Zero values in Line Graph

Did you try replacing the 0 with Double.NaN
by skunk
Wed Nov 17, 2010 2:45 pm
Forum: JFreeChart
Topic: Change ValueAxis position
Replies: 2
Views: 3583

Re: Change ValueAxis position

Code: Select all

public void setRangeAxisLocation(AxisLocation location)