Class Borders
java.lang.Object
com.jgoodies.forms.factories.Borders
Provides constants and factory methods for
Borders that use
instances of ConstantSize to define the margins.
Examples:
Borders.DLU2_BORDER
Borders.createEmptyBorder(Sizes.DLUY4, Sizes.DLUX2, Sizes.DLUY4, Sizes.DLUX2);
Borders.createEmptyBorder("4dlu, 2dlu, 4dlu, 2dlu");
- Version:
- $Revision: 1.11 $
- Author:
- Karsten Lentzsch
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classAn empty border that uses 4 instances ofConstantSizeto define the top, left, bottom and right gap. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final BorderA standardized Border that describes the gap between a component and a button bar in its bottom.static final BorderA standardized Border that describes the border around a dialog content that has no tabs.static final BorderA prepared Border with 14dlu on all sides.static final BorderA prepared and reusable Border with 2dlu on all sides.static final BorderA prepared Border with 21dlu on all sides.static final BorderA prepared and reusable Border with 4dlu on all sides.static final BorderA prepared and reusable Border with 7dlu on all sides.static final BorderA prepared and reusable EmptyBorder without gaps.static final BorderA standardized Border that describes the border around a dialog content that uses tabs. -
Method Summary
Modifier and TypeMethodDescriptionstatic BordercreateEmptyBorder(ConstantSize top, ConstantSize left, ConstantSize bottom, ConstantSize right) Creates and returns anEmptyBorderwith the specified gaps.static BordercreateEmptyBorder(String encodedSizes) Creates and returns aBorderusing sizes as specified by the given string.
-
Field Details
-
EMPTY_BORDER
A prepared and reusable EmptyBorder without gaps. -
DLU2_BORDER
A prepared and reusable Border with 2dlu on all sides. -
DLU4_BORDER
A prepared and reusable Border with 4dlu on all sides. -
DLU7_BORDER
A prepared and reusable Border with 7dlu on all sides. -
DLU14_BORDER
A prepared Border with 14dlu on all sides. -
DLU21_BORDER
-
BUTTON_BAR_GAP_BORDER
A standardized Border that describes the gap between a component and a button bar in its bottom. -
DIALOG_BORDER
A standardized Border that describes the border around a dialog content that has no tabs.- See Also:
-
TABBED_DIALOG_BORDER
A standardized Border that describes the border around a dialog content that uses tabs.- See Also:
-
-
Method Details
-
createEmptyBorder
public static Border createEmptyBorder(ConstantSize top, ConstantSize left, ConstantSize bottom, ConstantSize right) Creates and returns anEmptyBorderwith the specified gaps.- Parameters:
top- the top gapleft- the left-hand side gapbottom- the bottom gapright- the right-hand side gap- Returns:
- an
EmptyBorderwith the specified gaps - Throws:
NullPointerException- if top, left, bottom, or right isnull- See Also:
-
createEmptyBorder
Creates and returns aBorderusing sizes as specified by the given string. This string is a comma-separated encoding of 4ConstantSizes.- Parameters:
encodedSizes- top, left, bottom, right gap encoded as String- Returns:
- an
EmptyBorderwith the specified gaps - See Also:
-