net.sourceforge.chart2d
Class GraphProperties

java.lang.Object
  |
  +--net.sourceforge.chart2d.GraphProperties

public final class GraphProperties
extends java.lang.Object

A data structure for holding the properties common to all graph area objects. A graph area is the rectangular region surrounded on two sides by axes and containing either lines, dots, or bars as graph components. Pass this to any number of GraphChart2D objects.


Field Summary
static java.awt.AlphaComposite ALPHA_COMPOSITE_MEDIUM
          A medium transparent (some blending) alpha composite.
static java.awt.AlphaComposite ALPHA_COMPOSITE_MILD
          A mildly transparent (some blending) alpha composite.
static java.awt.AlphaComposite ALPHA_COMPOSITE_NONE
          An opaque (no blending) alpha composite.
static int BOTTOM
          Indicates the bottom of something.
static int COMPONENT
          Indicates only the component.
static float[] CONTINUOUS
          Indicates the lines will be continuous.
static float[] DASHED
          Indicates the lines will be dashed.
static float[] DOTTED
          Indicates the lines will be dotted.
static int GRAPH
          Indicates only the graph.
static boolean GRAPH_ALLOW_COMPONENT_ALIGNMENT_DEFAULT
          The default is false.
static java.awt.Color GRAPH_BACKGROUND_COLOR_DEFAULT
          The default is Color.white.
static boolean GRAPH_BACKGROUND_EXISTENCE_DEFAULT
          The default is false.
static float GRAPH_BARS_EXCESS_SPACE_FEEDBACK_RATIO_DEFAULT
          The default is 1f.
static boolean GRAPH_BARS_EXISTENCE_DEFAULT
          The default is true.
static float GRAPH_BARS_ROUNDING_RATIO_DEFAULT
          The default is .75f.
static int GRAPH_BARS_THICKNESS_MODEL_DEFAULT
          The default is 10.
static float GRAPH_BARS_WITHIN_CATEGORY_OVERLAP_RATIO_DEFAULT
          The default is .535f.
static boolean GRAPH_BETWEEN_COMPONENTS_GAP_EXISTENCE_DEFAULT
          The default is true.
static int GRAPH_BETWEEN_COMPONENTS_GAP_THICKNESS_MODEL_DEFAULT
          The default is 2.
static boolean GRAPH_BORDER_EXISTENCE_DEFAULT
          The default is true.
static java.awt.Color GRAPH_BORDER_LEFT_BOTTOM_COLOR_DEFAULT
          The default is Color.black.
static java.awt.Color GRAPH_BORDER_RIGHT_TOP_COLOR_DEFAULT
          The default is Color.gray.
static int GRAPH_BORDER_THICKNESS_MODEL_DEFAULT
          The default is 2.
static java.awt.AlphaComposite GRAPH_COMPONENTS_ALPHA_COMPOSITE_DEFAULT
          The default is ALPHA_COMPOSITE_NONE.
static int GRAPH_COMPONENTS_LIGHT_SOURCE_DEFAULT
          The default is TOP.
static int GRAPH_COMPONENTS_LIGHT_TYPE_DEFAULT
          The default is COMPONENT.
static boolean GRAPH_COMPONENTS_OVERFLOW_CLIP_DEFAULT
          The default is true.
static float GRAPH_DOTS_EXCESS_SPACE_FEEDBACK_RATIO_DEFAULT
          The default is 0f.
static boolean GRAPH_DOTS_EXISTENCE_DEFAULT
          The default is false.
static int GRAPH_DOTS_THICKNESS_MODEL_DEFAULT
          The default is 8.
static float GRAPH_DOTS_WITHIN_CATEGORY_OVERLAP_RATIO_DEFAULT
          The default is .40f.
static java.awt.Color GRAPH_LABELS_LINES_COLOR_DEFAULT
          The default is Color.gray.
static boolean GRAPH_LABELS_LINES_EXISTENCE_DEFAULT
          The default is false.
static float[] GRAPH_LABELS_LINES_STYLE_DEFAULT
          The default is CONTINUOUS.
static int GRAPH_LABELS_LINES_THICKNESS_MODEL_DEFAULT
          The default is 2.
static float GRAPH_LINES_EXCESS_SPACE_FEEDBACK_RATIO_DEFAULT
          The default is 0f.
static boolean GRAPH_LINES_EXISTENCE_DEFAULT
          The default is false.
static boolean GRAPH_LINES_FILL_INTERIOR_DEFAULT
          The default is false.
static boolean GRAPH_LINES_THICKNESS_ASSOCIATION_DEFAULT
          The default is true.
static int GRAPH_LINES_THICKNESS_MODEL_DEFAULT
          The default is 5.
static float GRAPH_LINES_WITHIN_CATEGORY_OVERLAP_RATIO_DEFAULT
          The default is 0f.
static java.awt.Color GRAPH_NUMBERS_LINES_COLOR_DEFAULT
          The default is Color.gray.
static boolean GRAPH_NUMBERS_LINES_EXISTENCE_DEFAULT
          The default is true.
static float[] GRAPH_NUMBERS_LINES_STYLE_DEFAULT
          The default is CONTINUOUS.
static int GRAPH_NUMBERS_LINES_THICKNESS_MODEL_DEFAULT
          The default is 2.
static java.awt.Color GRAPH_OUTLINE_COMPONENTS_COLOR_DEFAULT
          The default is Color.black.
static boolean GRAPH_OUTLINE_COMPONENTS_EXISTENCE_DEFAULT
          The default is false.
static int LEFT
          Indicates the left of something.
static int NONE
          Indicates none.
static int RIGHT
          Indicates the right of something.
static int TOP
          Indicates the top of something.
 
Constructor Summary
GraphProperties()
          Creates a GraphProperties object with the documented default values.
