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

📄 barchart.html

📁 java图形报表制作
💻 HTML
📖 第 1 页 / 共 5 页
字号:
render</H3>
<PRE>
public void <B>render</B>(java.awt.Graphics&nbsp;g)</PRE>
<DL>
<DD>Renders the bar chart according to the current chart attributes and which charts features are turned on or off.<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/objectplanet/chart/Chart.html#render(java.awt.Graphics)">render</A></CODE> in class <CODE><A HREF="../../../com/objectplanet/chart/Chart.html">Chart</A></CODE></DL>
</DD>
<DD>Following copied from class: <CODE>com.objectplanet.chart.Chart</CODE></DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>g</CODE> - The graphics context used to paint with.<DT><B>See Also: </B><DD><A HREF="../../../com/objectplanet/chart/Chart.html#paint(java.awt.Graphics)"><CODE>Chart.paint(java.awt.Graphics)</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="renderData(java.awt.Graphics, java.awt.Rectangle, java.awt.Rectangle)"><!-- --></A><H3>
renderData</H3>
<PRE>
protected void <B>renderData</B>(java.awt.Graphics&nbsp;g,                          java.awt.Rectangle&nbsp;grid,                          java.awt.Rectangle&nbsp;dataBounds)</PRE>
<DL>
<DD>Renders the bars and the value labels.<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/objectplanet/chart/Chart.html#renderData(java.awt.Graphics, java.awt.Rectangle, java.awt.Rectangle)">renderData</A></CODE> in class <CODE><A HREF="../../../com/objectplanet/chart/Chart.html">Chart</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>g</CODE> - The graphics context used to paint with.<DD><CODE>grid</CODE> - The grid bounds to paint within.<DD><CODE>dataBounds</CODE> - The scrolled data bounds to calculate the bars from.</DL>
</DD>
</DL>
<HR>

<A NAME="reset()"><!-- --></A><H3>
reset</H3>
<PRE>
public void <B>reset</B>()</PRE>
<DL>
<DD>Resets the chart data and features.<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/objectplanet/chart/Chart.html#reset()">reset</A></CODE> in class <CODE><A HREF="../../../com/objectplanet/chart/Chart.html">Chart</A></CODE></DL>
</DD>
</DL>
<HR>

<A NAME="setAutoLabelSpacingOn(boolean)"><!-- --></A><H3>
setAutoLabelSpacingOn</H3>
<PRE>
public void <B>setAutoLabelSpacingOn</B>(boolean&nbsp;on)</PRE>
<DL>
<DD>Turns on or off automatic bar label spacing. If this is on, only bar labels there is space for will be painted. If turned off, all labels will be painted, even if they overlap. It is turned off by default.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>on</CODE> - True for on, false for off.</DL>
</DD>
</DL>
<HR>

<A NAME="setBarAlignment(int)"><!-- --></A><H3>
setBarAlignment</H3>
<PRE>
public void <B>setBarAlignment</B>(int&nbsp;alignment)</PRE>
<DL>
<DD>Sets the bar alignment. The default alignment is vertical.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>alignment</CODE> - HORIZONTAL or VERTICAL.<DT><B>Throws:</B><DD><CODE>java.lang.IllegalArgumentException</CODE> - If the alignment is not valid.</DL>
</DD>
</DL>
<HR>

<A NAME="setBarLabels(java.lang.String[])"><!-- --></A><H3>
setBarLabels</H3>
<PRE>
public void <B>setBarLabels</B>(java.lang.String[]&nbsp;labels)</PRE>
<DL>
<DD>Sets the bar labels. By default, the bar labels are read from the sampleLabels. Setting this, overrides the sampleLabels.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>labels</CODE> - The labels, or null for default behavior.<DT><B>See Also: </B><DD><A HREF="../../../com/objectplanet/chart/BarChart.html#setBarLabelsOn(boolean)"><CODE>setBarLabelsOn(boolean)</CODE></A>, 
<A HREF="../../../com/objectplanet/chart/Chart.html#setSampleLabels(java.lang.String[])"><CODE>Chart.setSampleLabels(java.lang.String[])</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="setBarLabelsOn(boolean)"><!-- --></A><H3>
setBarLabelsOn</H3>
<PRE>
public void <B>setBarLabelsOn</B>(boolean&nbsp;on)</PRE>
<DL>
<DD>Turns on or off the bar labels. The bar labels are the same as the labels in the legend, but are displayed at the base of the bar itself.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>on</CODE> - True if the bar labels should be displayed.<DT><B>See Also: </B><DD><A HREF="../../../com/objectplanet/chart/Chart.html#setSampleLabel(int, java.lang.String)"><CODE>Chart.setSampleLabel(int, java.lang.String)</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="setBarLabelStyle(int)"><!-- --></A><H3>
setBarLabelStyle</H3>
<PRE>
public void <B>setBarLabelStyle</B>(int&nbsp;style)</PRE>
<DL>
<DD>Sets the bar label style. The bar labels can either be painted below the bar itself, or as a floating label over the bar when the mouse pointer moves over it.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>style</CODE> - BELOW, FLOATING, BELOW_AND_FLOATING.</DL>
</DD>
</DL>
<HR>

