类 Axis
- java.lang.Object
-
- org.meteoinfo.chart.axis.Axis
-
- 所有已实现的接口:
java.lang.Cloneable
- 直接已知子类:
LogAxis,LonLatAxis,TimeAxis
public class Axis extends java.lang.Object implements java.lang.Cloneable- 作者:
- yaqiang
-
-
构造器概要
构造器 构造器 说明 Axis()ConstructorAxis(java.lang.String label)ConstructorAxis(java.lang.String label, boolean xAxis)ConstructorAxis(java.lang.String label, boolean xAxis, Location loc)ConstructorAxis(java.lang.String label, boolean xAxis, Location loc, boolean drawTickLabel)ConstructorAxis(Axis axis)ConstructorAxis(ChartText label)ConstructorAxis(ChartText label, boolean xAxis)Constructor
-
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 java.lang.Objectclone()voiddraw(java.awt.Graphics2D g, java.awt.geom.Rectangle2D area, AbstractPlot2D plot)Draw axisChartTextgetLabel()Get axis labeljava.awt.ColorgetLabelColor()Get label colorjava.awt.FontgetLabelFont()Get label fontintgetLabelGap(java.awt.Graphics2D g, double len)Update lable gapjava.awt.ColorgetLineColor()Get line colorjava.awt.StrokegetLineStroke()Get line strokeLineStylesgetLineStyle()floatgetLineWidth()Get line widthLocationgetLocation()Get locationintgetMaxLabelLength(java.awt.Graphics2D g)Get maximum label string lengthjava.lang.StringgetMaxLenLable()Get label string with maximum lengthChartTextgetMaxLenText()Get tick label text with maximum lengthintgetMaxTickLableLines()Get maximum tick label line numberdoublegetMaxValue()Get maximum valueintgetMinorTickNum()Get minor tick numberdoublegetMinValue()Get minimum valuefloatgetShift()Get shiftjava.awt.ColorgetTickColor()Get tick colordoublegetTickDeltaValue()Get tick delta valuefloatgetTickLabelAngle()Get tick label anglejava.awt.ColorgetTickLabelColor()Get tick label colorjava.awt.FontgetTickLabelFont()Get tick label fontintgetTickLabelGap()Get tick label gapjava.util.List<ChartText>getTickLabels()Get tick labelsjava.util.List<java.lang.String>getTickLabelText()Get tick label textintgetTickLength()Get tick lengthjava.util.List<java.lang.Double>getTickLocations()Tick locationsintgetTickSpace()Get tick spacedoublegetTickStartValue()Get tick start valuejava.awt.StrokegetTickStroke()Get tick strokedouble[]getTickValues()Get tick valuesintgetXAxisHeight(java.awt.Graphics2D g)Get x axis heightintgetYAxisWidth(java.awt.Graphics2D g)Get y axis widthbooleanisAutoTick()Get if is auto tick labelsbooleanisDrawLabel()Get if draw labelbooleanisDrawTickLabel()Get is draw tick labelbooleanisDrawTickLine()Get if draw tick linesbooleanisInsideTick()Get if is inside tickbooleanisInverse()Get if is inversebooleanisMinorTickVisible()Get if minor tick visible or notbooleanisVisible()If is visiblebooleanisXAxis()Get if is x axisvoidsetAutoTick(boolean value)Set if auto tick labelsvoidsetColor_All(java.awt.Color c)Set color to all elementsvoidsetDrawLabel(boolean value)Set if draw labelvoidsetDrawTickLabel(boolean value)Set if draw tick labelvoidsetDrawTickLine(boolean value)Set if draw tick linesvoidsetInsideTick(boolean value)Set if is inside tickvoidsetInverse(boolean value)Set if is inversevoidsetLabel(java.lang.String value)Set axis labelvoidsetLabel(ChartText value)Set axis labelvoidsetLabelColor(java.awt.Color value)Set label colorvoidsetLabelFont(java.awt.Font value)Set lable fontvoidsetLineColor(java.awt.Color value)Set line colorvoidsetLineStyle(LineStyles value)voidsetLineWidth(float value)Set line widthvoidsetLocation(Location value)Set locationvoidsetMaxValue(double value)Set maximum valuevoidsetMinMaxValue(double minValue, double maxValue)Set minimum and maximum valuesvoidsetMinorTickNum(int value)Set minor tick numbervoidsetMinorTickVisible(boolean value)Set if minor tick visible or notvoidsetMinValue(double value)Set minimum valuevoidsetShift(float value)Set shiftvoidsetTickColor(java.awt.Color value)Set tick colorvoidsetTickDeltaValue(double value)Set tick delta valuevoidsetTickLabelAngle(float value)Set tick label anglevoidsetTickLabelColor(java.awt.Color value)Set tick label colorvoidsetTickLabelFont(java.awt.Font value)Set tick lable fontvoidsetTickLabelGap(int value)Set tick label gapvoidsetTickLabels(java.util.List<ChartText> value)Set tick labels.voidsetTickLabels_Number(java.util.List<java.lang.Number> value)Set tick labelsvoidsetTickLabelText(java.util.List<java.lang.String> value)Set tick label textvoidsetTickLength(int value)Set tick lengthvoidsetTickLocations(double[] value)Set tick locationsvoidsetTickLocations(java.util.List<java.lang.Number> value)Set tick locationsvoidsetTickSpace(int value)Set tick spacevoidsetTickStartValue(double value)Set tick start valuevoidsetTickStroke(java.awt.Stroke value)Set tick strokevoidsetTickValues(double[] value)Set tick valuesvoidsetTickValues(java.util.List<java.lang.Double> value)Set tick valuesvoidsetVisible(boolean value)Set if is visiblevoidsetXAxis(boolean value)Set if is x axisvoidupdateLabelGap(java.awt.Graphics2D g, java.awt.geom.Rectangle2D rect)Update lable gapvoidupdateTickLabels()Get tick labelsvoidupdateTickValues()Update tick values
-
-
-
构造器详细资料
-
Axis
public Axis()
Constructor
-
Axis
public Axis(ChartText label)
Constructor- 参数:
label- Axis label
-
Axis
public Axis(java.lang.String label)
Constructor- 参数:
label- Axis label
-
Axis
public Axis(java.lang.String label, boolean xAxis)Constructor- 参数:
label- Axis labelxAxis- If is x axis
-
Axis
public Axis(ChartText label, boolean xAxis)
Constructor- 参数:
label- Axis labelxAxis- If is x axis
-
Axis
public Axis(java.lang.String label, boolean xAxis, Location loc)Constructor- 参数:
label- Axis labelxAxis- If is x axisloc- Location
-
Axis
public Axis(java.lang.String label, boolean xAxis, Location loc, boolean drawTickLabel)Constructor- 参数:
label- Axis labelxAxis- If is x axisloc- LocationdrawTickLabel- If draw tick label
-
Axis
public Axis(Axis axis)
Constructor- 参数:
axis- Axis
-
-
方法详细资料
-
isXAxis
public boolean isXAxis()
Get if is x axis- 返回:
- Boolean
-
setXAxis
public void setXAxis(boolean value)
Set if is x axis- 参数:
value- Boolean
-
getLocation
public Location getLocation()
Get location- 返回:
- Location
-
setLocation
public void setLocation(Location value)
Set location- 参数:
value- Location
-
getLabel
public ChartText getLabel()
Get axis label- 返回:
- Axis label
-
setLabel
public void setLabel(ChartText value)
Set axis label- 参数:
value- Axis label
-
setLabel
public void setLabel(java.lang.String value)
Set axis label- 参数:
value- Axis label
-
isVisible
public boolean isVisible()
If is visible- 返回:
- Boolean
-
setVisible
public void setVisible(boolean value)
Set if is visible- 参数:
value- Boolean
-
isDrawTickLine
public boolean isDrawTickLine()
Get if draw tick lines- 返回:
- Boolean
-
setDrawTickLine
public void setDrawTickLine(boolean value)
Set if draw tick lines- 参数:
value- Boolean
-
isDrawTickLabel
public boolean isDrawTickLabel()
Get is draw tick label- 返回:
- Boolean
-
setDrawTickLabel
public void setDrawTickLabel(boolean value)
Set if draw tick label- 参数:
value- Boolean
-
isDrawLabel
public boolean isDrawLabel()
Get if draw label- 返回:
- Boolean
-
setDrawLabel
public void setDrawLabel(boolean value)
Set if draw label- 参数:
value- Boolean
-
getLineColor
public java.awt.Color getLineColor()
Get line color- 返回:
- Line color
-
setLineColor
public void setLineColor(java.awt.Color value)
Set line color- 参数:
value- Line color
-
getLineWidth
public float getLineWidth()
Get line width- 返回:
- Line width
-
setLineWidth
public void setLineWidth(float value)
Set line width- 参数:
value- Line width
-
getLineStyle
public LineStyles getLineStyle()
-
setLineStyle
public void setLineStyle(LineStyles value)
-
getLineStroke
public java.awt.Stroke getLineStroke()
Get line stroke- 返回:
- Line stroke
-
getTickColor
public java.awt.Color getTickColor()
Get tick color- 返回:
- Tick color
-
setTickColor
public void setTickColor(java.awt.Color value)
Set tick color- 参数:
value- Tick color
-
getTickStroke
public java.awt.Stroke getTickStroke()
Get tick stroke- 返回:
- Tick stroke
-
setTickStroke
public void setTickStroke(java.awt.Stroke value)
Set tick stroke- 参数:
value- Tick stroke
-
getTickLength
public int getTickLength()
Get tick length- 返回:
- Tick length
-
setTickLength
public void setTickLength(int value)
Set tick length- 参数:
value- Tick length
-
isInsideTick
public boolean isInsideTick()
Get if is inside tick- 返回:
- Boolean
-
setInsideTick
public void setInsideTick(boolean value)
Set if is inside tick- 参数:
value- Boolean
-
getLabelFont
public java.awt.Font getLabelFont()
Get label font- 返回:
- Label font
-
setLabelFont
public void setLabelFont(java.awt.Font value)
Set lable font- 参数:
value- Lable font
-
getLabelColor
public java.awt.Color getLabelColor()
Get label color- 返回:
- Label color
-
setLabelColor
public void setLabelColor(java.awt.Color value)
Set label color- 参数:
value- Label color
-
getTickLabelFont
public java.awt.Font getTickLabelFont()
Get tick label font- 返回:
- Tick label font
-
setTickLabelFont
public void setTickLabelFont(java.awt.Font value)
Set tick lable font- 参数:
value- Tick lable font
-
getTickLabelColor
public java.awt.Color getTickLabelColor()
Get tick label color- 返回:
- Tick label color
-
setTickLabelColor
public void setTickLabelColor(java.awt.Color value)
Set tick label color- 参数:
value- Tick label color
-
getTickLabelAngle
public float getTickLabelAngle()
Get tick label angle- 返回:
- Tick label angle
-
setTickLabelAngle
public void setTickLabelAngle(float value)
Set tick label angle- 参数:
value- Angle
-
getTickLabelGap
public int getTickLabelGap()
Get tick label gap- 返回:
- Tick label gap
-
setTickLabelGap
public void setTickLabelGap(int value)
Set tick label gap- 参数:
value- Tick label gap
-
getTickStartValue
public double getTickStartValue()
Get tick start value- 返回:
- Tick start value
-
setTickStartValue
public void setTickStartValue(double value)
Set tick start value- 参数:
value- Tick start value
-
getTickDeltaValue
public double getTickDeltaValue()
Get tick delta value- 返回:
- Tick delta value
-
setTickDeltaValue
public void setTickDeltaValue(double value)
Set tick delta value- 参数:
value- Tick delta value
-
getMinValue
public double getMinValue()
Get minimum value- 返回:
- Minimum value
-
setMinValue
public void setMinValue(double value)
Set minimum value- 参数:
value- Minimum value
-
getMaxValue
public double getMaxValue()
Get maximum value- 返回:
- Maximum value
-
setMaxValue
public void setMaxValue(double value)
Set maximum value- 参数:
value- Maximum value
-
getTickValues
public double[] getTickValues()
Get tick values- 返回:
- Tick values
-
setTickValues
public void setTickValues(double[] value)
Set tick values- 参数:
value- Tick values
-
setTickValues
public void setTickValues(java.util.List<java.lang.Double> value)
Set tick values- 参数:
value- Tick value list
-
isInverse
public boolean isInverse()
Get if is inverse- 返回:
- Boolean
-
setInverse
public void setInverse(boolean value)
Set if is inverse- 参数:
value- Boolean
-
getShift
public float getShift()
Get shift- 返回:
- Shift
-
setShift
public void setShift(float value)
Set shift- 参数:
value- Shift
-
getTickLocations
public java.util.List<java.lang.Double> getTickLocations()
Tick locations- 返回:
- Tick locations
-
setTickLocations
public void setTickLocations(java.util.List<java.lang.Number> value)
Set tick locations- 参数:
value- Tick locations
-
setTickLocations
public void setTickLocations(double[] value)
Set tick locations- 参数:
value- Tick locations
-
getTickLabels
public java.util.List<ChartText> getTickLabels()
Get tick labels- 返回:
- Tick labels
-
getTickLabelText
public java.util.List<java.lang.String> getTickLabelText()
Get tick label text- 返回:
- Tick label text
-
setTickLabelText
public void setTickLabelText(java.util.List<java.lang.String> value)
Set tick label text- 参数:
value- Tick label text
-
setTickLabels
public void setTickLabels(java.util.List<ChartText> value)
Set tick labels.- 参数:
value- Tick labels
-
setTickLabels_Number
public void setTickLabels_Number(java.util.List<java.lang.Number> value)
Set tick labels- 参数:
value- Tick labels
-
isAutoTick
public boolean isAutoTick()
Get if is auto tick labels- 返回:
- Boolean
-
setAutoTick
public void setAutoTick(boolean value)
Set if auto tick labels- 参数:
value- Boolean
-
isMinorTickVisible
public boolean isMinorTickVisible()
Get if minor tick visible or not- 返回:
- Boolean
-
setMinorTickVisible
public void setMinorTickVisible(boolean value)
Set if minor tick visible or not- 参数:
value- Boolean
-
getMinorTickNum
public int getMinorTickNum()
Get minor tick number- 返回:
- Minor tick number
-
setMinorTickNum
public void setMinorTickNum(int value)
Set minor tick number- 参数:
value- Minor tick number
-
getTickSpace
public int getTickSpace()
Get tick space- 返回:
- Tick space
-
setTickSpace
public void setTickSpace(int value)
Set tick space- 参数:
value- Tick space
-
setMinMaxValue
public void setMinMaxValue(double minValue, double maxValue)Set minimum and maximum values- 参数:
minValue- Start valuemaxValue- End value
-
updateTickValues
public void updateTickValues()
Update tick values
-
updateTickLabels
public void updateTickLabels()
Get tick labels
-
getMaxLabelLength
public int getMaxLabelLength(java.awt.Graphics2D g)
Get maximum label string length- 参数:
g- Graphics2D- 返回:
- Maximum lable string length
-
getMaxLenLable
public java.lang.String getMaxLenLable()
Get label string with maximum length- 返回:
- Maximum length lable string
-
getMaxLenText
public ChartText getMaxLenText()
Get tick label text with maximum length- 返回:
- Maximum length tick label text
-
getMaxTickLableLines
public int getMaxTickLableLines()
Get maximum tick label line number- 返回:
- Maximum tick label line number
-
updateLabelGap
public void updateLabelGap(java.awt.Graphics2D g, java.awt.geom.Rectangle2D rect)Update lable gap- 参数:
g- Graphics2Drect- The rectangle
-
getLabelGap
public int getLabelGap(java.awt.Graphics2D g, double len)Update lable gap- 参数:
g- Graphics2Dlen- Length- 返回:
- Label gap
-
setColor_All
public void setColor_All(java.awt.Color c)
Set color to all elements- 参数:
c- Color
-
draw
public void draw(java.awt.Graphics2D g, java.awt.geom.Rectangle2D area, AbstractPlot2D plot)Draw axis- 参数:
g- Graphics2Darea- Areaplot- XYPlot
-
getXAxisHeight
public int getXAxisHeight(java.awt.Graphics2D g)
Get x axis height- 参数:
g- Graphics2D- 返回:
- Axis height
-
getYAxisWidth
public int getYAxisWidth(java.awt.Graphics2D g)
Get y axis width- 参数:
g- Graphics2D- 返回:
- Axis width
-
clone
public java.lang.Object clone() throws java.lang.CloneNotSupportedException- 覆盖:
clone在类中java.lang.Object- 抛出:
java.lang.CloneNotSupportedException
-
-