Class TLcdGXYAsynchronousViewLabelPainterWrapper
- All Implemented Interfaces:
ILcdGXYViewLabelPainter
,Serializable
,Cloneable
ILcdGXYViewLabelPainter
that acts as a
wrapper for another ILcdGXYViewLabelPainter
, but only
delegates paint calls when there are no busy layers in the view.
A busy layer is a layer that is still being painted asynchronously. Painting labels of busy layers locks the Event Dispatch Thread until the painting is complete. This class removes this unwanted behavior by skipping asynchronous layers until they are idle. A consequence of this is that labels and selections will temporarily not be displayed. To reduce the flickering this causes, one can specify a minimum delay before re-displaying skipped content.
- Since:
- 8.0
- See Also:
-
Field Summary
Fields inherited from interface com.luciad.view.gxy.ILcdGXYViewLabelPainter
ALL, SELECTION
-
Constructor Summary
ConstructorDescriptionTLcdGXYAsynchronousViewLabelPainterWrapper
(ILcdGXYView aView, ILcdGXYViewLabelPainter aViewLabelPainterDelegate, int aSkipDelay) Deprecated.Constructs a new view label painter, wrapping around the given delegate. -
Method Summary
Modifier and TypeMethodDescriptionclone()
Deprecated.RedefinesObject.clone
to make it public.void
paintLabel
(Graphics aGraphics, ILcdGXYView aGXYView, int aViewLabelPainterMode) Deprecated.The implementation of this method shall define how to paint the labels of all the objects in the variousILcdGXYLayer
of the givenILcdGXYView
, in the given mode.void
paintLabel
(Graphics aGraphics, Enumeration aEnumeration, ILcdGXYView aGXYView, int aViewLabelPainterMode) Deprecated.The implementation of this method shall define how to paint the labels of all the objects in the variousILcdGXYLayer
of the given Enumeration, on the givenILcdGXYView
, in the given mode.
-
Constructor Details
-
TLcdGXYAsynchronousViewLabelPainterWrapper
public TLcdGXYAsynchronousViewLabelPainterWrapper(ILcdGXYView aView, ILcdGXYViewLabelPainter aViewLabelPainterDelegate, int aSkipDelay) Deprecated.Constructs a new view label painter, wrapping around the given delegate. Paint requests are only delegated for synchronous and idle asynchronous labels.- Parameters:
aView
- the view for which to paint labelsaViewLabelPainterDelegate
- to painter to wrap aroundaSkipDelay
- how many milliseconds to wait before re-painting skipped labels
-
-
Method Details
-
paintLabel
Deprecated.Description copied from interface:ILcdGXYViewLabelPainter
The implementation of this method shall define how to paint the labels of all the objects in the variousILcdGXYLayer
of the givenILcdGXYView
, in the given mode. Here one can implement various smart algorithms to check whether or not to paint a label at a certain location.If any layer for which labels are painted is an
ILcdGXYEditableLabelsLayer
, this method should inform theALcdLabelLocations
associated with that layer which labels have been drawn and which haven't been.- Specified by:
paintLabel
in interfaceILcdGXYViewLabelPainter
- Parameters:
aGraphics
- TheGraphics
instance on which to paint the labels.aGXYView
- The view for which to paint the labels. If labels are drawn for a layer that is an instance ofILcdGXYEditableLabelsLayer
, its ALcdLabelLocations instance should be informed of which labels have been drawn and which haven't been.aViewLabelPainterMode
- Determines which labels should be drawn. Should be one ofILcdGXYViewLabelPainter.ALL
orILcdGXYViewLabelPainter.SELECTION
- See Also:
-
paintLabel
public void paintLabel(Graphics aGraphics, Enumeration aEnumeration, ILcdGXYView aGXYView, int aViewLabelPainterMode) Deprecated.Description copied from interface:ILcdGXYViewLabelPainter
The implementation of this method shall define how to paint the labels of all the objects in the variousILcdGXYLayer
of the given Enumeration, on the givenILcdGXYView
, in the given mode. Here one can implement various smart algorithms to check whether or not to paint a label at a certain location.If any layer for which labels are painted is an
ILcdGXYEditableLabelsLayer
, this method should inform theALcdLabelLocations
associated with that layer which labels have been drawn and which haven't been.- Specified by:
paintLabel
in interfaceILcdGXYViewLabelPainter
- Parameters:
aGraphics
- TheGraphics
instance on which to paint the labels.aEnumeration
- Only the labels for the layers contained in thisEnumeration
will be drawn.aGXYView
- The ILcdGXYView instance for which to paint the layers.aViewLabelPainterMode
- Determines which labels should be drawn. Should be one ofILcdGXYViewLabelPainter.ALL
orILcdGXYViewLabelPainter.SELECTION
- See Also:
-
clone
Deprecated.Description copied from interface:ILcdGXYViewLabelPainter
RedefinesObject.clone
to make it public.- Specified by:
clone
in interfaceILcdGXYViewLabelPainter
- Overrides:
clone
in classObject
-