Class RectangleHighlightPainter
- java.lang.Object
-
- ro.sync.ecss.extensions.api.highlights.RectangleHighlightPainter
-
- All Implemented Interfaces:
HighlightPainter
,PrioritizableHighlightPainter
@API(type=EXTENDABLE, src=PUBLIC) public class RectangleHighlightPainter extends java.lang.Object implements HighlightPainter, PrioritizableHighlightPainter
Fill a rectangle for the given highlight.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface ro.sync.ecss.extensions.api.highlights.PrioritizableHighlightPainter
PrioritizableHighlightPainter.ZLayer
-
-
Constructor Summary
Constructors Constructor Description RectangleHighlightPainter(Color fillColor)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PrioritizableHighlightPainter.ZLayer
getZLayer()
Get the Z layer where this highlight painter paints all its highlights.void
paint(HighlightPainterInfo pi)
Renders the highlight.protected void
paintHighlight(Graphics g, int x, int y, int width, int height)
Paint highlight.void
setFillColor(Color fillColor)
-
-
-
Field Detail
-
fillColor
protected Color fillColor
The fill color.
-
-
Constructor Detail
-
RectangleHighlightPainter
public RectangleHighlightPainter(Color fillColor)
Constructor.- Parameters:
fillColor
- The fill color.
-
-
Method Detail
-
getZLayer
public PrioritizableHighlightPainter.ZLayer getZLayer()
Description copied from interface:PrioritizableHighlightPainter
Get the Z layer where this highlight painter paints all its highlights. One ofPrioritizableHighlightPainter.ZLayer.BASE_LAYER
,PrioritizableHighlightPainter.ZLayer.MIDDLE_LAYER
orPrioritizableHighlightPainter.ZLayer.TOP_LAYER
.- Specified by:
getZLayer
in interfacePrioritizableHighlightPainter
- Returns:
- the Z layer where this highlight painter paints all its highlights.
- See Also:
PrioritizableHighlightPainter.getZLayer()
-
paint
public void paint(HighlightPainterInfo pi)
Description copied from interface:HighlightPainter
Renders the highlight.- Specified by:
paint
in interfaceHighlightPainter
- Parameters:
pi
- Information used by highlight- See Also:
HighlightPainter.paint(ro.sync.ecss.extensions.api.highlights.HighlightPainterInfo)
-
paintHighlight
protected void paintHighlight(Graphics g, int x, int y, int width, int height)
Paint highlight.- Parameters:
g
- The graphics used for paint.x
- The x coordinate.y
- The y coordinate.width
- The rectangle width.height
- The rectangle height.
-
setFillColor
public void setFillColor(Color fillColor)
- Parameters:
fillColor
- The fill color to set.
-
-