GraphProperties(net.sourceforge.chart2d.GraphProperties graphProps)
          Creates a GraphProperties object with property values copied from another object.
 
Method Summary
 boolean getGraphAllowComponentAlignment()
          Gets whether the graph's components (ie bars, dots, or lines) are allowed to overlap/align or are offset for each set and within each category.
 java.awt.Color getGraphBackgroundColor()
          Gets the color of the background of this graph.
 boolean getGraphBackgroundExistence()
          Gets whether the background of this graph exists.
 float getGraphBarsExcessSpaceFeedbackRatio()
          Gets the amount of the excess space to feed back to bars thickness.
 boolean getGraphBarsExistence()
          Gets whether the graph contains bar components.
 float getGraphBarsRoundingRatio()
          Gets the degree of rounding for the bars.
 int getGraphBarsThicknessModel()
          Gets the thickness of the bar components for the chart's model size.
 float getGraphBarsWithinCategoryOverlapRatio()
          Gets how much the bars can overlap eachother when there are multiple data values per data set and per data category.
 boolean getGraphBetweenComponentsGapExistence()
          Gets whether a gap between each category of components exists (ie not the gap between each each component with each category).
 int getGraphBetweenComponentsGapThicknessModel()
          Gets the thickness of the gap between each category of components for the chart's model size.
 boolean getGraphBorderExistence()
          Gets whether the graph's left and bottom border exists.
 java.awt.Color getGraphBorderLeftBottomColor()
          Gets the color of the graph's left and bottom border.
 java.awt.Color getGraphBorderRightTopColor()
          Gets the color of the graph's right and top border.
 int getGraphBorderThicknessModel()
          Gets the thickness of the graph's left and bottom border for the chart's model size.
 java.awt.AlphaComposite getGraphComponentsAlphaComposite()
          Gets the actual AlphaComposite object to use on the Graphics2D object context for painting the graph components managed by this GraphProperties object.
 int getGraphComponentsLightSource()
          Gets the direction of the source of the light if any.
 int getGraphComponentsLightType()
          Gets the type of the lighting affect.
 boolean getGraphComponentsOverflowClip()
          Gets whether the graph's components will be clipped if they pass over the graph's inner space or border.
 float getGraphDotsExcessSpaceFeedbackRatio()
          Gets the amount of the excess space to feed back to dots thickness.
 boolean getGraphDotsExistence()
          Gets whether the graph contains dot components.
 int getGraphDotsThicknessModel()
          Gets the thickness of the dot components for the chart's model size.
 float getGraphDotsWithinCategoryOverlapRatio()
          Gets how much the dots can overlap eachother when there are multiple data values per data set and per data category.
 java.awt.Color getGraphLabelsLinesColor()
          Gets the color of the vertical lines of this graph.
 boolean getGraphLabelsLinesExistence()
          Gets whether the vertical lines of this graph exist.
 float[] getGraphLabelsLinesStyle()
          Gets the style of the vertical lines of this graph.
 int getGraphLabelsLinesThicknessModel()
          Gets the thickness of the vertical lines of this graph for the chart's model size.
 float getGraphLinesExcessSpaceFeedbackRatio()
          Gets the amount of the excess space to feed back to lines thickness.
 boolean getGraphLinesExistence()
          Gets whether the graph contains line components.
 boolean getGraphLinesFillInterior()
          Gets whether the graph lines will made to form a shap (ie like a mountain range).
 boolean getGraphLinesThicknessAssociation()
          Gets whether the horizontal and vertical lines (if they both exist) should both be the same thickness at all times.
 int getGraphLinesThicknessModel()
          Gets the thickness of the line components for the chart's model size.
 float getGraphLinesWithinCategoryOverlapRatio()
          Gets how much the lines can overlap eachother when there are multiple data values per data set and per data category.
 java.awt.Color getGraphNumbersLinesColor()
          Gets the color of the horizontal lines of this graph.
 boolean getGraphNumbersLinesExistence()
          Gets whether the horizontal lines of this graph exist.
 float[] getGraphNumbersLinesStyle()
          Gets the style of the horizontal lines of this graph.
 int getGraphNumbersLinesThicknessModel()
          Gets the thickness of the horizontal lines of this graph for the chart's model size.
 java.awt.Color getGraphOutlineComponentsColor()
          Gets the color of the thin outline around components (ie bars, lines, or dots).
 boolean getGraphOutlineComponentsExistence()
          Gets whether there exists a thin outline around each component (ie bars, lines, or dots).
 void setGraphAllowComponentAlignment(boolean alignment)
          Sets whether the graph's components (ie bars, dots, or lines) are allowed to overlap/align or are offset for each set and within each category.
 void setGraphBackgroundColor(java.awt.Color color)
          Sets the color of the background of this graph.
 void setGraphBackgroundExistence(boolean existence)
          Sets whether the background of this graph exists.
 void setGraphBarsExcessSpaceFeedbackRatio(float ratio)
          Sets the amount of the excess space to feed back to bars thickness.
 void setGraphBarsExistence(boolean existence)
          Sets whether the graph contains bar components.
 void setGraphBarsRoundingRatio(float r)
          Sets the degree of rounding for the bars.
 void setGraphBarsThicknessModel(int thickness)
          Sets the thickness of the bar components for the chart's model size.
 void setGraphBarsWithinCategoryOverlapRatio(float ratio)
          Sets how much the bars can overlap eachother when there are multiple data values per data set and per data category.
 void setGraphBetweenComponentsGapExistence(boolean existence)
          Sets whether a gap between each category of components exists (ie not the gap between each each component with each category).
 void setGraphBetweenComponentsGapThicknessModel(int thickness)
          Sets the thickness of the gap between each category of components for the chart's model size.
 void setGraphBorderExistence(boolean existence)
          Sets whether the graph's left and bottom border exists.
 void setGraphBorderLeftBottomColor(java.awt.Color color)
          Sets the color of the graph's left and bottom border.
 void setGraphBorderRightTopColor(java.awt.Color color)
          Sets the color of the graph's right and top border.
 void setGraphBorderThicknessModel(int thickness)
          Sets the thickness of the graph's left and bottom border for the chart's model size.
 void setGraphComponentsAlphaComposite(java.awt.AlphaComposite a)
          Sets the actual AlphaComposite object to use on the Graphics2D object context for painting the graph components managed by this GraphProperties object.
 void setGraphComponentsLightSource(int s)
          Sets the direction of the source of the light if any.
 void setGraphComponentsLightType(int t)
          Sets the type of the lighting affect.
 void setGraphComponentsOverflowClip(boolean c)
          Sets whether the graph's components will be clipped if they pass over the graph's inner space or border.
 void setGraphDotsExcessSpaceFeedbackRatio(float ratio)
          Sets the amount of the excess space to feed back to dots thickness.
 void setGraphDotsExistence(boolean existence)
          Sets whether the graph contains dot components.
 void setGraphDotsThicknessModel(int thickness)
          Sets the thickness of the dot components for the chart's model size.
 void setGraphDotsWithinCategoryOverlapRatio(float ratio)
          Sets how much the dots can overlap eachother when there are multiple data values per data set and per data category.
 void setGraphLabelsLinesColor(java.awt.Color color)
          Sets the color of the vertical lines of this graph.
 void setGraphLabelsLinesExistence(boolean existence)
          Sets whether the vertical lines of this graph exist.
 void setGraphLabelsLinesStyle(float[] style)
          Sets the style of the vertical lines of this graph.
 void setGraphLabelsLinesThicknessModel(int thickness)
          Sets the thickness of the vertical lines of this graph for the chart's model size.
 void setGraphLinesExcessSpaceFeedbackRatio(float ratio)
          Sets the amount of the excess space to feed back to lines thickness.
 void setGraphLinesExistence(boolean existence)
          Sets whether the graph contains line components.
 void setGraphLinesFillInterior(boolean fill)
          Sets whether the graph lines will made to form a shap (ie like a mountain range).
 void setGraphLinesThicknessAssociation(boolean association)
          Sets whether the horizontal and vertical lines (if they both exist) should both be the same thickness at all times.
 void setGraphLinesThicknessModel(int thickness)
          Sets the thickness of the line components for the chart's model size.
 void setGraphLinesWithinCategoryOverlapRatio(float ratio)
          Sets how much the lines can overlap eachother when there are multiple data values per data set and per data category.
 void setGraphNumbersLinesColor(java.awt.Color color)
          Sets the color of the horizontal lines of this graph.
 void setGraphNumbersLinesExistence(boolean existence)
          Sets whether the horizontal lines of this graph exist.
 void setGraphNumbersLinesStyle(float[] style)
          Sets the style of the horizontal lines of this graph.
 void setGraphNumbersLinesThicknessModel(int thickness)
          Sets the thickness of the horizontal lines of this graph for the chart's model size.
 void setGraphOutlineComponentsColor(java.awt.Color color)
          Sets the color of the thin outline around components (ie bars, lines, or dots).
 void setGraphOutlineComponentsExistence(boolean existence)
          Sets whether there exists a thin outline around each component (ie bars, lines, or dots).
 void setGraphProperties(net.sourceforge.chart2d.GraphProperties graphProps)
          Sets all properties to be the values of another GraphProperties object.
 void setGraphPropertiesToDefaults()
          Sets all properties to their default values.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CONTINUOUS

