public class TLcdDefaultVVGridRenderer extends Object implements ILcdVVGridRenderer
ILcdVVGridRenderer
.Constructor and Description |
---|
TLcdDefaultVVGridRenderer() |
Modifier and Type | Method and Description |
---|---|
TLcdAltitudeUnit |
getAltitudeUnit() |
int |
getFontHeight() |
Color |
getGridColor() |
Color |
getGridLabelColor() |
Font |
getGridLabelFont() |
int |
getOrdinateLabelWidth(double aMinOrdinateAlt,
double aMaxOrdinateAlt,
double aOrdinateStep,
Graphics aGraphics)
Returns the width that fits the ordinate labels using the given minimum and maximum altitude ordinates,
ordinate step and graphics.
|
Color |
getSubGridColor() |
boolean |
isAntiAliasing()
Returns whether to use anti-aliasing when painting.
|
boolean |
isShowUnit() |
void |
paintGridLine(Graphics aGraphics,
int aX1,
int aY1,
int aX2,
int aY2)
Performs the rendering of a grid-line on the given Graphics.
|
void |
paintOrdinateLabel(double aValue,
double aStep,
Graphics aGraphics,
int aX,
int aY,
int aWidth)
Performs the rendering of a grid-label on the given Graphics.
|
void |
paintSubGridLine(Graphics aGraphics,
int aX1,
int aY1,
int aX2,
int aY2)
Performs the rendering of a subgrid-line on the given Graphics.
|
void |
setAltitudeUnit(TLcdAltitudeUnit aAltitudeUnit) |
void |
setAntiAliasing(boolean aAntiAliasing)
Sets whether to use anti-aliasing when painting.
|
void |
setGridColor(Color aColor)
This methods sets the
Color used for painting the main-grid. |
void |
setGridLabelColor(Color aColor)
This methods will set the
Color to use for painting the grid-label. |
void |
setGridLabelFont(Font aFont)
Sets the
Font that should be uses when painting the grid-labels. |
void |
setShowUnit(boolean aShowUnit) |
void |
setSubGridColor(Color aColor)
This methods sets the
Color used for painting the sub-grid. |
public void setGridColor(Color aColor)
Color
used for painting the main-grid.public int getFontHeight()
getFontHeight
in interface ILcdVVGridRenderer
public Color getGridColor()
setGridColor(java.awt.Color)
public void setSubGridColor(Color aColor)
Color
used for painting the sub-grid.public Color getSubGridColor()
setSubGridColor(java.awt.Color)
public void setGridLabelFont(Font aFont)
Font
that should be uses when painting the grid-labels.public Font getGridLabelFont()
setGridLabelFont(java.awt.Font)
public Color getGridLabelColor()
setGridLabelColor(java.awt.Color)
public void setGridLabelColor(Color aColor)
Color
to use for painting the grid-label.public boolean isAntiAliasing()
setAntiAliasing(boolean)
public void setAntiAliasing(boolean aAntiAliasing)
aAntiAliasing
- if true
, uses anti-aliasing when paintingisAntiAliasing()
public void paintSubGridLine(Graphics aGraphics, int aX1, int aY1, int aX2, int aY2)
ILcdVVGridRenderer
paintSubGridLine
in interface ILcdVVGridRenderer
public void paintGridLine(Graphics aGraphics, int aX1, int aY1, int aX2, int aY2)
ILcdVVGridRenderer
paintGridLine
in interface ILcdVVGridRenderer
public void paintOrdinateLabel(double aValue, double aStep, Graphics aGraphics, int aX, int aY, int aWidth)
ILcdVVGridRenderer
paintOrdinateLabel
in interface ILcdVVGridRenderer
aValue
- The value to paint.aStep
- How big is the step between each grid-line ( model values )aX
- The screen's X-position.aY
- The screen's Y-position (of the grid-line).aWidth
- The amount of width available for the label.public int getOrdinateLabelWidth(double aMinOrdinateAlt, double aMaxOrdinateAlt, double aOrdinateStep, Graphics aGraphics)
getOrdinateLabelWidth
in interface ILcdVVGridRenderer
aMinOrdinateAlt
- the minimum altitudeaMaxOrdinateAlt
- the maximum altitudeaOrdinateStep
- the step size between the altitudesaGraphics
- the graphics for which to paint the labelspublic TLcdAltitudeUnit getAltitudeUnit()
public void setAltitudeUnit(TLcdAltitudeUnit aAltitudeUnit)
public boolean isShowUnit()
public void setShowUnit(boolean aShowUnit)