DynamicPDF by ceTe Software

com.cete.dynamicpdf.pageelements.charting
Class Chart

java.lang.Object
  extended by com.cete.dynamicpdf.PageElement
      extended by com.cete.dynamicpdf.pageelements.TaggablePageElement
          extended by com.cete.dynamicpdf.pageelements.RotatingPageElement
              extended by com.cete.dynamicpdf.pageelements.charting.Chart
All Implemented Interfaces:
ICoordinate

public class Chart
extends RotatingPageElement

This class can be used to place a chart on the page.

Licensing:
This is a DynamicPDF Generator Enterprise Edition feature. One of the following licenses is required for non-evaluation usage:

View Example


Constructor Summary
Chart(float x, float y, float width, float height)
          Initializes a new instance of the Chart class.
Chart(float x, float y, float width, float height, Font font, float fontSize, Color textColor)
          Initializes a new instance of the Chart class.
 
Method Summary
protected  void drawRotated(PageWriter writer)
          Draws the chart to the given PageWriter object.
 boolean getAutoLayout()
          Gets whether elements should be arranged automatically on the chart or not.
 Color getBackgroundColor()
          Gets the Color object to use for the background of the chart.
 Color getBorderColor()
          Gets the Color object to use for the border of the chart.
 LineStyle getBorderStyle()
          Gets the LineStyle object to use for the border style of the chart.
 float getBorderWidth()
          Gets the border width of the chart.
 float getBottomPadding()
          Gets the bottom padding of the chart.
 float getChartLegendSpacing()
          Gets the chart legend spacing of the chart.
 Font getFont()
          Gets the Font object to use for the text in the chart.
 float getFontSize()
          Gets the font size of the text in the chart.
 TitleList getFooterTitles()
          Gets the footer TitleList object contained in the chart.
 TitleList getHeaderTitles()
          Gets the header TitleList object contained in the chart.
 float getHeight()
          Gets the height of the chart.
 float getLeftPadding()
          Gets the left padding of the chart.
 LegendList getLegends()
          Gets the LegendList object contained in the chart.
 PlotAreaList getPlotAreas()
          Gets the PlotAreaList object contained in the chart.
 PlotArea getPrimaryPlotArea()
          Gets the Default PlotArea of the Chart.
 float getRightPadding()
          Gets the right padding of the chart.
 Color getTextColor()
          Gets the Color object to use for the text of the chart.
 float getTopPadding()
          Gets the top padding of the chart.
 float getWidth()
          Gets the width of the chart.
 float getX()
          Gets the x coordinate of the chart.
 float getY()
          Gets the y coordinate of the chart.
 void layout()
          Arranges all elements of chart automatically.
 void setAutoLayout(boolean autoLayout)
          Sets whether elements should be arranged automatically on the chart or not.
 void setBackgroundColor(Color color)
          Sets the Color object to use for the background of the chart.
 void setBorderColor(Color color)
          Sets the Color object to use for the border of the chart.
 void setBorderStyle(LineStyle lineStyle)
          Sets the LineStyle object to use for the border style of the chart.
 void setBorderWidth(float borderWidth)
          Sets the border width of the chart.
 void setBottomPadding(float bottomPadding)
          Sets the bottom padding of the chart.
 void setChartLegendSpacing(float chartLegendSpacing)
          Sets the chart legend spacing of the chart.
 void setFont(Font font)
          Sets the Font object to use for the text in the chart.
 void setFontSize(float val)
          sets the font size of the text in the chart.
 void setHeight(float height)
          Sets the height of the chart.
 void setLeftPadding(float leftPadding)
          Sets the left padding of the chart.
 void setRightPadding(float rightPadding)
          Sets the right padding of the chart.
 void setTopPadding(float topPadding)
          Sets the top padding of the chart.
 void setWidth(float width)
          Sets the width of the chart.
 void setX(float x)
          Sets the x coordinate of the chart.
 void setY(float y)
          Sets the y coordinate of the chart.
 
