org.zaval.lw.theme
Class LwTitledBorder
java.lang.Object
|
+--org.zaval.lw.LwView
|
+--org.zaval.lw.theme.LwBorder
|
+--org.zaval.lw.theme.LwTitledBorder
- All Implemented Interfaces:
- Validationable
- public class LwTitledBorder
- extends LwBorder
This class implements generic border render that can have a title area. To have a title area
the target component (for what the border is set) has to implement TitleInfo interface, otherwise.
the class will work as the LwBorder class. The rendering is customized by
LwLineRender class. The class specifies top, left, bottom and right lines rendering rules.
|
Constructor Summary |
LwTitledBorder(java.awt.Color c)
Constructs the border render that paints border using the specified color.
|
LwTitledBorder(java.awt.Color c,
int size)
Constructs the border render that paints border using the specified color and
the given border lines thickness. |
LwTitledBorder(LwLineRender r)
Constructs the border render that paints border using the specified line render.
|
LwTitledBorder(LwLineRender r,
int a)
Constructs the border render that paints border using the specified line render
and the given title alignment. |
|
Method Summary |
void |
paint(java.awt.Graphics g,
int x,
int y,
int w,
int h,
Layoutable d)
Paints the view using the given width and height. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LwTitledBorder
public LwTitledBorder(java.awt.Color c)
- Constructs the border render that paints border using the specified color.
The border thickness is 1, the title alignment is bottom.
- Parameters:
c - the specified border color.
LwTitledBorder
public LwTitledBorder(java.awt.Color c,
int size)
- Constructs the border render that paints border using the specified color and
the given border lines thickness. The title alignment is bottom.
- Parameters:
c - the specified border color.size - the given border lines thickness.
LwTitledBorder
public LwTitledBorder(LwLineRender r)
- Constructs the border render that paints border using the specified line render.
The title alignment is bottom.
- Parameters:
r - the specified line render.
LwTitledBorder
public LwTitledBorder(LwLineRender r,
int a)
- Constructs the border render that paints border using the specified line render
and the given title alignment.
- Parameters:
r - the specified line render.a - the given title alignment. The alignment specifies the place where a title
is placed. Use LwToolkit.TOP, LwToolkit.LEFT, LwToolkit.RIGHT or LwToolkit.BOTTOM.
paint
public void paint(java.awt.Graphics g,
int x,
int y,
int w,
int h,
Layoutable d)
- Description copied from class:
LwView
- Paints the view using the given width and height. The location where the
view has to be painted is determined with the
x and y
coordinates. This abstract method has to be implemented to define a "face" for the view.
- Overrides:
paint in class LwBorder
- Following copied from class:
org.zaval.lw.LwView
- Parameters:
g - the specified context to be used for painting.x - the x coordinate.y - the y coordinate.w - the width of the view.h - the height of the view.d - the owner component.
|