Class MatteBorderExt
java.lang.Object
javax.swing.border.AbstractBorder
javax.swing.border.EmptyBorder
javax.swing.border.MatteBorder
org.jdesktop.swingx.border.MatteBorderExt
- All Implemented Interfaces:
Serializable, Border
Matte border that allows specialized icons for corners and sides.
- See Also:
-
Field Summary
FieldsFields inherited from class MatteBorder
color, tileIconFields inherited from class EmptyBorder
bottom, left, right, top -
Constructor Summary
ConstructorsConstructorDescriptionMatteBorderExt(int top, int left, int bottom, int right, Color matteColor) MatteBorderExt(int top, int left, int bottom, int right, Icon tileIcon) MatteBorderExt(int top, int left, int bottom, int right, Icon[] tileIcons) Draws a matte border using specialized icons for corners and sides.MatteBorderExt(Insets borderInsets, Color matteColor) MatteBorderExt(Insets borderInsets, Icon tileIcon) MatteBorderExt(Icon tileIcon) -
Method Summary
Modifier and TypeMethodDescriptionprotected IconOnly called by paintBorder()Icon[]Returns the icons used by this borderprotected voidvoidpaintBorder(Component c, Graphics g, int x, int y, int width, int height) protected voidpaintBottom(Component c, Graphics g, int x, int y, int width, int height) Only called by paintBorder()protected voidpaintBottomLeft(Component c, Graphics g, int x, int y, int width, int height) Only called by paintBorder()protected voidpaintBottomRight(Component c, Graphics g, int x, int y, int width, int height) Only called by paintBorder()protected voidOnly called by paintBorder()protected voidpaintRight(Component c, Graphics g, int x, int y, int width, int height) Only called by paintBorder()protected voidOnly called by paintBorder()protected voidpaintTopLeft(Component c, Graphics g, int x, int y, int width, int height) Only called by paintBorder()protected voidpaintTopRight(Component c, Graphics g, int x, int y, int width, int height) Only called by paintBorder()Methods inherited from class MatteBorder
getBorderInsets, getBorderInsets, getMatteColor, getTileIcon, isBorderOpaqueMethods inherited from class AbstractBorder
getBaseline, getBaselineResizeBehavior, getBorderInsets, getInteriorRectangle, getInteriorRectangle
-
Field Details
-
tileIcons
-
defaultIcon
-
-
Constructor Details
-
MatteBorderExt
Draws a matte border using specialized icons for corners and sides. If tileIcons is null, or if the length of tileIcons array is less than 2, this defaults to thesuperclassbehavior. Otherwise, tileIcons must specify icons in clockwise order, starting with the top-left icon at index zero, culminating with the left icon at index 7. If the length of the tileIcons array is greater than 1, but less than 8, then tileIcons[0] is used to paint the corners, and tileIcons[1] is used to paint the sides, with icons rotated as necessary. Other icons, if any, are ignored.- Parameters:
top- top insetleft- left insetbottom- bottom insetright- right insettileIcons- array of icons starting with top-left in index 0, continuing clockwise through the rest of the indices
-
MatteBorderExt
- See Also:
-
MatteBorderExt
-
MatteBorderExt
- See Also:
-
MatteBorderExt
-
MatteBorderExt
- See Also:
-
-
Method Details
-
getTileIcons
Returns the icons used by this border- Returns:
- the icons used by this border
-
paintBorder
- Specified by:
paintBorderin interfaceBorder- Overrides:
paintBorderin classMatteBorder
-
paint
-
paintTopLeft
-
paintTop
-
paintTopRight
-
paintRight
-
paintBottomRight
-
paintBottom
-
paintBottomLeft
-
paintLeft
-
getDefaultIcon
Only called by paintBorder()
-