public static float[] CONTINUOUS
Indicates the lines will be continuous. Used by setGraphNumbersLinesStyle(int) and setGraphLabelsLinesStyle(int).


DASHED

public static float[] DASHED
Indicates the lines will be dashed. Used by setGraphNumbersLinesStyle(int) and setGraphLabelsLinesStyle(int).


DOTTED

public static float[] DOTTED
Indicates the lines will be dotted. Used by setGraphNumbersLinesStyle(int) and setGraphLabelsLinesStyle(int).


LEFT

public static int LEFT
Indicates the left of something. Used by setGraphComponentsLightSource(int).


RIGHT

public static int RIGHT
Indicates the right of something. Used by setGraphComponentsLightSource(int).


TOP

public static int TOP
Indicates the top of something. Used by setGraphComponentsLightSource(int).


BOTTOM

public static int BOTTOM
Indicates the bottom of something. Used by setGraphComponentsLightSource(int).


NONE

public static int NONE
Indicates none. Used by setGraphComponentsLightSource(int).


COMPONENT

public static int COMPONENT
Indicates only the component. Used by setGraphComponentsLightType(int).


GRAPH

public static int GRAPH
Indicates only the graph. Used by setGraphComponentsLightType(int).


ALPHA_COMPOSITE_NONE

public static java.awt.AlphaComposite ALPHA_COMPOSITE_NONE
An opaque (no blending) alpha composite.


ALPHA_COMPOSITE_MILD

public static java.awt.AlphaComposite ALPHA_COMPOSITE_MILD
A mildly transparent (some blending) alpha composite.


ALPHA_COMPOSITE_MEDIUM

public static java.awt.AlphaComposite ALPHA_COMPOSITE_MEDIUM
A medium transparent (some blending) alpha composite.


GRAPH_BACKGROUND_EXISTENCE_DEFAULT

public static final boolean GRAPH_BACKGROUND_EXISTENCE_DEFAULT
The default is false.

See Also:
Constant Field Values

GRAPH_BACKGROUND_COLOR_DEFAULT

public static final java.awt.Color GRAPH_BACKGROUND_COLOR_DEFAULT
The default is Color.white.


GRAPH_BORDER_EXISTENCE_DEFAULT

public static final boolean GRAPH_BORDER_EXISTENCE_DEFAULT
The default is true.

See Also:
Constant Field Values

