public final class ConditionalBorder
extends javax.swing.border.AbstractBorder
| Constructor and Description |
|---|
ConditionalBorder(java.awt.Color color,
int thickness,
int innerThickness) |
| Modifier and Type | Method and Description |
|---|---|
java.awt.Color |
getBorderColor()
Returns the color of the border.
|
java.awt.Insets |
getBorderInsets(java.awt.Component c)
Returns the insets of the border.
|
java.awt.Insets |
getBorderInsets(java.awt.Component c,
java.awt.Insets insets)
Reinitialize the insets parameter with this Border's current Insets.
|
int |
getInnerThickness()
Returns the inner thickness of the border.
|
int |
getThickness()
Returns the thickness of the border.
|
boolean |
isBorderOpaque()
Returns whether or not the border is opaque.
|
void |
paintBorder(java.awt.Component c,
java.awt.Graphics g,
int x,
int y,
int width,
int height)
Paints the border for the specified component with the
specified position and size.
|
void |
setBorderColor(java.awt.Color borderColor)
Sets the color of the border.
|
void |
setInnerThickness(int innerThickness)
Sets the inner thickness of the border.
|
void |
setThickness(int thickness)
Sets the thickness of the border.
|
public ConditionalBorder(java.awt.Color color,
int thickness,
int innerThickness)
public void paintBorder(java.awt.Component c,
java.awt.Graphics g,
int x,
int y,
int width,
int height)
paintBorder in interface javax.swing.border.BorderpaintBorder in class javax.swing.border.AbstractBorderc - the component for which this border is being paintedg - the paint graphicsx - the x position of the painted bordery - the y position of the painted borderwidth - the width of the painted borderheight - the height of the painted borderpublic java.awt.Insets getBorderInsets(java.awt.Component c)
getBorderInsets in interface javax.swing.border.BordergetBorderInsets in class javax.swing.border.AbstractBorderc - the component for which this border insets value appliespublic java.awt.Insets getBorderInsets(java.awt.Component c,
java.awt.Insets insets)
getBorderInsets in class javax.swing.border.AbstractBorderc - the component for which this border insets value appliesinsets - the object to be reinitializedpublic java.awt.Color getBorderColor()
public void setBorderColor(java.awt.Color borderColor)
borderColor - the color of the border.public int getInnerThickness()
public void setInnerThickness(int innerThickness)
innerThickness - Returns the inner thickness of the border.public int getThickness()
public void setThickness(int thickness)
thickness - the thickness of the border.public boolean isBorderOpaque()
isBorderOpaque in interface javax.swing.border.BorderisBorderOpaque in class javax.swing.border.AbstractBorder