Package org.eclipse.draw2d
Class SeparatorBorder
java.lang.Object
org.eclipse.draw2d.AbstractBorder
org.eclipse.draw2d.MarginBorder
org.eclipse.draw2d.SeparatorBorder
- All Implemented Interfaces:
Border
This border behaves similar to a
LineBorder
with width 1
,
except that individual sides are drawn. The sides are specified via
PositionConstants.LEFT
, PositionConstants.RIGHT
,
PositionConstants.TOP
and PositionConstants.BOTTOM
. Multiple
sides can be specified by logically or-ing these constants.- Since:
- 3.16
-
Field Summary
Fields inherited from class org.eclipse.draw2d.MarginBorder
insets
Fields inherited from class org.eclipse.draw2d.AbstractBorder
tempRect
-
Constructor Summary
ConstructorsConstructorDescriptionSeparatorBorder
(Insets insets, int sides) The sides are specified viaPositionConstants.LEFT
,PositionConstants.RIGHT
,PositionConstants.TOP
,PositionConstants.BOTTOM
. -
Method Summary
Methods inherited from class org.eclipse.draw2d.MarginBorder
getInsets
Methods inherited from class org.eclipse.draw2d.AbstractBorder
getPaintRectangle, getPreferredSize, isOpaque
-
Constructor Details
-
SeparatorBorder
The sides are specified viaPositionConstants.LEFT
,PositionConstants.RIGHT
,PositionConstants.TOP
,PositionConstants.BOTTOM
. Multiple sides can be specified by logically or-ing these constants.- Parameters:
insets
- The Insets for the bordersides
- The integer-encoded sides that should be drawn.- See Also:
-
-
Method Details
-
setColor
Ifnull
is given as a parameter, the current foreground color of the graphics object is used while painting.- Parameters:
color
- The color used for drawing each side.
-
paint
Description copied from class:MarginBorder
This method does nothing, since this border is just for spacing.- Specified by:
paint
in interfaceBorder
- Overrides:
paint
in classMarginBorder
- Parameters:
f
- The figure this border belongs tog
- The graphics object used for paintingi
- The insets- See Also:
-