|
JClass DesktopViews 6.3.0 API Documentation |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.klg.jclass.chart3d.ParentTrackChange | +--com.klg.jclass.chart3d.ParentFormatter | +--com.klg.jclass.chart3d.JCAxis
The JCAxis
class represents one of the three axes in 3D space.
It it used to store and control axis related properties like its min, max,
annotation method, title, gridlines, annotation, and title font. It has
an annotation handler to handle the annotation generation.
Field Summary | |
protected double |
annoEaseway
|
protected Font |
annoFont
The annotation font for this axis. |
protected int |
annoFontCubeSize
The annotation font cube size for this axis (this size is measured in thousandths of the unit cube size and must be between 0 and 1000). |
protected com.klg.jclass.chart3d.Chart3dAnnoHandler |
annoHandler
Handler for code specific to axis annotations. |
protected double |
annoMax
|
protected double |
annoMin
|
protected double |
annoStep
|
static int |
ANNOTATION_DATA_LABELS
Annotation method in which the xLabels and yLabels are used (grid data only). |
static int |
ANNOTATION_ROTATION_DEFAULT
Annotation rotation is caclulated based on type of annotation an spacing |
static int |
ANNOTATION_ROTATION_HORIZONTAL
Annotation is horizontal or parallel to the axis |
static int |
ANNOTATION_ROTATION_VERTICAL
Annoation is vertical or orthogonal to the axis |
static int |
ANNOTATION_VALUE_LABELS
Annotation method in which the user's value labels are used for annotation. |
static int |
ANNOTATION_VALUES
Annotation method in which chart 3D computes the labels based on axis values. |
protected int |
annotationMethod
The annotation method. |
protected int |
annotationRotation
The annotation rotation. |
static int |
AXIS_EYE
Enum used in the rotate actions for rotation about the user's eye position. |
static int |
AXIS_NONE
Enum used in the rotate actions where no particular axis is selected. |
static int |
AXIS_X
The X axis. |
static int |
AXIS_Y
The Y axis. |
static int |
AXIS_Z
The Z axis. |
protected int |
axisId
The axis id number. |
protected boolean |
combineLabels
If true , consecutive data labels that are identical (in other
words, that refer to the same object) are combined into one label, and the
resulting label is positioned at the average (or middle) label position. |
protected double |
dataportMax
|
protected double |
dataportMin
|
protected com.klg.jclass.chart3d.JCGridLines |
gridLines
Gridlines on a per plane basis for this axis. |
protected com.klg.jclass.chart3d.JCLabelGenerator |
labelGenerator
Label generator which is used for custom annotations. |
protected com.klg.jclass.chart3d.DerivedDouble |
max
The axis maximum value. |
static int |
MAX_AXIS_FONT_CUBE_SIZE
The maximum axis font cube size. |
protected int |
maxAnnoLength
|
protected com.klg.jclass.chart3d.DerivedDouble |
min
The axis minimum value. |
static int |
NUM_AXES
The number of axes on the plotcube. |
protected double |
origin
The origin is used for Z axis only (for bars and scatter plot drop lines). |
protected boolean |
showing
Asks if the axis showing. |
protected String |
title
The axis title. |
protected Font |
titleFont
The title font for this axis. |
protected int |
titleFontCubeSize
The title font cube size for this axis (this size is measured in thousandths of the unit cube size and must be between 0 and 1000). |
Fields inherited from class com.klg.jclass.chart3d.ParentFormatter |
decimalPadded, groupingUsed, nFrac, numberLocalization |
Fields inherited from class com.klg.jclass.chart3d.ParentTrackChange |
parents |
Constructor Summary | |
JCAxis()
No args constructor. |
|
JCAxis(int axisId,
Font defaultFont)
Constructor which supplies the axisId . |
Method Summary | |
void |
addValueLabel(com.klg.jclass.chart3d.JCValueLabel vl)
Adds the provided value label to the list of value labels. |
protected void |
calcMaxAnnoLength()
Calculates the length of the longest annotation. |
protected void |
checkLimits(double dataMin,
double dataMax)
Ensures that the max value is greater than the min value. |
double |
getAnnoEaseway()
Gets the annotation easeway. |
Font |
getAnnoFont()
Gets the annotation font for this axis. |
int |
getAnnoFontCubeSize()
Returns the size of the annotation font. |
com.klg.jclass.chart3d.Chart3dAnnoHandler |
getAnnoHandler()
Returns the annotation handler for this axis. |
double |
getAnnoMax()
Gets the annotation maximum. |
double |
getAnnoMin()
Gets the annotation minimum. |
double |
getAnnoStep()
Gets the annotation step. |
int |
getAnnotationMethod()
Returns the annotation method. |
int |
getAnnotationRotation()
Returns the annotation rotation. |
int |
getAxisId()
Returns the axisId . |
double |
getDataportMax()
Gets the dataport maximum. |
double |
getDataportMin()
Gets the dataport minimum. |
com.klg.jclass.chart3d.JCValueLabel |
getGeneratedValueLabel(double value)
Retrieves the value label for the specified value from the list of value labels generated for this axis. |
com.klg.jclass.chart3d.JCValueLabel[] |
getGeneratedValueLabels()
Gets the list of value labels generated for this axis. |
com.klg.jclass.chart3d.JCValueLabel |
getGeneratedValueLabels(int index)
Gets the value label at the specified index in the list of value labels generated for this axis. |
com.klg.jclass.chart3d.JCGridLines |
getGridLines()
Gets the gridlines object. |
com.klg.jclass.chart3d.JCLabelGenerator |
getLabelGenerator()
Gets the value of the LabelGenerator property. |
double |
getMax()
Gets the max property of the axis, which controls the maximum
value shown on the axis. |
protected int |
getMaxAnnoLength()
Gets the maximum annotation length for this axis (previously computed). |
boolean |
getMaxIsDefault()
Gets the maxIsDefault property. |
double |
getMin()
Gets the min property of the JCAxis , which
controls the minimum value shown on the axis. |
boolean |
getMinIsDefault()
Gets the minIsDefault property. |
double |
getOrigin()
Returns the axis origin. |
String |
getTitle()
Returns the title for this axis. |
Font |
getTitleFont()
Gets the title font for this axis. |
int |
getTitleFontCubeSize()
Returns the size of the title font. |
com.klg.jclass.chart3d.JCValueLabel |
getValueLabel(double value)
Retrieves the value label for the specified value from the list of user-specified value labels. |
com.klg.jclass.chart3d.JCValueLabel[] |
getValueLabels()
Gets the value of the ValueLabels property. |
com.klg.jclass.chart3d.JCValueLabel |
getValueLabels(int index)
Gets the value of the ValueLabels property at a specified index. |
boolean |
isCombineLabels()
Are data labels combined? If true , consecutive data labels that are
identical (that refer to the same object), are combined into one label and
the resulting label is positioned at the average (or middle) label position. |
boolean |
isShowing()
Returns whether this axis is showing or not. |
protected void |
setAnnoEaseway(double annoEaseway)
Sets the annotation easeway. |
void |
setAnnoFont(Font annoFont)
Sets annotation font for this axis. |
void |
setAnnoFontCubeSize(int annoFontCubeSize)
Sets the size of the annotation font. |
protected void |
setAnnoMax(double annoMax)
Sets the annotation maximum. |
protected void |
setAnnoMin(double annoMin)
Sets the annotation minimum. |
protected void |
setAnnoStep(double annoStep)
Sets the annotation step. |
void |
setAnnotationMethod(int annotationMethod)
Sets the axis annotation method. |
void |
setAnnotationRotation(int annotationRotation)
Sets the axis annotation rotation. |
void |
setCombineLabels(boolean combineLabels)
Sets the value of the combineLabels property. |
protected void |
setDataportMax(double dataportMax)
Sets the dataport maximum. |
protected void |
setDataportMin(double dataportMin)
Sets the dataport minimum. |
protected void |
setExtents(double minValue,
double maxValue)
Sets the extents of this axis. |
void |
setGridLines(com.klg.jclass.chart3d.JCGridLines gridLines)
Sets the gridlines object. |
void |
setLabelGenerator(com.klg.jclass.chart3d.JCLabelGenerator labelGenerator)
Sets the value of the LabelGenerator property. |
void |
setMax(double newMax)
Sets the max property of the axis, which controls the maximum
value shown on the axis. |
void |
setMaxIsDefault(boolean useDef)
Sets the naxIsDefault property. |
void |
setMin(double newMin)
Sets the min property of the JCAxis , which
controls the minimum value shown on the axis. |
void |
setMinIsDefault(boolean useDef)
Sets the minIsDefault property. |
void |
setOrigin(double origin)
Sets the axis origin. |
void |
setShowing(boolean showing)
Sets flag, which determines whether this axis is showing or not. |
void |
setTitle(String title)
Sets the title for this axis. |
void |
setTitleFont(Font titleFont)
Sets title font for this axis. |
void |
setTitleFontCubeSize(int titleFontCubeSize)
Sets the size of the title font. |
void |
setValueLabels(int index,
com.klg.jclass.chart3d.JCValueLabel vl)
Sets the value of one one value label in the ValueLabels property. |
void |
setValueLabels(com.klg.jclass.chart3d.JCValueLabel[] vl)
Sets the value of the ValueLabels property. |
Methods inherited from class com.klg.jclass.chart3d.ParentFormatter |
getGroupingUsed, getNFrac, getNumberFormatter, getNumberLocalization, isDecimalPadded, setDecimalPadded, setGroupingUsed, setNFrac, setNumberFormatterLocale, setNumberLocalization |
Methods inherited from class com.klg.jclass.chart3d.ParentTrackChange |
addParent, clearParents, removeParent |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int MAX_AXIS_FONT_CUBE_SIZE
public static final int AXIS_NONE
public static final int AXIS_X
public static final int AXIS_Y
public static final int AXIS_Z
public static final int AXIS_EYE
public static final int NUM_AXES
public static final int ANNOTATION_VALUES
public static final int ANNOTATION_DATA_LABELS
public static final int ANNOTATION_VALUE_LABELS
public static final int ANNOTATION_ROTATION_DEFAULT
public static final int ANNOTATION_ROTATION_HORIZONTAL
public static final int ANNOTATION_ROTATION_VERTICAL
protected boolean showing
protected int annotationMethod
ANNOTATION_VALUES
,
ANNTOATION_DATA_LABELS
, or ANNOTATION_VALUE_LABELS
.
protected int annotationRotation
ANNOTATION_ROTATION_DEFAULT
,
ANNTOATION_ROTATION_HORIZONTAL
, or
ANNOTATION_ROTATION_VERTICAL
.
protected double origin
protected String title
protected com.klg.jclass.chart3d.DerivedDouble min
protected com.klg.jclass.chart3d.DerivedDouble max
protected com.klg.jclass.chart3d.JCGridLines gridLines
protected Font annoFont
protected int annoFontCubeSize
protected Font titleFont
protected int titleFontCubeSize
protected boolean combineLabels
true
, consecutive data labels that are identical (in other
words, that refer to the same object) are combined into one label, and the
resulting label is positioned at the average (or middle) label position.
Ticks are still drawn at each data label position.
protected double annoMin
protected double annoMax
protected double annoStep
protected double annoEaseway
protected int maxAnnoLength
protected double dataportMin
protected double dataportMax
protected com.klg.jclass.chart3d.Chart3dAnnoHandler annoHandler
protected com.klg.jclass.chart3d.JCLabelGenerator labelGenerator
protected int axisId
AXIS_X
, AXIS_Y
,
and AXIS_Z
. This property can only be set on creation.
Constructor Detail |
public JCAxis()
public JCAxis(int axisId, Font defaultFont)
axisId
. The axisId
can only be set on creation.
axisId
- Which axis is it? Should be one of AXIS_X
,
AXIS_Y
, or AXIS_Z
.defaultFont
- What font should be used as the default annotation and
title font?Method Detail |
public int getAxisId()
axisId
. Should be one of AXIS_X
,
AXIS_Y
, or AXIS_Z
.
axisId
public void setShowing(boolean showing)
showing
- The new value of the showing flagpublic boolean isShowing()
public void setAnnotationMethod(int annotationMethod)
ANNOTATION_VALUES
, ANNTOATION_DATA_LABELS
, or
ANNOTATION_VALUE_LABELS
.
annotationMethod
- The new value of the annotation methodpublic int getAnnotationMethod()
public void setAnnotationRotation(int annotationRotation)
ANNOTATION_ROTATION_DEFAULT
,
ANNTOATION_ROTATION_HORIZONTAL
, or
ANNOTATION_ROTATION_VERTICAL
.
annotationRotation
- The new value of the annotation rotationpublic int getAnnotationRotation()
public void setOrigin(double origin)
origin
- the new value of the axis originpublic double getOrigin()
public void setAnnoFont(Font annoFont)
annoFontCubeSize
.
annoFont
- the new annotation fontpublic Font getAnnoFont()
annoFontCubeSize
.
public void setAnnoFontCubeSize(int annoFontCubeSize)
annoFontCubeSize
- the new size of the annotation fontpublic int getAnnoFontCubeSize()
public void setTitleFont(Font titleFont)
titleFontCubeSize
.
titleFont
- the new title fontpublic Font getTitleFont()
titleFontCubeSize
.
public void setTitleFontCubeSize(int titleFontCubeSize)
titleFontCubeSize
- the new size of the title fontpublic int getTitleFontCubeSize()
public void setTitle(String title)
title
- the new axis titlepublic String getTitle()
public void setMin(double newMin)
min
property of the JCAxis
, which
controls the minimum value shown on the axis.
newMin
- the new minimum valuepublic double getMin()
min
property of the JCAxis
, which
controls the minimum value shown on the axis.
public void setMinIsDefault(boolean useDef)
minIsDefault
property. The minIsDefault
property determines whether Chart3d is responsible for calculating the
minimum axis value. If true
, Chart3d will calculate the axis min. If false
,
Chart3d will use the provided axis min.
useDef
- if true
, Chart3d calculates the min
property; if false
, the
min
property is assumed to be already specifiedpublic boolean getMinIsDefault()
minIsDefault
property. The minIsDefault
property determines whether Chart3d is responsible for calculating the
minimum axis value. If true
, Chart3d will calculate the axis min. If false
,
Chart3d will use the provided axis min.
true
Chart3d calculates the min
property; if false
,
the min
property is assumed to be already specifiedpublic void setMax(double newMax)
max
property of the axis, which controls the maximum
value shown on the axis.
newMax
- the new maximum valuepublic double getMax()
max
property of the axis, which controls the maximum
value shown on the axis.
public void setMaxIsDefault(boolean useDef)
naxIsDefault
property. The naxIsDefault
property determines whether Chart3d is responsible for calculating the
maximum axis value. If true
, Chart3d calculates the axis max. If false
,
Chart3d uses the provided axis max.
useDef
- if true
, Chart3d calculates the max
property;
if false
, the max
property is assumed to be already specifiedpublic boolean getMaxIsDefault()
maxIsDefault
property. The maxIsDefault
property determines whether Chart3d is responsible for calculating the
maximum axis value. If true
, Chart3d calculates the axis max. If false
,
Chart3d uses the provided axis max.
max
property. If false
, the max
property is assumed to be already specifiedpublic void setGridLines(com.klg.jclass.chart3d.JCGridLines gridLines)
gridLines
- the new JCGridLines
object (cannot be null)public com.klg.jclass.chart3d.JCGridLines getGridLines()
JCGridLines
objectprotected void setAnnoMin(double annoMin)
annoMin
- the new annotation minimumpublic double getAnnoMin()
protected void setAnnoMax(double annoMax)
annoMax
- the new annotation maximumpublic double getAnnoMax()
protected void setAnnoStep(double annoStep)
annoStep
- the new annotation steppublic double getAnnoStep()
protected void setAnnoEaseway(double annoEaseway)
annoEaseway
- The new annotation easewaypublic double getAnnoEaseway()
protected int getMaxAnnoLength()
protected void setDataportMin(double dataportMin)
dataportMin
- dataport minimumpublic double getDataportMin()
protected void setDataportMax(double dataportMax)
dataportMax
- dataport maximumpublic double getDataportMax()
public com.klg.jclass.chart3d.Chart3dAnnoHandler getAnnoHandler()
protected void checkLimits(double dataMin, double dataMax)
dataMin
- the default data mindataMax
- the default data maxprotected void setExtents(double minValue, double maxValue)
minValue
- the calculated (or default) minimummaxValue
- the calculated (or default) maximumprotected void calcMaxAnnoLength()
public void setLabelGenerator(com.klg.jclass.chart3d.JCLabelGenerator labelGenerator)
LabelGenerator
property. The
LabelGenerator
property holds a reference to an object that
implements the JCLabelGenerator
interface. This interface is
used to externally generate labels.
labelGenerator
- reference to object instance used to generate labelspublic com.klg.jclass.chart3d.JCLabelGenerator getLabelGenerator()
LabelGenerator
property. The
LabelGenerator
property holds a reference to an object that
implements the JCLabelGenerator
interface. This interface is
used to externally generate labels.
public void setCombineLabels(boolean combineLabels)
combineLabels
property. If true
,
consecutive data labels that are identical (that refer to the same object),
are combined into one label and the resulting label is positioned at the
average (or middle) label position. Ticks are still drawn at each data
label position.
combineLabels
- the new value of combineLabelspublic boolean isCombineLabels()
true
, consecutive data labels that are
identical (that refer to the same object), are combined into one label and
the resulting label is positioned at the average (or middle) label position.
Ticks are still drawn at each data label position.
public com.klg.jclass.chart3d.JCValueLabel getValueLabel(double value)
value
- Data value for which to find the value label
public com.klg.jclass.chart3d.JCValueLabel getGeneratedValueLabel(double value)
AnnotationMethod
is
set to ANNOTATION_VALUE_LABELS
, this list will be the same as the
user-specified list of value labels.
value
- data value for which to find the value label
public void addValueLabel(com.klg.jclass.chart3d.JCValueLabel vl)
AnnotationMethod
is ANNOTATION_VALUE_LABELS
, then
the value label will appear at the appropriate point along the axis.
vl
- JCValueLabel
instance to addpublic com.klg.jclass.chart3d.JCValueLabel[] getValueLabels()
ValueLabels
property.
The ValueLabels
property is an indexed property containing
a list of all annotations specified by the user for an axis.
public com.klg.jclass.chart3d.JCValueLabel[] getGeneratedValueLabels()
AnnotationMethod
is set to ANNOTATION_VALUE_LABELS
,
this list will be the same as the user-specified list of value labels.
public void setValueLabels(com.klg.jclass.chart3d.JCValueLabel[] vl)
ValueLabels
property.
The ValueLabels
property is an indexed property containing
a list of all annotations specified by the user for an axis. AnnotationMethod
must be set to
ANNOTATION_VALUE_LABELS
for these labels to be used.
vl
- a list of value labels to be used on this axispublic com.klg.jclass.chart3d.JCValueLabel getValueLabels(int index)
ValueLabels
property at a specified index.
The ValueLabels
property is an indexed property containing
a list of all annotations specified by the user for an axis.
index
- the index of the user specified value label to be retrieved
public com.klg.jclass.chart3d.JCValueLabel getGeneratedValueLabels(int index)
AnnotationMethod
is set to
ANNOTATION_VALUE_LABELS
, this list will be the same as the
user-specified list of value labels.
index
- the index of the generated value label to be retrieved
public void setValueLabels(int index, com.klg.jclass.chart3d.JCValueLabel vl)
ValueLabels
property.
The ValueLabels
property is an indexed property containing
a list of all annotations specified by the user for an axis.
ValueLabel
list
is sorted by value. It is not recommended for use.
index
- the index of the value label to be setvl
- the new value label at the specified index
|
Copyright © 2004 Quest Software Inc.. All rights reserved. |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |