com.tensegrity.gui.swing.control
Class LabelLineBorder

java.lang.Object
  extended byjavax.swing.border.AbstractBorder
      extended byjavax.swing.border.TitledBorder
          extended bycom.tensegrity.gui.swing.control.LabelLineBorder
All Implemented Interfaces:
javax.swing.border.Border, java.io.Serializable

public class LabelLineBorder
extends javax.swing.border.TitledBorder

A header border as commonly seen in Windows or Mac-applciation. Just a line going over the whole width of the component with a title in the middle.

Version:
$Id: LabelLineBorder.java,v 1.2 2004/01/13 15:27:42 AndreasEbbert Exp $
Author:
Andreas Ebbert
See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.swing.border.TitledBorder
ABOVE_BOTTOM, ABOVE_TOP, BELOW_BOTTOM, BELOW_TOP, border, BOTTOM, CENTER, DEFAULT_JUSTIFICATION, DEFAULT_POSITION, LEADING, LEFT, RIGHT, TEXT_INSET_H, TEXT_SPACING, title, titleColor, titleFont, titleJustification, titlePosition, TOP, TRAILING
 
Constructor Summary
LabelLineBorder(java.lang.String title)
          Constructor specifying the title of the Border.
 
Method Summary
 java.awt.Insets getBorderInsets(java.awt.Component c)
           
 java.awt.Insets getBorderInsets(java.awt.Component c, java.awt.Insets insets)
           
 void paintBorder(java.awt.Component c, java.awt.Graphics g, int x, int y, int width, int height)
          Paints a label line border for the specified component.
 
Methods inherited from class javax.swing.border.TitledBorder
getBorder, getFont, getMinimumSize, getTitle, getTitleColor, getTitleFont, getTitleJustification, getTitlePosition, isBorderOpaque, setBorder, setTitle, setTitleColor, setTitleFont, setTitleJustification, setTitlePosition
 
Methods inherited from class javax.swing.border.AbstractBorder
getInteriorRectangle, getInteriorRectangle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LabelLineBorder

public LabelLineBorder(java.lang.String title)
Constructor specifying the title of the Border.

Parameters:
title - the title to use.
Method Detail

paintBorder

public void paintBorder(java.awt.Component c,
                        java.awt.Graphics g,
                        int x,
                        int y,
                        int width,
                        int height)
Paints a label line border for the specified component.

Parameters:
c - the component for which this border is being painted
g - the paint graphics
x - the x position of the painted border
y - the y position of the painted border
width - the width of the painted border
height - the height of the painted border

getBorderInsets

public java.awt.Insets getBorderInsets(java.awt.Component c)
See Also:
Border.getBorderInsets(java.awt.Component)

getBorderInsets

public java.awt.Insets getBorderInsets(java.awt.Component c,
                                       java.awt.Insets insets)
See Also:
AbstractBorder.getBorderInsets(java.awt.Component, java.awt.Insets)


Copyright © 2005 Tensegrity Software GmbH. All Rights Reserved. Date of creation: 09.06.2006.