GRAPH_BORDER_THICKNESS_MODEL_DEFAULT

public static final int GRAPH_BORDER_THICKNESS_MODEL_DEFAULT
The default is 2.

See Also:
Constant Field Values

GRAPH_BORDER_LEFT_BOTTOM_COLOR_DEFAULT

public static final java.awt.Color GRAPH_BORDER_LEFT_BOTTOM_COLOR_DEFAULT
The default is Color.black.


GRAPH_BORDER_RIGHT_TOP_COLOR_DEFAULT

public static final java.awt.Color GRAPH_BORDER_RIGHT_TOP_COLOR_DEFAULT
The default is Color.gray.


GRAPH_ALLOW_COMPONENT_ALIGNMENT_DEFAULT

public static final boolean GRAPH_ALLOW_COMPONENT_ALIGNMENT_DEFAULT
The default is false.

See Also:
Constant Field Values

GRAPH_OUTLINE_COMPONENTS_EXISTENCE_DEFAULT

public static final boolean GRAPH_OUTLINE_COMPONENTS_EXISTENCE_DEFAULT
The default is false.

See Also:
Constant Field Values

GRAPH_OUTLINE_COMPONENTS_COLOR_DEFAULT

public static final java.awt.Color GRAPH_OUTLINE_COMPONENTS_COLOR_DEFAULT
The default is Color.black.


GRAPH_BETWEEN_COMPONENTS_GAP_EXISTENCE_DEFAULT

public static final boolean GRAPH_BETWEEN_COMPONENTS_GAP_EXISTENCE_DEFAULT
The default is true.

See Also:
Constant Field Values

GRAPH_BETWEEN_COMPONENTS_GAP_THICKNESS_MODEL_DEFAULT

public static final int GRAPH_BETWEEN_COMPONENTS_GAP_THICKNESS_MODEL_DEFAULT
The default is 2.

See Also:
Constant Field Values

GRAPH_BARS_EXISTENCE_DEFAULT

public static final boolean GRAPH_BARS_EXISTENCE_DEFAULT
The default is true.

See Also:
Constant Field Values

GRAPH_BARS_THICKNESS_MODEL_DEFAULT

public static final int GRAPH_BARS_THICKNESS_MODEL_DEFAULT
The default is 10.

See Also:
Constant Field Values

GRAPH_BARS_EXCESS_SPACE_FEEDBACK_RATIO_DEFAULT

public static final float GRAPH_BARS_EXCESS_SPACE_FEEDBACK_RATIO_DEFAULT
The default is 1f.

See Also:
Constant Field Values

GRAPH_BARS_WITHIN_CATEGORY_OVERLAP_RATIO_DEFAULT

public static final float GRAPH_BARS_WITHIN_CATEGORY_OVERLAP_RATIO_DEFAULT
The default is .535f.

See Also:
Constant Field Values

GRAPH_LINES_EXISTENCE_DEFAULT

public static final boolean GRAPH_LINES_EXISTENCE_DEFAULT
The default is false.

See Also:
Constant Field Values

GRAPH_LINES_THICKNESS_MODEL_DEFAULT

public static final int GRAPH_LINES_THICKNESS_MODEL_DEFAULT
The default is 5.

See Also:
Constant Field Values

GRAPH_LINES_FILL_INTERIOR_DEFAULT

public static final boolean GRAPH_LINES_FILL_INTERIOR_DEFAULT
The default is false.

See Also:
Constant Field Values

GRAPH_LINES_EXCESS_SPACE_FEEDBACK_RATIO_DEFAULT

public static final float GRAPH_LINES_EXCESS_SPACE_FEEDBACK_RATIO_DEFAULT
The default is 0f.

See Also:
Constant Field Values

GRAPH_LINES_WITHIN_CATEGORY_OVERLAP_RATIO_DEFAULT

public static final float GRAPH_LINES_WITHIN_CATEGORY_OVERLAP_RATIO_DEFAULT
The default is 0f.

See Also:
Constant Field Values

GRAPH_DOTS_EXISTENCE_DEFAULT

public static final boolean GRAPH_DOTS_EXISTENCE_DEFAULT
The default is false.

See Also:
Constant Field Values

GRAPH_DOTS_THICKNESS_MODEL_DEFAULT

public static final int GRAPH_DOTS_THICKNESS_MODEL_DEFAULT
The default is 8.

See Also:
Constant Field Values

GRAPH_DOTS_EXCESS_SPACE_FEEDBACK_RATIO_DEFAULT

public static final float GRAPH_DOTS_EXCESS_SPACE_FEEDBACK_RATIO_DEFAULT
The default is 0f.

See Also:
Constant Field Values

GRAPH_DOTS_WITHIN_CATEGORY_OVERLAP_RATIO_DEFAULT

public static final float GRAPH_DOTS_WITHIN_CATEGORY_OVERLAP_RATIO_DEFAULT
The default is .40f.

See Also:
Constant Field Values

GRAPH_NUMBERS_LINES_EXISTENCE_DEFAULT

public static final boolean GRAPH_NUMBERS_LINES_EXISTENCE_DEFAULT
The default is true.

See Also:
Constant Field Values

GRAPH_NUMBERS_LINES_THICKNESS_MODEL_DEFAULT

public static final int GRAPH_NUMBERS_LINES_THICKNESS_MODEL_DEFAULT
The default is 2.

See Also:
Constant Field Values

GRAPH_NUMBERS_LINES_STYLE_DEFAULT

public static final float[] GRAPH_NUMBERS_LINES_STYLE_DEFAULT
The default is CONTINUOUS.


GRAPH_NUMBERS_LINES_COLOR_DEFAULT

public static final java.awt.Color GRAPH_NUMBERS_LINES_COLOR_DEFAULT
The default is Color.gray.


GRAPH_LABELS_LINES_EXISTENCE_DEFAULT

