org.openbp.swing.plaf.sky
Class ShadowBorder

java.lang.Object
  extended by javax.swing.border.AbstractBorder
      extended by org.openbp.swing.plaf.sky.ShadowBorder
All Implemented Interfaces:
java.io.Serializable, javax.swing.border.Border

public class ShadowBorder
extends javax.swing.border.AbstractBorder

Border for Panels. This Border paint a Rectangle and place a shadow at the right and at the bottom. This Border can be used to give any component a shadow.

Author:
Jens Ferchland
See Also:
Serialized Form

Constructor Summary
ShadowBorder()
          Creates a new ShadowBorder with a inlay border.
ShadowBorder(boolean inlayBorder)
          Creats a new shadow border.
 
Method Summary
 java.awt.Insets getBorderInsets(java.awt.Component c)
          See AbstractBorder#getBorderInsets (Component c)
 void paintBorder(java.awt.Component c, java.awt.Graphics g, int x, int y, int width, int height)
          see AbstractBorder#paintBorder (Component c, Graphics g, int x, int y, int width, int height)
 
Methods inherited from class javax.swing.border.AbstractBorder
getBaseline, getBaselineResizeBehavior, getBorderInsets, getInteriorRectangle, getInteriorRectangle, isBorderOpaque
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ShadowBorder

public ShadowBorder(boolean inlayBorder)
Creats a new shadow border. The inlay border is .

Parameters:
inlayBorder - true Paints the inlay border (a small line around the component).
false Paints the shadow only.

ShadowBorder

public ShadowBorder()
Creates a new ShadowBorder with a inlay border.

Method Detail

paintBorder

public void paintBorder(java.awt.Component c,
                        java.awt.Graphics g,
                        int x,
                        int y,
                        int width,
                        int height)
see AbstractBorder#paintBorder (Component c, Graphics g, int x, int y, int width, int height)

Specified by:
paintBorder in interface javax.swing.border.Border
Overrides:
paintBorder in class javax.swing.border.AbstractBorder

getBorderInsets

public java.awt.Insets getBorderInsets(java.awt.Component c)
See AbstractBorder#getBorderInsets (Component c)

Specified by:
getBorderInsets in interface javax.swing.border.Border
Overrides:
getBorderInsets in class javax.swing.border.AbstractBorder


Copyright © 2011. All Rights Reserved.