final class ShadowPopupBorder
extends javax.swing.border.AbstractBorder
ShadowPopup,
ShadowPopupFactory| Modifier and Type | Field and Description |
|---|---|
private static ShadowPopupBorder |
instance
The singleton instance used to draw all borders.
|
private static java.awt.Image |
shadow
The drop shadow is created from a PNG image with 8 bit alpha channel.
|
private static int |
SHADOW_SIZE
The drop shadow needs 5 pixels at the bottom and the right hand side.
|
| Constructor and Description |
|---|
ShadowPopupBorder() |
| Modifier and Type | Method and Description |
|---|---|
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)
Reinitializes the insets parameter with this Border's current Insets.
|
static ShadowPopupBorder |
getInstance()
Returns the singleton instance used to draw all borders.
|
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.
|
private static final int SHADOW_SIZE
private static ShadowPopupBorder instance
private static java.awt.Image shadow
public static ShadowPopupBorder getInstance()
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.AbstractBorderpublic java.awt.Insets getBorderInsets(java.awt.Component c)
getBorderInsets in interface javax.swing.border.BordergetBorderInsets in class javax.swing.border.AbstractBorderpublic 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 reinitializedinsets object