public static final boolean GRAPH_LABELS_LINES_EXISTENCE_DEFAULT
The default is false.

See Also:
Constant Field Values

GRAPH_LABELS_LINES_THICKNESS_MODEL_DEFAULT

public static final int GRAPH_LABELS_LINES_THICKNESS_MODEL_DEFAULT
The default is 2.

See Also:
Constant Field Values

GRAPH_LABELS_LINES_STYLE_DEFAULT

public static final float[] GRAPH_LABELS_LINES_STYLE_DEFAULT
The default is CONTINUOUS.


GRAPH_LABELS_LINES_COLOR_DEFAULT

public static final java.awt.Color GRAPH_LABELS_LINES_COLOR_DEFAULT
The default is Color.gray.


GRAPH_LINES_THICKNESS_ASSOCIATION_DEFAULT

public static final boolean GRAPH_LINES_THICKNESS_ASSOCIATION_DEFAULT
The default is true.

See Also:
Constant Field Values

GRAPH_COMPONENTS_LIGHT_SOURCE_DEFAULT

public static int GRAPH_COMPONENTS_LIGHT_SOURCE_DEFAULT
The default is TOP.


GRAPH_COMPONENTS_LIGHT_TYPE_DEFAULT

public static int GRAPH_COMPONENTS_LIGHT_TYPE_DEFAULT
The default is COMPONENT.


GRAPH_BARS_ROUNDING_RATIO_DEFAULT

public static float GRAPH_BARS_ROUNDING_RATIO_DEFAULT
The default is .75f.


GRAPH_COMPONENTS_OVERFLOW_CLIP_DEFAULT

public static final boolean GRAPH_COMPONENTS_OVERFLOW_CLIP_DEFAULT
The default is true.

See Also:
Constant Field Values

GRAPH_COMPONENTS_ALPHA_COMPOSITE_DEFAULT

public static java.awt.AlphaComposite GRAPH_COMPONENTS_ALPHA_COMPOSITE_DEFAULT
The default is ALPHA_COMPOSITE_NONE.

Constructor Detail

GraphProperties

public GraphProperties()
Creates a GraphProperties object with the documented default values.


GraphProperties

public GraphProperties(net.sourceforge.chart2d.GraphProperties graphProps)
Creates a GraphProperties object with property values copied from another object. The copying is a deep copy.

Parameters:
graphProps - The properties to copy.
Method Detail

setGraphPropertiesToDefaults

public final void setGraphPropertiesToDefaults()
Sets all properties to their default values.


setGraphProperties

public final void setGraphProperties(net.sourceforge.chart2d.GraphProperties graphProps)
Sets all properties to be the values of another GraphProperties object. The copying is a deep copy.

Parameters:
graphProps - The properties to copy.

setGraphBackgroundExistence

public final void setGraphBackgroundExistence(boolean existence)
Sets whether the background of this graph exists. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would totally paint over the previous graph.

Parameters:
existence - If true, the background of this graph will exist.

setGraphBackgroundColor

public final void setGraphBackgroundColor(java.awt.Color color)
Sets the color of the background of this graph. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would totally paint over the previous graph.

Parameters:
color - The color of the background of this graph.

setGraphBorderExistence

public final void setGraphBorderExistence(boolean existence)
Sets whether the graph's left and bottom border exists.

Parameters:
existence - If true, then the graph's left and bottom border exists.

setGraphBorderThicknessModel

public final void setGraphBorderThicknessModel(int thickness)
Sets the thickness of the graph's left and bottom border for the chart's model size.

Parameters:
thickness - The model thickness of the graph's left and bottom border.

setGraphBorderLeftBottomColor

public final void setGraphBorderLeftBottomColor(java.awt.Color color)
Sets the color of the graph's left and bottom border.

Parameters:
color - The color of the graph's left and bottom border.

setGraphBorderRightTopColor

public final void setGraphBorderRightTopColor(java.awt.Color color)
Sets the color of the graph's right and top border.

Parameters:
color - The color of the graph's right and top border.

setGraphAllowComponentAlignment

public final void setGraphAllowComponentAlignment(boolean alignment)
Sets whether the graph's components (ie bars, dots, or lines) are allowed to overlap/align or are offset for each set and within each category. For non-stacked bars charts, don't align; for all other chart types alignment is generally preferrable.

Parameters:
alignment - If true, the components will not be offset within the category.

setGraphOutlineComponentsExistence

public final void setGraphOutlineComponentsExistence(boolean existence)
Sets whether there exists a thin outline around each component (ie bars, lines, or dots).

Parameters:
existence - If true, the components will have an outline.

setGraphOutlineComponentsColor

public final void setGraphOutlineComponentsColor(java.awt.Color color)
Sets the color of the thin outline around components (ie bars, lines, or dots).

Parameters:
color - The color of each component's outline.

setGraphBetweenComponentsGapExistence

public final void setGraphBetweenComponentsGapExistence(boolean existence)
Sets whether a gap between each category of components exists (ie not the gap between each each component with each category).

Parameters:
existence - If true, then the gap between components exists.

setGraphBetweenComponentsGapThicknessModel

public final void setGraphBetweenComponentsGapThicknessModel(int thickness)
Sets the thickness of the gap between each category of components for the chart's model size.

Parameters:
thickness - The model thickness of teh gap between components.

setGraphBarsExistence

public final void setGraphBarsExistence(boolean existence)
Sets whether the graph contains bar components.

Parameters:
existence - If true, then the graph contains bars.

setGraphBarsThicknessModel

public final void setGraphBarsThicknessModel(int thickness)
Sets the thickness of the bar components for the chart's model size.

Parameters:
thickness - The model thickness of the bars.

setGraphBarsExcessSpaceFeedbackRatio