Methods inherited from class com.cete.dynamicpdf.pageelements.RotatingPageElement
draw, getAngle, setAngle
 
Methods inherited from class com.cete.dynamicpdf.pageelements.TaggablePageElement
getTag, getTagOrder, setTag, setTagOrder
 
Methods inherited from class com.cete.dynamicpdf.PageElement
getRequiredLicenseLevel, getStrID, setRequiredLicenseLevel, setStrID
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Chart

public Chart(float x,
             float y,
             float width,
             float height)
Initializes a new instance of the Chart class.

Parameters:
x - float value indicating X coordinate of the chart.
y - float value indicating Y coordinate of the chart.
width - float value indicating width of the chart.
height - float value indicating height of the chart.

Chart

public Chart(float x,
             float y,
             float width,
             float height,
             Font font,
             float fontSize,
             Color textColor)
Initializes a new instance of the Chart class.

Parameters:
x - float value indicating X coordinate of the chart.
y - float value indicating Y coordinate of the chart.
width - float value indicating width of the chart.
height - float value indicating height of the chart.
font - Font for the text in the chart.
fontSize - font size for the text in the chart.
textColor - Color for the text in the chart.
Method Detail

getX

public float getX()
Gets the x coordinate of the chart.

Specified by:
getX in interface ICoordinate
Overrides:
getX in class RotatingPageElement
Returns:
the float value specifying x coordinate of the chart.

setX

public void setX(float x)
Sets the x coordinate of the chart.

Specified by:
setX in interface ICoordinate
Overrides:
setX in class RotatingPageElement
Parameters:
x - the float value used to set x coordinate of the chart.

getY

public float getY()
Gets the y coordinate of the chart.

Specified by:
getY in interface ICoordinate
Overrides:
getY in class RotatingPageElement
Returns:
the float value specifying y coordinate of the chart.

setY

public void setY(float y)
Sets the y coordinate of the chart.

Specified by:
setY in interface ICoordinate
Overrides:
setY in class RotatingPageElement
Parameters:
y - the float value used to set y coordinate of the chart.

getWidth

public float getWidth()
Gets the width of the chart.

Returns:
the float value specifying width of the chart.

setFont

public void setFont(Font font)
Sets the Font object to use for the text in the chart.

Parameters:
font - the Font object used to set the font of the text in the chart.
See Also:
Font

setFontSize

public void setFontSize(float val)
sets the font size of the text in the chart.

Parameters:
val - the float value uset to set font size of the text in chart.

setWidth

public void setWidth(float width)
Sets the width of the chart.

Parameters:
width - the float value used to set width of the chart.

getHeight

public float getHeight()
Gets the height of the chart.

Overrides:
getHeight in class RotatingPageElement
Returns:
the float value specifying height of the chart.

getPrimaryPlotArea

public PlotArea getPrimaryPlotArea()
Gets the Default PlotArea of the Chart.

Returns:
PlotArea The default PlotArea of the chart.

setHeight

public void setHeight(float height)
Sets the height of the chart.

Overrides:
setHeight in class RotatingPageElement
Parameters:
height - the float value used to set height of the chart.

setLeftPadding

public void setLeftPadding(float leftPadding)
Sets the left padding of the chart.

Parameters:
leftPadding - the float value used to set left padding of the chart.

getLeftPadding

public float getLeftPadding()
Gets the left padding of the chart.

Returns:
the float value specifying left padding of the chart.

setRightPadding

public void setRightPadding(float rightPadding)
Sets the right padding of the chart.

Parameters:
rightPadding - the float value used to set right padding of the chart.

getRightPadding

public float getRightPadding()
Gets the right padding of the chart.

Returns:
the float value specifying right padding of the chart.

setTopPadding

public void setTopPadding(float topPadding)
Sets the top padding of the chart.

Parameters:
topPadding - the float value used to set top padding of the chart.

getTopPadding

public float getTopPadding()
Gets the top padding of the chart.

Returns:
the float value specifying top padding of the chart.

setBottomPadding

