Class APointPainter<T extends IPointPainterConfigurableUI<T>>
- Type Parameters:
T
- needed for generic comparable.
- All Implemented Interfaces:
IPointPainter<T>
,IPointPainterConfigurableUI<T>
,Serializable
,Comparable<T>
- Direct Known Subclasses:
PointPainterDisc
,PointPainterLine
,PointPainterVerticalBar
IPointPainter
as "no operation".
- Since:
- 3.0.0
- Version:
- $Revision: 1.13 $
- Author:
- Achim Westermann
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor (sets the consumed by paint flag to false). -
Method Summary
Modifier and TypeMethodDescriptionfinal int
void
Invoked to inform implementations that a paint iteration ends for the correspondingITrace2D
.boolean
getColor()
Returns the color to paint with ornull if no special color is desired.
Returns the color to paint fillings with ornull if no special color is desired.
Returns the stroke to paint with.int
Returns the transparency to use for painting.int
Returns the transparency to use for fill painting.int
hashCode()
protected Color
Installs the color to the graphics context if and only if a color has been set.protected Color
Installs the fill color to the graphics context if and only if a fill color has been set.protected Stroke
Installs the stroke to the graphics context if and only if a stroke has been set.Sets the color to paint with ornull
if no special color is desired.setColorFill
(Color fillColor) Sets the color to paint fillings with ornull
if no special fill color is desired.Sets the stroke to paint with ornull
if no special color is desired.int
setTransparency
(int transparency0to255) Sets the transparency to use for painting.int
setTransparencyFill
(int transparency0to255) Sets the transparency to use for fill painting.void
Invoked to inform implementations that a paint iteration starts for the correspondingITrace2D
.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface info.monitorenter.gui.chart.IPointPainter
paintPoint
-
Constructor Details
-
APointPainter
public APointPainter()Default constructor (sets the consumed by paint flag to false).
-
-
Method Details
-
compareTo
- Specified by:
compareTo
in interfaceComparable<T extends IPointPainterConfigurableUI<T>>
- See Also:
-
endPaintIteration
Description copied from interface:IPointPainter
Invoked to inform implementations that a paint iteration ends for the correspondingITrace2D
.- Specified by:
endPaintIteration
in interfaceIPointPainter<T extends IPointPainterConfigurableUI<T>>
- Parameters:
g2d
- provided in case pending paint operations have to be performed.- See Also:
-
equals
-
getColor
Description copied from interface:IPointPainterConfigurableUI
Returns the color to paint with ornull if no special color is desired.
- Specified by:
getColor
in interfaceIPointPainterConfigurableUI<T extends IPointPainterConfigurableUI<T>>
- Returns:
- the color to paint with
null if no special color is desired.
- See Also:
-
getColorFill
Description copied from interface:IPointPainterConfigurableUI
Returns the color to paint fillings with ornull if no special color is desired.
- Specified by:
getColorFill
in interfaceIPointPainterConfigurableUI<T extends IPointPainterConfigurableUI<T>>
- Returns:
- the color to paint fillings with
null if no special color is desired.
- See Also:
-
getStroke
Description copied from interface:IPointPainterConfigurableUI
Returns the stroke to paint with.- Specified by:
getStroke
in interfaceIPointPainterConfigurableUI<T extends IPointPainterConfigurableUI<T>>
- Returns:
- the stroke to paint with.
- See Also:
-
getTransparency
public int getTransparency()Description copied from interface:IPointPainterConfigurableUI
Returns the transparency to use for painting.This value will be computed from the color used. If that color is not configured (null) a value of 0.0 is returned even if the color from the
used for painting has a different setting!Graphics
- Specified by:
getTransparency
in interfaceIPointPainterConfigurableUI<T extends IPointPainterConfigurableUI<T>>
- Returns:
- the transparency used between 0 and 255.
- See Also:
-
getTransparencyFill
public int getTransparencyFill()Description copied from interface:IPointPainterConfigurableUI
Returns the transparency to use for fill painting.This value will be computed from the color used. If that color is not configured (null) a value of 0.0 is returned even if the color from the
used for painting has a different setting!Graphics
- Specified by:
getTransparencyFill
in interfaceIPointPainterConfigurableUI<T extends IPointPainterConfigurableUI<T>>
- Returns:
- the fill transparency used between 0 and 255.
- See Also:
-
hashCode
public int hashCode() -
installColor
Installs the color to the graphics context if and only if a color has been set.- Parameters:
g
- the graphics context to use.- Returns:
- the previous color of the graphics context or
null
if no action was taken. - See Also:
-
installColorFill
Installs the fill color to the graphics context if and only if a fill color has been set.- Parameters:
g
- the graphics context to use.- Returns:
- the previous color of the graphics context or
null
if no action was taken. - See Also:
-
installStroke
Installs the stroke to the graphics context if and only if a stroke has been set.- Parameters:
g
- the graphics context to use.- Returns:
- the previous stroke of the graphics context or
null
if no action was taken. - See Also:
-
setColor
Description copied from interface:IPointPainterConfigurableUI
Sets the color to paint with ornull
if no special color is desired.In the latter case the color of the
provided for paint operations will be used.Graphics
- Specified by:
setColor
in interfaceIPointPainterConfigurableUI<T extends IPointPainterConfigurableUI<T>>
- Parameters:
color
- the color to paint with ornull
if no special color is desired.- Returns:
- the previous color to paint with
null if no special color is desired.
- See Also:
-
setColorFill
Description copied from interface:IPointPainterConfigurableUI
Sets the color to paint fillings with ornull
if no special fill color is desired.In the latter case the color of the
provided for paint fill operations will be used.Graphics
- Specified by:
setColorFill
in interfaceIPointPainterConfigurableUI<T extends IPointPainterConfigurableUI<T>>
- Parameters:
fillColor
- the color to paint fillings with ornull
if no special color is desired.- Returns:
- the previous color to paint fillings with
null if no special color is desired.
- See Also:
-
setStroke
Description copied from interface:IPointPainterConfigurableUI
Sets the stroke to paint with ornull
if no special color is desired.In the latter case the stroke of the
provided for paint operations will be used.Graphics
- Specified by:
setStroke
in interfaceIPointPainterConfigurableUI<T extends IPointPainterConfigurableUI<T>>
- Parameters:
stroke
- the stroke to paint with.- Returns:
- the previous color being used or
null
if none was used before. - See Also:
-
setTransparency
public int setTransparency(int transparency0to255) Description copied from interface:IPointPainterConfigurableUI
Sets the transparency to use for painting.This value will be fold into color. If color has not been configured before it will not have any effect.
Caution: When using a value greater 0 may cost a multiple cpu load!
- Specified by:
setTransparency
in interfaceIPointPainterConfigurableUI<T extends IPointPainterConfigurableUI<T>>
- Parameters:
transparency0to255
- a transparency value between 0 and 255.- Returns:
- the previous transparency used.
- See Also:
-
setTransparencyFill
public int setTransparencyFill(int transparency0to255) Description copied from interface:IPointPainterConfigurableUI
Sets the transparency to use for fill painting.This value will be fold into fill color. If fill color has not been configured before it will not have any effect.
Caution: When using a value greater 0 may cost a multiple cpu load!
- Specified by:
setTransparencyFill
in interfaceIPointPainterConfigurableUI<T extends IPointPainterConfigurableUI<T>>
- Parameters:
transparency0to255
- a transparency value between 0 and 255.- Returns:
- the previous fill transparency used.
- See Also:
-
startPaintIteration
Description copied from interface:IPointPainter
Invoked to inform implementations that a paint iteration starts for the correspondingITrace2D
.- Specified by:
startPaintIteration
in interfaceIPointPainter<T extends IPointPainterConfigurableUI<T>>
- Parameters:
g2d
- provided in case pending paint operations have to be performed.- See Also:
-