public final void setGraphBarsExcessSpaceFeedbackRatio(float ratio)
Sets the amount of the excess space to feed back to bars thickness. Frequently the graphs are larger than necessary, the excess space can be fedback to the bars, making them larger. The ratio is the amount of space to feed back to the bars, to the total amount of space.

Parameters:
ratio - The ratio on the total amount of space to feedback.

setGraphBarsWithinCategoryOverlapRatio

public final void setGraphBarsWithinCategoryOverlapRatio(float ratio)
Sets how much the bars can overlap eachother when there are multiple data values per data set and per data category.

Parameters:
ratio - The ratio on the thickness of the bar for overlap.

setGraphLinesExistence

public final void setGraphLinesExistence(boolean existence)
Sets whether the graph contains line components.

Parameters:
existence - If true, then the graph contains lines.

setGraphLinesThicknessModel

public final void setGraphLinesThicknessModel(int thickness)
Sets the thickness of the line components for the chart's model size.

Parameters:
thickness - The model thickness of the lines.

setGraphLinesFillInterior

public final void setGraphLinesFillInterior(boolean fill)
Sets whether the graph lines will made to form a shap (ie like a mountain range).

Parameters:
fill - If true, then the lines will be filled.

setGraphLinesExcessSpaceFeedbackRatio

public final void setGraphLinesExcessSpaceFeedbackRatio(float ratio)
Sets the amount of the excess space to feed back to lines thickness. Frequently the graphs are larger than necessary, the excess space can be fedback to the lines, making them larger. The ratio is the amount of space to feed back to the lines, to the total amount of space.

Parameters:
ratio - The ratio on the total amount of space to feedback.

setGraphLinesWithinCategoryOverlapRatio

public final void setGraphLinesWithinCategoryOverlapRatio(float ratio)
Sets how much the lines can overlap eachother when there are multiple data values per data set and per data category.

Parameters:
ratio - The ratio on the thickness of the line for overlap.

setGraphDotsExistence

public final void setGraphDotsExistence(boolean existence)
Sets whether the graph contains dot components.

Parameters:
existence - If true, then the graph contains dots.

setGraphDotsThicknessModel

public final void setGraphDotsThicknessModel(int thickness)
Sets the thickness of the dot components for the chart's model size.

Parameters:
thickness - The model thickness of the dots.

setGraphDotsExcessSpaceFeedbackRatio

public final void setGraphDotsExcessSpaceFeedbackRatio(float ratio)
Sets the amount of the excess space to feed back to dots thickness. Frequently the graphs are larger than necessary, the excess space can be fedback to the dots, making them larger. The ratio is the amount of space to feed back to the dots, to the total amount of space.

Parameters:
ratio - The ratio on the total amount of space to feedback.

setGraphDotsWithinCategoryOverlapRatio

public final void setGraphDotsWithinCategoryOverlapRatio(float ratio)
Sets how much the dots can overlap eachother when there are multiple data values per data set and per data category.

Parameters:
ratio - The ratio on the thickness of the dot for overlap.

setGraphNumbersLinesExistence

public final void setGraphNumbersLinesExistence(boolean existence)
Sets whether the horizontal lines of this graph exist. These lines are aligned with the axis' ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components.

Parameters:
existence - If true, the horizontal lines exist.

setGraphNumbersLinesThicknessModel

public final void setGraphNumbersLinesThicknessModel(int thickness)
Sets the thickness of the horizontal lines of this graph for the chart's model size. These lines are aligned with the axis's ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components.

Parameters:
thickness - The model thickness of the horizontal lines.

setGraphNumbersLinesStyle

public final void setGraphNumbersLinesStyle(float[] style)
Sets the style of the horizontal lines of this graph. These lines are aligned with the axis's ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components. Possible values for style are: CONTINUOUS, DASHED, and DOTTED.

Parameters:
style - The style of the horizontal lines.

setGraphNumbersLinesColor

public final void setGraphNumbersLinesColor(java.awt.Color color)
Sets the color of the horizontal lines of this graph. These lines are aligned with the axis's ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components.

Parameters:
color - The color of the horizontal lines.

setGraphLabelsLinesExistence

public final void setGraphLabelsLinesExistence(boolean existence)
Sets whether the vertical lines of this graph exist. These lines are aligned with the axis' ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components.

Parameters:
existence - If true, the vertical lines exist.

setGraphLabelsLinesThicknessModel

public final void setGraphLabelsLinesThicknessModel(int thickness)
Sets the thickness of the vertical lines of this graph for the chart's model size. These lines are aligned with the axis's ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components.

Parameters:
thickness - The model thickness of the vertical lines.

setGraphLabelsLinesStyle

public final void setGraphLabelsLinesStyle(float[] style)
Sets the style of the vertical lines of this graph. These lines are aligned with the axis's ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components. Possible values for style are: CONTINUOUS, DASHED, and DOTTED.

Parameters:
style - The style of the vertical lines.

setGraphLabelsLinesColor

public final void setGraphLabelsLinesColor(java.awt.Color color)
Sets the color of the vertical lines of this graph. These lines are aligned with the axis's ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components.

Parameters:
color - The color of the vertical lines.

setGraphLinesThicknessAssociation

public final void setGraphLinesThicknessAssociation(boolean association)
Sets whether the horizontal and vertical lines (if they both exist) should both be the same thickness at all times. Uses the smaller thickness if they are not already equal.

Parameters:
association - If true, then these lines will have equal thickness.

setGraphComponentsLightSource

public final void setGraphComponentsLightSource(int s)
Sets the direction of the source of the light if any. Possible values are: TOP, BOTTOM, LEFT, RIGHT, TOPLEFT, BOTTOMRIGHT, and NONE.

Parameters:
s - The direction of the light source.

setGraphComponentsLightType