public void setBottomPadding(float bottomPadding)
Sets the bottom padding of the chart.

Parameters:
bottomPadding - the float value used to set bottom padding of the chart.

getBottomPadding

public float getBottomPadding()
Gets the bottom padding of the chart.

Returns:
the float value specifying bottom padding of the chart.

setChartLegendSpacing

public void setChartLegendSpacing(float chartLegendSpacing)
Sets the chart legend spacing of the chart.

Parameters:
chartLegendSpacing - the float value used to set chart legend spacing of the chart.

getChartLegendSpacing

public float getChartLegendSpacing()
Gets the chart legend spacing of the chart.

Returns:
the float value specifying chart legend spacing of the chart.

getFooterTitles

public TitleList getFooterTitles()
Gets the footer TitleList object contained in the chart.

Returns:
the list of footer titles.
See Also:
TitleList

getHeaderTitles

public TitleList getHeaderTitles()
Gets the header TitleList object contained in the chart.

Returns:
the list of header titles.
See Also:
TitleList

getPlotAreas

public PlotAreaList getPlotAreas()
Gets the PlotAreaList object contained in the chart.

Returns:
the list of plot areas.
See Also:
PlotAreaList

getLegends

public LegendList getLegends()
Gets the LegendList object contained in the chart.

Returns:
the list of legends.
See Also:
LegendList

getFont

public Font getFont()
Gets the Font object to use for the text in the chart.

Returns:
the font of the chart.
See Also:
Font

getFontSize

public float getFontSize()
Gets the font size of the text in the chart.

Returns:
the float value specifying font size of the text in chart.

getTextColor

public Color getTextColor()
Gets the Color object to use for the text of the chart.

Returns:
the text color of the chart.
See Also:
Color

getBackgroundColor

public Color getBackgroundColor()
Gets the Color object to use for the background of the chart.

Returns:
the background color of the chart.
See Also:
Color

setBackgroundColor

public void setBackgroundColor(Color color)
Sets the Color object to use for the background of the chart.

Parameters:
color - Color object to set the background color of the chart.
See Also:
Color

getBorderColor

public Color getBorderColor()
Gets the Color object to use for the border of the chart.

Returns:
the border color of the chart.
See Also:
Color

setBorderColor

public void setBorderColor(Color color)
Sets the Color object to use for the border of the chart.

Parameters:
color - Color object to set the border color of the chart
See Also:
Color

getBorderWidth

public float getBorderWidth()
Gets the border width of the chart.

Returns:
the float value specifying border width of the chart.

setBorderWidth

public void setBorderWidth(float borderWidth)
Sets the border width of the chart.

Parameters:
borderWidth - the float value used to set border width of chart.

getAutoLayout

public boolean getAutoLayout()
Gets whether elements should be arranged automatically on the chart or not.

Returns:
boolean value indicating whether elements should be arranged automatically on the chart or not, true by default.

setAutoLayout

public void setAutoLayout(boolean autoLayout)
Sets whether elements should be arranged automatically on the chart or not.

Parameters:
autoLayout - boolean value indicating whether elements should be arranged automatically on the chart or not, true by default.

getBorderStyle

public LineStyle getBorderStyle()
Gets the LineStyle object to use for the border style of the chart.

Returns:
the LineStyle object to use for border style of the chart.
See Also:
LineStyle

setBorderStyle

public void setBorderStyle(LineStyle lineStyle)
Sets the LineStyle object to use for the border style of the chart.

Parameters:
lineStyle - the LineStyle object used to set border style of the chart.
See Also:
LineStyle

drawRotated

protected void drawRotated(PageWriter writer)
Draws the chart to the given PageWriter object.

Specified by:
drawRotated in class RotatingPageElement
Parameters:
writer - PageWriter object to receive the chart's output.
See Also:
PageWriter

layout

public void layout()
Arranges all elements of chart automatically.


DynamicPDF by ceTe Software

API Reference for DynamicPDF v10.04 for Java generated on September 25, 2019
© Copyright 2019, ceTe Software