Package org.eclipse.draw2d
Interface Border
- All Known Subinterfaces:
- FlowBorder,- LabeledBorder
- All Known Implementing Classes:
- AbstractBackground,- AbstractBorder,- AbstractFlowBorder,- AbstractLabeledBorder,- ButtonBorder,- CompoundBorder,- FocusBorder,- FrameBorder,- GroupBoxBorder,- LineBorder,- MarginBorder,- SchemeBorder,- SeparatorBorder,- SimpleEtchedBorder,- SimpleLoweredBorder,- SimpleRaisedBorder,- TitleBarBorder
public interface Border
A decoration on a Figure. A border may paint itself within the bounds of a
 figure, and it may provide Insets which can affect how the figures children
 are posiiton and painted.
 
A border instance may be used with multiple figure instances.
- 
Method SummaryModifier and TypeMethodDescriptionReturns the Insets for this Border for the given Figure.getPreferredSize(IFigure figure) Returns the preferred width and height that this border would like to display itself properly.booleanisOpaque()Returnstrueif the Border completely fills the region defined inpaint(IFigure, Graphics, Insets).voidPaints the border.
- 
Method Details- 
getInsetsReturns the Insets for this Border for the given Figure.- Parameters:
- figure- The figure this border belongs to
- Returns:
- The insets
 
- 
getPreferredSizeReturns the preferred width and height that this border would like to display itself properly.- Parameters:
- figure- The figure
- Returns:
- The preferred size
 
- 
isOpaqueboolean isOpaque()Returnstrueif the Border completely fills the region defined inpaint(IFigure, Graphics, Insets).- Returns:
- trueif this border is opaque
 
- 
paintPaints the border. The border should paint inside figure'sIFigure.getBounds(), inset by the parameter insets. The border generally should not paint inside its own insets. More specifically, Border b should paint inside the rectangle: figure.getBounds().getCropped(insets) and outside of the rectangle: figure.getBounds().getCropped(insets).getCropped(getInsets()) where inside is defined asRectangle.contains(int, int).- Parameters:
- figure- The figure this border belongs to
- graphics- The graphics object used for painting
- insets- The insets
 
 
-