public final void setGraphComponentsLightType(int t)
Sets the type of the lighting affect. Possible values are: COMPONENT and GRAPH. COMPONENT implies that the light source is positioned directly on the components (for example leaving a complete shading affect for each component). GRAPH implies that the light source is positioned directly on the graph (for example leaving the components on one side of the graph lighter than the others).

Parameters:
t - The lighting affect type.

setGraphBarsRoundingRatio

public final void setGraphBarsRoundingRatio(float r)
Sets the degree of rounding for the bars. Uses the RoundRectangle in its implemenation. See the arcw and arch properties for guidance of RoundRectangle. The ratio is the diameter of the half-ellipse making the arc over the dimension in one direction of a bar. For the "Labels" ratio, the direction is the same direction in which the labels axis runs. Possible values are between zero and 1. Zero means less round, one means more round.

Parameters:
r - The rounding ratio.

setGraphComponentsOverflowClip

public final void setGraphComponentsOverflowClip(boolean c)
Sets whether the graph's components will be clipped if they pass over the graph's inner space or border. The only time the graph's components should not be clipped is if the graph's inner space and border are set to not exist. Not clipping may cause components to be painted over other chart components such as the legend or axis.

Parameters:
c - If true, then the components will be clipped.

setGraphComponentsAlphaComposite

public final void setGraphComponentsAlphaComposite(java.awt.AlphaComposite a)
Sets the actual AlphaComposite object to use on the Graphics2D object context for painting the graph components managed by this GraphProperties object. By passing different AlphaComposite objects, the graph components can take on a blending or transparency effect. Underneath components can be seen through components painted over them. This is especially useful for "line area" or "filled line" charts because top lines can paint over underneath lines if not using a "stacked" dataset object.

Parameters:
a - The AlphaComposite object to use.

getGraphBackgroundExistence

public final boolean getGraphBackgroundExistence()
Gets whether the background of this graph exists. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would totally paint over the previous graph.

Returns:
boolean If true, the background of this graph will exist.

getGraphBackgroundColor

public final java.awt.Color getGraphBackgroundColor()
Gets the color of the background of this graph. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would totally paint over the previous graph.

Returns:
Color The color of the background of this graph.

getGraphBorderExistence

public final boolean getGraphBorderExistence()
Gets whether the graph's left and bottom border exists.

Returns:
boolean If true, then the graph's left and bottom border exists.

getGraphBorderThicknessModel

public final int getGraphBorderThicknessModel()
Gets the thickness of the graph's left and bottom border for the chart's model size.

Returns:
int The model thickness of the graph's left and bottom border.

getGraphBorderLeftBottomColor

public final java.awt.Color getGraphBorderLeftBottomColor()
Gets the color of the graph's left and bottom border.

Returns:
Color The color of the graph's left and bottom border.

getGraphBorderRightTopColor

public final java.awt.Color getGraphBorderRightTopColor()
Gets the color of the graph's right and top border.

Returns:
Color The color of the graph's right and top border.

getGraphAllowComponentAlignment

public final boolean getGraphAllowComponentAlignment()
Gets whether the graph's components (ie bars, dots, or lines) are allowed to overlap/align or are offset for each set and within each category. For non-stacked bars charts, don't align; for all other chart types alignment is generally preferrable.

Returns:
boolean If true, the components will not be offset within the category.

getGraphOutlineComponentsExistence

public final boolean getGraphOutlineComponentsExistence()
Gets whether there exists a thin outline around each component (ie bars, lines, or dots).

Returns:
boolean If true, the components will have an outline.

getGraphOutlineComponentsColor

public final java.awt.Color getGraphOutlineComponentsColor()
Gets the color of the thin outline around components (ie bars, lines, or dots).

Returns:
Color The color of each component's outline.

getGraphBetweenComponentsGapExistence

public final boolean getGraphBetweenComponentsGapExistence()
Gets whether a gap between each category of components exists (ie not the gap between each each component with each category).

Returns:
boolean If true, then the gap between components exists.

getGraphBetweenComponentsGapThicknessModel

public final int getGraphBetweenComponentsGapThicknessModel()
Gets the thickness of the gap between each category of components for the chart's model size.

Returns:
int The model thickness of teh gap between components.

getGraphBarsExistence

public final boolean getGraphBarsExistence()
Gets whether the graph contains bar components.

Returns:
boolean If true, then the graph contains bars.

getGraphBarsThicknessModel

public final int getGraphBarsThicknessModel()
Gets the thickness of the bar components for the chart's model size.

Returns:
int The model thickness of the bars.

getGraphBarsExcessSpaceFeedbackRatio

public final float getGraphBarsExcessSpaceFeedbackRatio()
Gets the amount of the excess space to feed back to bars thickness. Frequently the graphs are larger than necessary, the excess space can be fedback to the bars, making them larger. The ratio is the amount of space to feed back to the bars, to the total amount of space.

Returns:
float The ratio on the total amount of space to feedback.

getGraphBarsWithinCategoryOverlapRatio

public final float getGraphBarsWithinCategoryOverlapRatio()
Gets how much the bars can overlap eachother when there are multiple data values per data set and per data category.

Returns:
ratio The ratio on the thickness of the bar for overlap.

getGraphLinesExistence

public final boolean getGraphLinesExistence()
Gets whether the graph contains line components.

Returns:
boolean If true, then the graph contains lines.

getGraphLinesThicknessModel

public final int getGraphLinesThicknessModel()
Gets the thickness of the line components for the chart's model size.

Returns:
int The model thickness of the lines.

getGraphLinesFillInterior

public final boolean getGraphLinesFillInterior()
Gets whether the graph lines will made to form a shap (ie like a mountain range).

Returns:
boolean If true, then the lines will be filled.

getGraphLinesExcessSpaceFeedbackRatio

public final float getGraphLinesExcessSpaceFeedbackRatio()
Gets the amount of the excess space to feed back to lines thickness. Frequently the graphs are larger than necessary, the excess space can be fedback to the lines, making them larger. The ratio is the amount of space to feed back to the lines, to the total amount of space.

