⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 jfreechart.html

📁 JFreeChart 9.20的文档 需要用JAVA在网页上做统计图的东东
💻 HTML
📖 第 1 页 / 共 5 页
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"><!--NewPage--><HTML><HEAD><!-- Generated by javadoc (build 1.4.2_03) on Mon Jun 07 16:42:27 BST 2004 --><TITLE>JFreeChart (JFreeChart Class Library (version 0.9.20))</TITLE><META NAME="keywords" CONTENT="org.jfree.chart.JFreeChart class"><LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style"><SCRIPT type="text/javascript">function windowTitle(){    parent.document.title="JFreeChart (JFreeChart Class Library (version 0.9.20))";}</SCRIPT></HEAD><BODY BGCOLOR="white" onload="windowTitle();"><!-- ========= START OF TOP NAVBAR ======= --><A NAME="navbar_top"><!-- --></A><A HREF="#skip-navbar_top" title="Skip navigation links"></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""><TR><TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_top_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">  <TR ALIGN="center" VALIGN="top">  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>  </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">&nbsp;<A HREF="../../../org/jfree/chart/DrawableLegendItem.html" title="class in org.jfree.chart"><B>PREV CLASS</B></A>&nbsp;&nbsp;<A HREF="../../../org/jfree/chart/Legend.html" title="class in org.jfree.chart"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="../../../index.html" target="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="JFreeChart.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;&nbsp;<SCRIPT type="text/javascript">  <!--  if(window==top) {    document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');  }  //--></SCRIPT><NOSCRIPT>  <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A></NOSCRIPT></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_top"></A><!-- ========= END OF TOP NAVBAR ========= --><HR><!-- ======== START OF CLASS DATA ======== --><H2><FONT SIZE="-1">org.jfree.chart</FONT><BR>Class JFreeChart</H2><PRE>java.lang.Object  <IMG SRC="../../../resources/inherit.gif" ALT="extended by"><B>org.jfree.chart.JFreeChart</B></PRE><DL><DT><B>All Implemented Interfaces:</B> <DD>java.lang.Cloneable, org.jfree.ui.Drawable, java.util.EventListener, <A HREF="../../../org/jfree/chart/event/LegendChangeListener.html" title="interface in org.jfree.chart.event">LegendChangeListener</A>, <A HREF="../../../org/jfree/chart/event/PlotChangeListener.html" title="interface in org.jfree.chart.event">PlotChangeListener</A>, java.io.Serializable, <A HREF="../../../org/jfree/chart/event/TitleChangeListener.html" title="interface in org.jfree.chart.event">TitleChangeListener</A></DD></DL><HR><DL><DT>public class <B>JFreeChart</B><DT>extends java.lang.Object<DT>implements org.jfree.ui.Drawable, <A HREF="../../../org/jfree/chart/event/TitleChangeListener.html" title="interface in org.jfree.chart.event">TitleChangeListener</A>, <A HREF="../../../org/jfree/chart/event/LegendChangeListener.html" title="interface in org.jfree.chart.event">LegendChangeListener</A>, <A HREF="../../../org/jfree/chart/event/PlotChangeListener.html" title="interface in org.jfree.chart.event">PlotChangeListener</A>, java.io.Serializable, java.lang.Cloneable</DL><P>A chart class implemented using the Java 2D APIs.  The current version supports bar charts, line charts, pie charts and xy plots (including time series data). <P> JFreeChart coordinates several objects to achieve its aim of being able to draw a chart on a Java 2D graphics device: a list of <A HREF="../../../org/jfree/chart/title/Title.html" title="class in org.jfree.chart.title"><CODE>Title</CODE></A> objects, a <A HREF="../../../org/jfree/chart/Legend.html" title="class in org.jfree.chart"><CODE>Legend</CODE></A>, a <A HREF="../../../org/jfree/chart/plot/Plot.html" title="class in org.jfree.chart.plot"><CODE>Plot</CODE></A> and a <A HREF="../../../org/jfree/data/Dataset.html" title="interface in org.jfree.data"><CODE>Dataset</CODE></A> (the plot in turn manages a horizontal axis and a vertical axis). <P> You should use a <A HREF="../../../org/jfree/chart/ChartPanel.html" title="class in org.jfree.chart"><CODE>ChartPanel</CODE></A> to display a chart in a GUI. <P> The <A HREF="../../../org/jfree/chart/ChartFactory.html" title="class in org.jfree.chart"><CODE>ChartFactory</CODE></A> class contains static methods for creating 'ready-made' charts.<P><P><DL><DT><B>See Also:</B><DD><A HREF="../../../org/jfree/chart/ChartPanel.html" title="class in org.jfree.chart"><CODE>ChartPanel</CODE></A>, <A HREF="../../../org/jfree/chart/ChartFactory.html" title="class in org.jfree.chart"><CODE>ChartFactory</CODE></A>, <A HREF="../../../org/jfree/chart/title/Title.html" title="class in org.jfree.chart.title"><CODE>Title</CODE></A>, <A HREF="../../../org/jfree/chart/Legend.html" title="class in org.jfree.chart"><CODE>Legend</CODE></A>, <A HREF="../../../org/jfree/chart/plot/Plot.html" title="class in org.jfree.chart.plot"><CODE>Plot</CODE></A>, <A HREF="../../../serialized-form.html#org.jfree.chart.JFreeChart">Serialized Form</A></DL><HR><P><!-- ======== NESTED CLASS SUMMARY ======== --><!-- =========== FIELD SUMMARY =========== --><A NAME="field_summary"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=2><FONT SIZE="+2"><B>Field Summary</B></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;java.awt.Image</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#DEFAULT_BACKGROUND_IMAGE">DEFAULT_BACKGROUND_IMAGE</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The default background image.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#DEFAULT_BACKGROUND_IMAGE_ALIGNMENT">DEFAULT_BACKGROUND_IMAGE_ALIGNMENT</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The default background image alignment.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;float</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#DEFAULT_BACKGROUND_IMAGE_ALPHA">DEFAULT_BACKGROUND_IMAGE_ALPHA</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The default background image alpha.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;java.awt.Paint</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#DEFAULT_BACKGROUND_PAINT">DEFAULT_BACKGROUND_PAINT</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The default background color.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;java.awt.Font</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#DEFAULT_TITLE_FONT">DEFAULT_TITLE_FONT</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The default font for titles.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;org.jfree.ui.about.ProjectInfo</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#INFO">INFO</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Information about the project.</TD></TR></TABLE>&nbsp;<!-- ======== CONSTRUCTOR SUMMARY ======== --><A NAME="constructor_summary"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=2><FONT SIZE="+2"><B>Constructor Summary</B></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#JFreeChart(org.jfree.chart.plot.Plot)">JFreeChart</A></B>(<A HREF="../../../org/jfree/chart/plot/Plot.html" title="class in org.jfree.chart.plot">Plot</A>&nbsp;plot)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs a chart.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#JFreeChart(java.lang.String, java.awt.Font, org.jfree.chart.plot.Plot, boolean)">JFreeChart</A></B>(java.lang.String&nbsp;title,           java.awt.Font&nbsp;titleFont,           <A HREF="../../../org/jfree/chart/plot/Plot.html" title="class in org.jfree.chart.plot">Plot</A>&nbsp;plot,           boolean&nbsp;createLegend)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs a chart.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#JFreeChart(java.lang.String, org.jfree.chart.plot.Plot)">JFreeChart</A></B>(java.lang.String&nbsp;title,           <A HREF="../../../org/jfree/chart/plot/Plot.html" title="class in org.jfree.chart.plot">Plot</A>&nbsp;plot)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a new chart.</TD></TR></TABLE>&nbsp;<!-- ========== METHOD SUMMARY =========== --><A NAME="method_summary"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=2><FONT SIZE="+2"><B>Method Summary</B></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#addChangeListener(org.jfree.chart.event.ChartChangeListener)">addChangeListener</A></B>(<A HREF="../../../org/jfree/chart/event/ChartChangeListener.html" title="interface in org.jfree.chart.event">ChartChangeListener</A>&nbsp;listener)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Registers an object for notification of changes to the chart.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#addProgressListener(org.jfree.chart.event.ChartProgressListener)">addProgressListener</A></B>(<A HREF="../../../org/jfree/chart/event/ChartProgressListener.html" title="interface in org.jfree.chart.event">ChartProgressListener</A>&nbsp;listener)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Registers an object for notification of progress events relating to the chart.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#addSubtitle(org.jfree.chart.title.Title)">addSubtitle</A></B>(<A HREF="../../../org/jfree/chart/title/Title.html" title="class in org.jfree.chart.title">Title</A>&nbsp;subtitle)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a chart subtitle, and notifies registered listeners that the chart has been modified.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;java.lang.Object</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#clone()">clone</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Clones the object, and takes care of listeners.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;java.awt.image.BufferedImage</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#createBufferedImage(int, int)">createBufferedImage</A></B>(int&nbsp;width,                    int&nbsp;height)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates and returns a buffered image into which the chart has been drawn.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;java.awt.image.BufferedImage</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#createBufferedImage(int, int, org.jfree.chart.ChartRenderingInfo)">createBufferedImage</A></B>(int&nbsp;width,                    int&nbsp;height,                    <A HREF="../../../org/jfree/chart/ChartRenderingInfo.html" title="class in org.jfree.chart">ChartRenderingInfo</A>&nbsp;info)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates and returns a buffered image into which the chart has been drawn.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;java.awt.image.BufferedImage</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#createBufferedImage(int, int, double, double, org.jfree.chart.ChartRenderingInfo)">createBufferedImage</A></B>(int&nbsp;imageWidth,                    int&nbsp;imageHeight,                    double&nbsp;drawWidth,                    double&nbsp;drawHeight,                    <A HREF="../../../org/jfree/chart/ChartRenderingInfo.html" title="class in org.jfree.chart">ChartRenderingInfo</A>&nbsp;info)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates and returns a buffered image into which the chart has been drawn.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;java.awt.image.BufferedImage</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#createBufferedImage(int, int, int, org.jfree.chart.ChartRenderingInfo)">createBufferedImage</A></B>(int&nbsp;width,                    int&nbsp;height,                    int&nbsp;imageType,                    <A HREF="../../../org/jfree/chart/ChartRenderingInfo.html" title="class in org.jfree.chart">ChartRenderingInfo</A>&nbsp;info)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates and returns a buffered image into which the chart has been drawn.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#draw(java.awt.Graphics2D, java.awt.geom.Rectangle2D)">draw</A></B>(java.awt.Graphics2D&nbsp;g2,     java.awt.geom.Rectangle2D&nbsp;area)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Draws the chart on a Java 2D graphics device (such as the screen or a printer).</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/jfree/chart/JFreeChart.html#draw(java.awt.Graphics2D, java.awt.geom.Rectangle2D, org.jfree.chart.ChartRenderingInfo)">draw</A></B>(java.awt.Graphics2D&nbsp;g2,     java.awt.geom.Rectangle2D&nbsp;area,     <A HREF="../../../org/jfree/chart/ChartRenderingInfo.html" title="class in org.jfree.chart">ChartRenderingInfo</A>&nbsp;info)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Draws the chart on a Java 2D graphics device (such as the screen or a printer).</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -