class org.aswing.border.DecorateBorder

DecorateBorder make your border can represented as many border arounded. DecorateBorder is a abstract class, you need to inherit it to implement your real decrator border.

Note:You should only need to override:

  • getDisplayImp
  • updateBorderImp
  • getBorderInsetsImp
methods in sub-class.

Authors

  • paling

Instance Fields

function new(interior:Border): Void

function getBorderInsets(c:Component, bounds:IntRectangle): Insets

Returns the insets of the border.
Note:subclass should not override this method, should override getBorderInsetsImp.

c

the component for which this border insets value applies

bounds

the bounds of the border would paint in.

See Also

function getBorderInsetsImp(c:Component, bounds:IntRectangle): Insets

You should override this method to count this border's insets.

See Also

function getDisplay(c:Component): DisplayObject

You should override this method to return the display object.

See Also

function getDisplayImp(): DisplayObject

Override this method in sub-class to return the display object if needed.

returns

a display object, or null, do not need a display object.

function getInterior(): Border

Returns current interior border.

returns

current interior border

function setInterior(interior:Border): Void

Sets new interior border.

interior

the new interior border

function updateBorder(c:Component, g:Graphics2D, bounds:IntRectangle): Void

call super.paintBorder paint the border first and then paint the interior border on the interior bounds.
Note:subclass should not override this method, should override paintBorderImp.

See Also

function updateBorderImp(com:Component, g:Graphics2D, bounds:IntRectangle): Void

Override this method in sub-class to draw border on the specified mc.

c

the component for which this border is being painted

g

the paint graphics

bounds

the bounds of border