Package com.luciad.format.dgn.gxy
Class TLcdDGNGXYLineStyle
java.lang.Object
com.luciad.format.dgn.gxy.TLcdDGNGXYLineStyle
- All Implemented Interfaces:
ILcdCloneable
,ILcdGXYPainterStyle
,Serializable
,Cloneable
This class implements an
ILcdGXYPainterStyle
for DGN objects.
It sets a selectionColor before painting an Object
in
ILcdGXYPainter.SELECTED
mode, or the color specified by the
DGN object otherwise.- See Also:
-
Constructor Summary
ConstructorDescriptionTLcdDGNGXYLineStyle
(TLcdDGNColorTable aDGNColorTable) TLcdDGNGXYLineStyle
(TLcdDGNColorTable aDGNColorTable, TLcdDGNLevelSymbology aDGNLevelSymbology) TLcdDGNGXYLineStyle
(TLcdDGNColorTable aDGNColorTable, TLcdDGNLevelSymbology aDGNLevelSymbology, Color aSelectionColor) TLcdDGNGXYLineStyle
(TLcdDGNColorTable aDGNColorTable, TLcdDGNLevelSymbology aDGNLevelSymbology, Color aSelectionColor, boolean aUseAntiAliasing) -
Method Summary
Modifier and TypeMethodDescriptionclone()
MakesObject.clone()
public.static ILcdDGNGXYStrokeFactory
retrieveColor
(ILcdDGNShape aDGNShape) Finds the correct DGN color index and returns the corresponding color from the DGN color table.int
retrieveColorIndex
(ILcdDGNShape aDGNShape) Deprecated.int
retrieveStyle
(ILcdDGNShape aDGNShape) int
retrieveWeight
(ILcdDGNShape aDGNShape) void
setDGNColorTable
(TLcdDGNColorTable aDGNColorTable) static void
setDGNGXYStrokeFactory
(ILcdDGNGXYStrokeFactory aStrokeFactory) void
setDGNLevelSymbology
(TLcdDGNLevelSymbology aDGNLevelSymbology) void
setSelectionColor
(Color aSelectionColor) void
setupGraphics
(Graphics aGraphics, Object aObject, int aMode, ILcdGXYContext aGXYContext) Set upaGraphics
before painting aObject.
-
Constructor Details
-
TLcdDGNGXYLineStyle
public TLcdDGNGXYLineStyle() -
TLcdDGNGXYLineStyle
-
TLcdDGNGXYLineStyle
public TLcdDGNGXYLineStyle(TLcdDGNColorTable aDGNColorTable, TLcdDGNLevelSymbology aDGNLevelSymbology) -
TLcdDGNGXYLineStyle
public TLcdDGNGXYLineStyle(TLcdDGNColorTable aDGNColorTable, TLcdDGNLevelSymbology aDGNLevelSymbology, Color aSelectionColor) -
TLcdDGNGXYLineStyle
public TLcdDGNGXYLineStyle(TLcdDGNColorTable aDGNColorTable, TLcdDGNLevelSymbology aDGNLevelSymbology, Color aSelectionColor, boolean aUseAntiAliasing)
-
-
Method Details
-
setDGNColorTable
-
getDGNColorTable
-
setDGNLevelSymbology
-
getDGNLevelSymbology
-
setSelectionColor
-
getSelectionColor
-
setDGNGXYStrokeFactory
-
getDGNGXYStrokeFactory
-
setupGraphics
public void setupGraphics(Graphics aGraphics, Object aObject, int aMode, ILcdGXYContext aGXYContext) Description copied from interface:ILcdGXYPainterStyle
Set upaGraphics
before painting aObject. For example, if(aMode & ILcdGXYPainter.SELECTED) != 0
, you may want to callaGraphics.setColor(Color.red)
for instance, to see the selected representation of a aObject in red.- Specified by:
setupGraphics
in interfaceILcdGXYPainterStyle
- Parameters:
aGraphics
- theGraphics
to set up.aObject
- theObject
to paint.aMode
- the painting mode to consider (defined inILcdGXYPainter
).aGXYContext
- theILcdGXYContext
to consider.- See Also:
-
retrieveStyle
- Returns:
- the DGN style to be used for drawing the given DGN element.
-
retrieveWeight
- Returns:
- the DGN weight to be used for drawing the given DGN element.
-
retrieveColor
Finds the correct DGN color index and returns the corresponding color from the DGN color table. Implementations may override this method to get a different behavior.- Returns:
- the Color to be used for filling the given DGN element.
- See Also:
-
retrieveColorIndex
Deprecated.this method does not take extended colors into account, useretrieveColor(com.luciad.format.dgn.ILcdDGNShape)
instead- Returns:
- the DGN color index to be used for drawing the given DGN element.
-
clone
Description copied from interface:ILcdCloneable
Makes
When for example extending fromObject.clone()
public.java.lang.Object
, it can be implemented like this:public Object clone() { try { return super.clone(); } catch ( CloneNotSupportedException e ) { // Cannot happen: extends from Object and implements Cloneable (see also Object.clone) throw new RuntimeException( e ); } }
- Specified by:
clone
in interfaceILcdCloneable
- Overrides:
clone
in classObject
- See Also:
-
retrieveColor(com.luciad.format.dgn.ILcdDGNShape)
instead