java.lang.Object | ||
↳ | javax.swing.border.AbstractBorder | |
↳ | javax.swing.border.BevelBorder |
![]() |
A class which implements a simple two-line bevel border.
Warning:
Serialized objects of this class will not be compatible with
future Swing releases. The current serialization support is
appropriate for short term storage or RMI between applications running
the same version of Swing. As of 1.4, support for long term storage
of all JavaBeansTM
has been added to the java.beans
package.
Please see XMLEncoder
.
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
int | LOWERED | Lowered bevel type. | |||||||||
int | RAISED | Raised bevel type. |
Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
bevelType | |||||||||||
highlightInner | |||||||||||
highlightOuter | |||||||||||
shadowInner | |||||||||||
shadowOuter |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Creates a bevel border with the specified type and whose
colors will be derived from the background color of the
component passed into the paintBorder method.
| |||||||||||
Creates a bevel border with the specified type, highlight and
shadow colors.
| |||||||||||
Creates a bevel border with the specified type, highlight and
shadow colors.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Returns the type of the bevel border.
| |||||||||||
Reinitialize the insets parameter with this Border's current Insets.
| |||||||||||
Returns the insets of the border.
| |||||||||||
Returns the inner highlight color of the bevel border.
| |||||||||||
Returns the inner highlight color of the bevel border
when rendered on the specified component.
| |||||||||||
Returns the outer highlight color of the bevel border
when rendered on the specified component.
| |||||||||||
Returns the outer highlight color of the bevel border.
| |||||||||||
Returns the inner shadow color of the bevel border
when rendered on the specified component.
| |||||||||||
Returns the inner shadow color of the bevel border.
| |||||||||||
Returns the outer shadow color of the bevel border
when rendered on the specified component.
| |||||||||||
Returns the outer shadow color of the bevel border.
| |||||||||||
Returns whether or not the border is opaque.
| |||||||||||
Paints the border for the specified component with the specified
position and size.
|
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() | |||||||||||
![]() | |||||||||||
![]() |
Lowered bevel type.
Raised bevel type.
Creates a bevel border with the specified type and whose colors will be derived from the background color of the component passed into the paintBorder method.
bevelType | the type of bevel for the border |
---|
Creates a bevel border with the specified type, highlight and shadow colors.
bevelType | the type of bevel for the border |
---|---|
highlight | the color to use for the bevel highlight |
shadow | the color to use for the bevel shadow |
Creates a bevel border with the specified type, highlight and shadow colors.
Note: The shadow inner and outer colors are switched for a lowered bevel border.
bevelType | the type of bevel for the border |
---|---|
highlightOuterColor | the color to use for the bevel outer highlight |
highlightInnerColor | the color to use for the bevel inner highlight |
shadowOuterColor | the color to use for the bevel outer shadow |
shadowInnerColor | the color to use for the bevel inner shadow |
Returns the type of the bevel border.
Reinitialize the insets parameter with this Border's current Insets.
c | the component for which this border insets value applies |
---|---|
insets | the object to be reinitialized |
insets
object
Returns the insets of the border.
c | the component for which this border insets value applies |
---|
Insets
object initialized to 0
Returns the inner highlight color of the bevel border. Will return null if no highlight color was specified at instantiation.
Returns the inner highlight color of the bevel border when rendered on the specified component. If no highlight color was specified at instantiation, the highlight color is derived from the specified component's background color.
c | the component for which the highlight may be derived |
---|
Returns the outer highlight color of the bevel border when rendered on the specified component. If no highlight color was specified at instantiation, the highlight color is derived from the specified component's background color.
c | the component for which the highlight may be derived |
---|
Returns the outer highlight color of the bevel border. Will return null if no highlight color was specified at instantiation.
Returns the inner shadow color of the bevel border when rendered on the specified component. If no shadow color was specified at instantiation, the shadow color is derived from the specified component's background color.
c | the component for which the shadow may be derived |
---|
Returns the inner shadow color of the bevel border. Will return null if no shadow color was specified at instantiation.
Returns the outer shadow color of the bevel border when rendered on the specified component. If no shadow color was specified at instantiation, the shadow color is derived from the specified component's background color.
c | the component for which the shadow may be derived |
---|
Returns the outer shadow color of the bevel border. Will return null if no shadow color was specified at instantiation.
Returns whether or not the border is opaque.
Paints the border for the specified component with the specified position and size.
c | the component for which this border is being painted |
---|---|
g | the paint graphics |
x | the x position of the painted border |
y | the y position of the painted border |
width | the width of the painted border |
height | the height of the painted border |