Returns:
float The ratio on the total amount of space to feedback.

getGraphLinesWithinCategoryOverlapRatio

public final float getGraphLinesWithinCategoryOverlapRatio()
Gets how much the lines can overlap eachother when there are multiple data values per data set and per data category.

Returns:
ratio The ratio on the thickness of the line for overlap.

getGraphDotsExistence

public final boolean getGraphDotsExistence()
Gets whether the graph contains dot components.

Returns:
boolean If true, then the graph contains dots.

getGraphDotsThicknessModel

public final int getGraphDotsThicknessModel()
Gets the thickness of the dot components for the chart's model size.

Returns:
int The model thickness of the dots.

getGraphDotsExcessSpaceFeedbackRatio

public final float getGraphDotsExcessSpaceFeedbackRatio()
Gets the amount of the excess space to feed back to dots thickness. Frequently the graphs are larger than necessary, the excess space can be fedback to the dots, making them larger. The ratio is the amount of space to feed back to the dots, to the total amount of space.

Returns:
float The ratio on the total amount of space to feedback.

getGraphDotsWithinCategoryOverlapRatio

public final float getGraphDotsWithinCategoryOverlapRatio()
Gets how much the dots can overlap eachother when there are multiple data values per data set and per data category.

Returns:
ratio The ratio on the thickness of the dot for overlap.

getGraphNumbersLinesExistence

public final boolean getGraphNumbersLinesExistence()
Gets whether the horizontal lines of this graph exist. These lines are aligned with the axis' ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components.

Returns:
boolean If true, the horizontal lines exist.

getGraphNumbersLinesThicknessModel

public final int getGraphNumbersLinesThicknessModel()
Gets the thickness of the horizontal lines of this graph for the chart's model size. These lines are aligned with the axis's ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components.

Returns:
int The model thickness of the horizontal lines.

getGraphNumbersLinesStyle

public final float[] getGraphNumbersLinesStyle()
Gets the style of the horizontal lines of this graph. These lines are aligned with the axis's ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components. Possible values for style are: CONTINUOUS, DASHED, and DOTTED.

Returns:
float[] The style of the horizontal lines.

getGraphNumbersLinesColor

public final java.awt.Color getGraphNumbersLinesColor()
Gets the color of the horizontal lines of this graph. These lines are aligned with the axis's ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components.

Returns:
Color The color of the horizontal lines.

getGraphLabelsLinesExistence

public final boolean getGraphLabelsLinesExistence()
Gets whether the vertical lines of this graph exist. These lines are aligned with the axis' ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components.

Returns:
boolean If true, the vertical lines exist.

getGraphLabelsLinesThicknessModel

public final int getGraphLabelsLinesThicknessModel()
Gets the thickness of the vertical lines of this graph for the chart's model size. These lines are aligned with the axis's ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components.

Returns:
int The model thickness of the vertical lines.

getGraphLabelsLinesStyle

public final float[] getGraphLabelsLinesStyle()
Gets the style of the vertical lines of this graph. These lines are aligned with the axis's ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components. Possible values for style are: CONTINUOUS, DASHED, and DOTTED.

Returns:
float[] The style of the vertical lines.

getGraphLabelsLinesColor

public final java.awt.Color getGraphLabelsLinesColor()
Gets the color of the vertical lines of this graph. These lines are aligned with the axis's ticks. For each chart this graph is added to, this property will only be respected if its the first graph added that the chart; otherwise, graphs added after any chart would paint over the previous graph's components.

Returns:
Color The color of the vertical lines.

getGraphLinesThicknessAssociation

public final boolean getGraphLinesThicknessAssociation()
Gets whether the horizontal and vertical lines (if they both exist) should both be the same thickness at all times. Uses the smaller thickness if they are not already equal.

Returns:
boolean If true, then these lines will have equal thickness.

getGraphComponentsLightSource

public final int getGraphComponentsLightSource()
Gets the direction of the source of the light if any. Possible values are: TOP, BOTTOM, LEFT, RIGHT, and NONE.

Returns:
The direction of the light source.

getGraphComponentsLightType

public final int getGraphComponentsLightType()
Gets the type of the lighting affect. Possible values are: COMPONENT and GRAPH. COMPONENT implies that the light source is positioned directly on the components (for example leaving a complete shading affect for each component). GRAPH implies that the light source is positioned directly on the graph (for example leaving the components on one side of the graph lighter than the others).

Returns:
The lighting affect type.

getGraphBarsRoundingRatio

public final float getGraphBarsRoundingRatio()
Gets the degree of rounding for the bars. Uses the RoundRectangle in its implemenation. See the arcw and arch properties for guidance of RoundRectangle. The ratio is the diameter of the half-ellipse making the arc over the dimension in one direction of a bar. For the "Labels" ratio, the direction is the same direction in which the labels axis runs. Possible values are between zero and 1. Zero means less round, one means more round.

Returns:
The rounding ratio.

getGraphComponentsOverflowClip

public final boolean getGraphComponentsOverflowClip()
Gets whether the graph's components will be clipped if they pass over the graph's inner space or border. The only time the graph's components should not be clipped is if the graph's inner space and border are set to not exist. Not clipping may cause components to be painted over other chart components such as the legend or axis.

Returns:
If true, then the components will be clipped.

getGraphComponentsAlphaComposite

public final java.awt.AlphaComposite getGraphComponentsAlphaComposite()
Gets the actual AlphaComposite object to use on the Graphics2D object context for painting the graph components managed by this GraphProperties object. By passing different AlphaComposite objects, the graph components can take on a blending or transparency effect. Underneath components can be seen through components painted over them. This is especially useful for "line area" or "filled line" charts because top lines can paint over underneath lines if not using a "stacked" dataset object.

Returns:
The AlphaComposite object to use.