Package net.infonode.tabbedpanel.border
Class GradientTabAreaBorder
- java.lang.Object
-
- net.infonode.tabbedpanel.border.GradientTabAreaBorder
-
- All Implemented Interfaces:
java.io.Serializable
,javax.swing.border.Border
public class GradientTabAreaBorder extends java.lang.Object implements javax.swing.border.Border, java.io.Serializable
Paints a gradient background for a tab area component. The background blends from one color on the component edge opposite to the tabbed panel content panel to the another color on the component edge closest to the tabbed panel content panel.- Since:
- ITP 1.1.0
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description GradientTabAreaBorder(java.awt.Color topColor)
Creates a border where the color of the component edge closest to the tabben panel content panel will be the default control color.GradientTabAreaBorder(java.awt.Color topColor, java.awt.Color bottomColor)
Constructor.GradientTabAreaBorder(ColorProvider topColorProvider, ColorProvider bottomColorProvider)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.awt.Insets
getBorderInsets(java.awt.Component c)
boolean
isBorderOpaque()
void
paintBorder(java.awt.Component component, java.awt.Graphics g, int x, int y, int width, int height)
-
-
-
Constructor Detail
-
GradientTabAreaBorder
public GradientTabAreaBorder(java.awt.Color topColor)
Creates a border where the color of the component edge closest to the tabben panel content panel will be the default control color.- Parameters:
topColor
- the color of the component edge opposite to the tabbed panel content panel
-
GradientTabAreaBorder
public GradientTabAreaBorder(java.awt.Color topColor, java.awt.Color bottomColor)
Constructor.- Parameters:
topColor
- the color of the component edge opposite to the tabbed panel content panelbottomColor
- the color of the component edge closest to the tabbed panel content panel
-
GradientTabAreaBorder
public GradientTabAreaBorder(ColorProvider topColorProvider, ColorProvider bottomColorProvider)
Constructor.- Parameters:
topColorProvider
- provides the color of the component edge opposite to the tabbed panel content panelbottomColorProvider
- provides the color of the component edge closest to the tabbed panel content panel
-
-
Method Detail
-
isBorderOpaque
public boolean isBorderOpaque()
- Specified by:
isBorderOpaque
in interfacejavax.swing.border.Border
-
paintBorder
public void paintBorder(java.awt.Component component, java.awt.Graphics g, int x, int y, int width, int height)
- Specified by:
paintBorder
in interfacejavax.swing.border.Border
-
getBorderInsets
public java.awt.Insets getBorderInsets(java.awt.Component c)
- Specified by:
getBorderInsets
in interfacejavax.swing.border.Border
-
-