// Decompiled by Jad v1.5.8e2. Copyright 2001 Pavel Kouznetsov. // Jad home page: http://kpdus.tripod.com/jad.html // Decompiler options: packimports(3) fieldsfirst ansi space package demo; import java.awt.Color; import java.io.*; import org.jfree.chart.*; import org.jfree.chart.axis.NumberAxis; import org.jfree.chart.entity.StandardEntityCollection; import org.jfree.chart.imagemap.ImageMapUtilities; import org.jfree.chart.plot.PlotOrientation; import org.jfree.chart.plot.XYPlot; // Referenced classes of package demo: // SampleXYDataset2 public class ImageMapDemo5 { public ImageMapDemo5() { } public static void main(String args[]) { SampleXYDataset2 samplexydataset2 = new SampleXYDataset2(); JFreeChart jfreechart = ChartFactory.createScatterPlot("Scatter Plot Demo", "X", "Y", samplexydataset2, PlotOrientation.VERTICAL, true, true, false); jfreechart.setBackgroundPaint(Color.white); XYPlot xyplot = (XYPlot)jfreechart.getPlot(); NumberAxis numberaxis = (NumberAxis)xyplot.getDomainAxis(); numberaxis.setAutoRangeIncludesZero(false); try { ChartRenderingInfo chartrenderinginfo = new ChartRenderingInfo(new StandardEntityCollection()); File file = new File("scatter100.png"); ChartUtilities.saveChartAsPNG(file, jfreechart, 600, 400, chartrenderinginfo); File file1 = new File("scatter100.html"); BufferedOutputStream bufferedoutputstream = new BufferedOutputStream(new FileOutputStream(file1)); PrintWriter printwriter = new PrintWriter(bufferedoutputstream); printwriter.println(""); printwriter.println(""); printwriter.println("JFreeChart Image Map Demo"); printwriter.println("

"); ImageMapUtilities.writeImageMap(printwriter, "chart", chartrenderinginfo); printwriter.println("\"scatter100.png\"/"); printwriter.println("

"); printwriter.println(""); printwriter.close(); } catch (IOException ioexception) { System.out.println(ioexception.toString()); } } }