<A NAME="setBarOutlineColor(java.awt.Color)"><!-- --></A><H3>
setBarOutlineColor</H3>
<PRE>
public void <B>setBarOutlineColor</B>(java.awt.Color&nbsp;color)</PRE>
<DL>
<DD>Sets the color used for the bar outline. If color is null, chart foreground is used<DD><DL>
<DT><B>Parameters:</B><DD><CODE>color</CODE> - The color to set.</DL>
</DD>
</DL>
<HR>

<A NAME="setBarOutlineOn(boolean)"><!-- --></A><H3>
setBarOutlineOn</H3>
<PRE>
public void <B>setBarOutlineOn</B>(boolean&nbsp;on)</PRE>
<DL>
<DD>Turns on or off the bar outline. The bar outline is the frame drawn around each bar. The bar outline is turned on by default.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>on</CODE> - True if on, false for off.</DL>
</DD>
</DL>
<HR>

<A NAME="setBarType(int)"><!-- --></A><H3>
setBarType</H3>
<PRE>
public void <B>setBarType</B>(int&nbsp;type)</PRE>
<DL>
<DD>Sets the bar type in multiple series charts.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>type</CODE> - STACKED_BARS or SIDE_BY_SIDE_BARS.<DT><B>Throws:</B><DD><CODE>java.lang.IllegalArgumentException</CODE> - If the type is not valid.</DL>
</DD>
</DL>
<HR>

<A NAME="setBarWidth(double)"><!-- --></A><H3>
setBarWidth</H3>
<PRE>
public void <B>setBarWidth</B>(double&nbsp;width)</PRE>
<DL>
<DD>Sets the relative width of each bar. If the width is set to 1.0, there will be no space between the bars. If the width is set to 0.5, the space between each bar will be the same as the width of the bar. If you have side-by-side bars in the chart, it is the combined width of a sample that is set.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>width</CODE> - The width fraction to use (0.0 to 1.0).</DL>
</DD>
</DL>
<HR>

<A NAME="setMultiColorOn(boolean)"><!-- --></A><H3>
setMultiColorOn</H3>
<PRE>
public void <B>setMultiColorOn</B>(boolean&nbsp;on)</PRE>
<DL>
<DD>Turns on or off multi-color bar display.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>on</CODE> - True for multi-color, false for single-color.</DL>
</DD>
</DL>
<HR>

<A NAME="setMultiSeriesOn(boolean)"><!-- --></A><H3>
setMultiSeriesOn</H3>
<PRE>
public void <B>setMultiSeriesOn</B>(boolean&nbsp;state)</PRE>
<DL>
<DD>Makes the chart behave like it does when it has multiple data series, even if it has only one. The labels in the chart will then always be the series labels, and not change to the sample labels when the number of data series changes to one.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>state</CODE> - True for on, false for off.</DL>
</DD>
</DL>
<HR>

<A NAME="setValueLabelStyle(int)"><!-- --></A><H3>
setValueLabelStyle</H3>
<PRE>
public void <B>setValueLabelStyle</B>(int&nbsp;style)</PRE>
<DL>
<DD>Sets the value label style.<DD><DL>
<DT><B>Parameters:</B><DD><CODE>style</CODE> - INSIDE, OUTSIDE, FLOATING.<DT><B>Throws:</B><DD><CODE>java.lang.IllegalArgumentException</CODE> - If the style is invalid.</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>

<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_bottom"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT C

⌨️ 快捷键说明

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