dog.gui
Class DComponent

java.lang.Object
  |
  +--java.awt.Component
        |
        +--dog.gui.DComponent
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, Referential, java.io.Serializable
Direct Known Subclasses:
DCheckbox, DChoice, DLabel, DMenubar, DPicture, DProgress, DScrollbar

public abstract class DComponent
extends java.awt.Component
implements Referential

The base class for lightweight components.

All DComponents are beans, and property change listeners can register themselves for property changes. All DComponents can have a tooltip set, which will be managed by its root pane. Also you can set an arbitrary object reference for any component.

See Also:
Serialized Form

Inner classes inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent
 
Field Summary
static int CENTER
          The centre alignment.
static int CENTER_TILE
          Tiles the background image in the panel from the centre.
protected  java.beans.PropertyChangeSupport changes
          The property change support for components.
static int EAST
          The east alignment.
static int INTEGER_TILE
          Tiles the background image in the panel, resizing the image such that it its dimensions are factors of the panel dimensions.
static int MAXIMIZE
          Renders the background image to fit exactly into the panel, resizing its dimensions as necessary.
static int MAXIMIZE_ASPECT
          Renders the background image to fit into the panel, preserving the aspect ratio.
static int MAXIMIZE_HORIZONTAL
          Renders the background image to fit the width of the image into the panel.
static int MAXIMIZE_VERTICAL
          Renders the background image to fit the height of the image into the panel.
static int NORTH
          The north alignment.
static int NORTHEAST
          The northeast alignment.
static int NORTHWEST
          The northwest alignment.
protected  java.lang.Object reference
           
static int SOUTH
          The south alignment.
static int SOUTHEAST
          The southeast alignment.
static int SOUTHWEST
          The southwest alignment.
static int TILE
          Tiles the background image in the panel from the top left-hand corner.
protected  java.lang.String tooltip
           
static int WEST
          The west alignment.
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
DComponent()
          Construct a component.
 
Method Summary
 void addPropertyChangeListener(java.beans.PropertyChangeListener l)
          Adds a property change listener to receive notification of changes to this component.
protected  java.lang.String alignParamString(int align)
          Returns a description of alignment for debugging.
protected static void drawActiveButtonBorder(java.awt.Graphics g, java.awt.Rectangle r, java.awt.Color ds, java.awt.Color h, java.awt.Color c, java.awt.Color pc, java.awt.Color pcds)
          Draws a border for active buttons.
protected static void drawActiveOptionBorder(java.awt.Graphics g, java.awt.Rectangle r, java.awt.Color ds, java.awt.Color h, java.awt.Color c, java.awt.Color cs, java.awt.Color pc, java.awt.Color pcds)
          Draws a border for active options.
protected static void drawArrow(java.awt.Graphics g, java.awt.Rectangle r, boolean active, int orientation, java.awt.Color ds, java.awt.Color h, java.awt.Color pc)
          Draws an arrow inside the specified bounds rectangle.
protected static void drawBackgroundImage(java.awt.Graphics g, java.awt.Image image, java.awt.Rectangle bounds, java.awt.Dimension bs, java.awt.Rectangle br, int mode, java.awt.image.ImageObserver observer)
          Draws a background image for a root pane into the specified bounds rectangle according to the specified mode.
protected static void drawBorder(java.awt.Graphics g, java.awt.Rectangle r, java.awt.Color ds, java.awt.Color h, java.awt.Color c)
          Draws a border inside the specified bounds rectangle.
protected static void drawButtonBorder(java.awt.Graphics g, java.awt.Rectangle r, boolean active, java.awt.Color ds, java.awt.Color h, java.awt.Color c, java.awt.Color pc, java.awt.Color pcds)
          Draws a border for buttons.
protected static void drawCheckbox(java.awt.Graphics g, java.awt.Rectangle r, boolean active, boolean value, java.awt.Color ds, java.awt.Color h, java.awt.Color c, java.awt.Color cs, java.awt.Color pc, java.awt.Color pcds, java.awt.Color f)
          Draws a checkbox inside the specified bounds rectangle.
protected static void drawDarkBorder(java.awt.Graphics g, java.awt.Rectangle r, java.awt.Color ds, java.awt.Color h, java.awt.Color c, java.awt.Color cs)
          Draws a dark border for things like sticky buttons.
protected static void drawDefaultButtonBorder(java.awt.Graphics g, java.awt.Rectangle r, boolean active, java.awt.Color ds, java.awt.Color h, java.awt.Color c, java.awt.Color pc, java.awt.Color pcds)
          Draws a border for the default button in a pane.
protected static void drawDisabledBorder(java.awt.Graphics g, java.awt.Rectangle r, java.awt.Color d)
          Draws a disabled border inside the specified bounds rectangle.
protected static void drawDisabledCheckbox(java.awt.Graphics g, java.awt.Rectangle r, boolean value, java.awt.Color d)
          Draws a disabled checkbox inside the specified bounds rectangle.
protected static void drawDisabledOption(java.awt.Graphics g, java.awt.Rectangle r, boolean value, java.awt.Color d)
          Draws a disabled option inside the specified bounds rectangle.
protected static void drawExpander(java.awt.Graphics g, java.awt.Rectangle r, boolean active, boolean collapsed, java.awt.Color pc, java.awt.Color pch, java.awt.Color pcs, java.awt.Color pcds, java.awt.Color f)
          Draws an expansion symbol.
protected static void drawFocusBorder(java.awt.Graphics g, java.awt.Rectangle r, java.awt.Color f)
          Draws a focus border inside the specified bounds rectangle.
protected static void drawImage(java.awt.Graphics g, java.awt.Rectangle r, java.awt.Image image, java.awt.image.ImageObserver observer, int align)
          Draws an image into the specified bounds rectangle, rescaling it if necessary.
protected static void drawLabel(java.awt.Graphics g, java.awt.Rectangle r, java.awt.FontMetrics fm, java.lang.String label, int align, java.awt.Color f)
          Draws a multiline label in the specified bounds rectangle.
protected static void drawOption(java.awt.Graphics g, java.awt.Rectangle r, boolean active, boolean value, java.awt.Color ds, java.awt.Color h, java.awt.Color c, java.awt.Color cs, java.awt.Color pc, java.awt.Color pcds, java.awt.Color f)
          Draws an option inside the specified bounds rectangle.
protected static void drawOptionBorder(java.awt.Graphics g, java.awt.Rectangle r, java.awt.Color ds, java.awt.Color h, java.awt.Color c)
          Draws a border for options.
protected static void drawPressedBorder(java.awt.Graphics g, java.awt.Rectangle r, java.awt.Color ds, java.awt.Color h, java.awt.Color c, java.awt.Color cs)
          Draws a pressed border inside the specified bounds rectangle.
protected static void drawTick(java.awt.Graphics g, java.awt.Rectangle r, java.awt.Color c)
          Draws a tick inside the specified bounds rectangle.
static java.awt.Toolkit getDefaultToolkit()
          Returns the default toolkit.
static java.awt.Image getImage(java.awt.Image image, java.awt.image.ImageObserver observer)
          Returns images for observers.
static java.awt.Image getImage(java.lang.String file, java.awt.image.ImageObserver observer)
          Returns images for observers.
static java.awt.Image getImage(java.net.URL url, java.awt.image.ImageObserver observer)
          Returns images for observers.
 java.lang.Object getReference()
          Returns the object reference.
 DRootPane getRootPane()
          Returns the root pane for this component.
protected static java.lang.String[] getRows(java.awt.FontMetrics fm, java.lang.String label, int width)
          Returns the array of strings resulting from attempting to fit a string into a specified width, according to the specified font metrics and splitting the original string at spaces.
 java.lang.String getTooltip()
          Returns the tooltip label for this component.
static boolean isPreloadImages()
          Indicates whether to preload images from files or URLs.
protected  java.lang.String paramString()
          Returns additional parameters about the component.
static java.awt.Color parseColor(java.lang.String rgb)
          Returns a colour matching the specified RGB string.
static java.awt.Font parseFont(java.lang.String font)
          Returns a font matching the supplied font specification.
protected  void processCancelAction(java.awt.event.ActionEvent event)
          Activates the cancel button in the nearest container.
protected  void processDefaultAction(java.awt.event.ActionEvent event)
          Activates the default button in the nearest container.
protected  void processEvent(java.awt.AWTEvent event)
           
protected  void processMouseEvent(java.awt.event.MouseEvent event)
           
protected  void processMouseMotionEvent(java.awt.event.MouseEvent event)
           
 void removePropertyChangeListener(java.beans.PropertyChangeListener l)
          Removes a property change listener so it no longer receives notification of changes to this component.
 void setEnabled(boolean flag)
          Overrides setEnabled to repaint the component.
static void setPreloadImages(boolean flag)
          Sets whether to preload images from files or URLs.
 void setReference(java.lang.Object reference)
          Sets the object reference.
 void setTooltip(java.lang.String tooltip)
          Sets the tooltip label for this component.
 java.lang.String toString()
          Returns a string description of this component.
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addNotify, addPropertyChangeListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, deliverEvent, disable, disableEvents, dispatchEvent, doLayout, enable, enable, enableEvents, enableInputMethods, firePropertyChange, getAccessibleContext, getAlignmentX, getAlignmentY, getBackground, getBounds, getBounds, getColorModel, getComponentAt, getComponentAt, getComponentOrientation, getCursor, getDropTarget, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getInputContext, getInputMethodRequests, getListeners, getLocale, getLocation, getLocation, getLocationOnScreen, getMaximumSize, getMinimumSize, getName, getParent, getPeer, getPreferredSize, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, invalidate, isDisplayable, isDoubleBuffered, isEnabled, isFocusTraversable, isLightweight, isOpaque, isShowing, isValid, isVisible, keyDown, keyUp, layout, list, list, list, list, list, locate, location, lostFocus, minimumSize, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paint, paintAll, postEvent, preferredSize, prepareImage, prepareImage, print, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeNotify, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFont, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, show, size, transferFocus, update, validate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

CENTER

public static final int CENTER
The centre alignment. This can be used as a constant to render a background image centrally.

NORTH

public static final int NORTH
The north alignment.

EAST

public static final int EAST
The east alignment.

SOUTH

public static final int SOUTH
The south alignment.

WEST

public static final int WEST
The west alignment.

NORTHEAST

public static final int NORTHEAST
The northeast alignment.

SOUTHEAST

public static final int SOUTHEAST
The southeast alignment.

SOUTHWEST

public static final int SOUTHWEST
The southwest alignment.

NORTHWEST

public static final int NORTHWEST
The northwest alignment.

TILE

public static final int TILE
Tiles the background image in the panel from the top left-hand corner.

INTEGER_TILE

public static final int INTEGER_TILE
Tiles the background image in the panel, resizing the image such that it its dimensions are factors of the panel dimensions.

CENTER_TILE

public static final int CENTER_TILE
Tiles the background image in the panel from the centre.

MAXIMIZE

public static final int MAXIMIZE
Renders the background image to fit exactly into the panel, resizing its dimensions as necessary.

MAXIMIZE_ASPECT

public static final int MAXIMIZE_ASPECT
Renders the background image to fit into the panel, preserving the aspect ratio.

MAXIMIZE_VERTICAL

public static final int MAXIMIZE_VERTICAL
Renders the background image to fit the height of the image into the panel.

MAXIMIZE_HORIZONTAL

public static final int MAXIMIZE_HORIZONTAL
Renders the background image to fit the width of the image into the panel.

changes

protected java.beans.PropertyChangeSupport changes
The property change support for components.

reference

protected java.lang.Object reference

tooltip

protected java.lang.String tooltip
Constructor Detail

DComponent

public DComponent()
Construct a component.
Method Detail

getTooltip

public java.lang.String getTooltip()
Returns the tooltip label for this component.

setTooltip

public void setTooltip(java.lang.String tooltip)
Sets the tooltip label for this component.

processDefaultAction

protected void processDefaultAction(java.awt.event.ActionEvent event)
Activates the default button in the nearest container.

processCancelAction

protected void processCancelAction(java.awt.event.ActionEvent event)
Activates the cancel button in the nearest container.

setEnabled

public void setEnabled(boolean flag)
Overrides setEnabled to repaint the component.
Overrides:
setEnabled in class java.awt.Component

getDefaultToolkit

public static java.awt.Toolkit getDefaultToolkit()
Returns the default toolkit.

getImage

public static java.awt.Image getImage(java.awt.Image image,
                                      java.awt.image.ImageObserver observer)
Returns images for observers.

getImage

public static java.awt.Image getImage(java.lang.String file,
                                      java.awt.image.ImageObserver observer)
Returns images for observers.

getImage

public static java.awt.Image getImage(java.net.URL url,
                                      java.awt.image.ImageObserver observer)
Returns images for observers.

isPreloadImages

public static boolean isPreloadImages()
Indicates whether to preload images from files or URLs.

setPreloadImages

public static void setPreloadImages(boolean flag)
Sets whether to preload images from files or URLs.

getReference

public java.lang.Object getReference()
Returns the object reference.
Specified by:
getReference in interface Referential

setReference

public void setReference(java.lang.Object reference)
Sets the object reference.
Specified by:
setReference in interface Referential
Parameters:
reference - the object reference to store.

getRootPane

public DRootPane getRootPane()
Returns the root pane for this component.
See Also:
DRootPane

toString

public java.lang.String toString()
Returns a string description of this component.
Overrides:
toString in class java.awt.Component

paramString

protected java.lang.String paramString()
Returns additional parameters about the component.
Overrides:
paramString in class java.awt.Component

alignParamString

protected java.lang.String alignParamString(int align)
Returns a description of alignment for debugging.

parseColor

public static java.awt.Color parseColor(java.lang.String rgb)
Returns a colour matching the specified RGB string.
Parameters:
rgb - a string in RGB format

parseFont

public static java.awt.Font parseFont(java.lang.String font)
Returns a font matching the supplied font specification.
Parameters:
font - a font specification of the form [name[,size | ,style[,size]]]

drawBorder

protected static void drawBorder(java.awt.Graphics g,
                                 java.awt.Rectangle r,
                                 java.awt.Color ds,
                                 java.awt.Color h,
                                 java.awt.Color c)
Draws a border inside the specified bounds rectangle.
Parameters:
g - the graphics context
r - the bounding rectangle of the border
ds - the control dark shadow colour to use
h - the control highlight colour to use
c - the control colour to use

drawFocusBorder

protected static void drawFocusBorder(java.awt.Graphics g,
                                      java.awt.Rectangle r,
                                      java.awt.Color f)
Draws a focus border inside the specified bounds rectangle.
Parameters:
g - the graphics context
r - the bounding rectangle of the border
f - the control focus to use

drawPressedBorder

protected static void drawPressedBorder(java.awt.Graphics g,
                                        java.awt.Rectangle r,
                                        java.awt.Color ds,
                                        java.awt.Color h,
                                        java.awt.Color c,
                                        java.awt.Color cs)
Draws a pressed border inside the specified bounds rectangle. Used for things like pressed buttons.
Parameters:
g - the graphics context
r - the bounding rectangle of the border
ds - the control dark shadow colour to use
h - the control highlight colour to use
c - the control colour to use
cs - the control shadow colour to use

drawDisabledBorder

protected static void drawDisabledBorder(java.awt.Graphics g,
                                         java.awt.Rectangle r,
                                         java.awt.Color d)
Draws a disabled border inside the specified bounds rectangle.
Parameters:
g - the graphics context
r - the bounding rectangle of the border
d - the control disabled colour to use

drawDarkBorder

protected static void drawDarkBorder(java.awt.Graphics g,
                                     java.awt.Rectangle r,
                                     java.awt.Color ds,
                                     java.awt.Color h,
                                     java.awt.Color c,
                                     java.awt.Color cs)
Draws a dark border for things like sticky buttons.
Parameters:
g - the graphics context
r - the bounding rectangle of the border
c - the control colour to use
cs - the control shadow colour to use

drawButtonBorder

protected static void drawButtonBorder(java.awt.Graphics g,
                                       java.awt.Rectangle r,
                                       boolean active,
                                       java.awt.Color ds,
                                       java.awt.Color h,
                                       java.awt.Color c,
                                       java.awt.Color pc,
                                       java.awt.Color pcds)
Draws a border for buttons.
Parameters:
g - the graphics context
r - the bounding rectangle of the border
active - whether the button is active
ds - the control dark shadow colour to use
h - the control highlight colour to use
c - the control colour to use
pc - the primary control colour to use
pcds - the primary control dark shadow colour to use

drawActiveButtonBorder

protected static void drawActiveButtonBorder(java.awt.Graphics g,
                                             java.awt.Rectangle r,
                                             java.awt.Color ds,
                                             java.awt.Color h,
                                             java.awt.Color c,
                                             java.awt.Color pc,
                                             java.awt.Color pcds)
Draws a border for active buttons.
Parameters:
g - the graphics context
r - the bounding rectangle of the border
ds - the control dark shadow colour to use
h - the control highlight colour to use
c - the control colour to use
pc - the primary control colour to use
pcds - the primary control dark shadow colour to use

drawDefaultButtonBorder

protected static void drawDefaultButtonBorder(java.awt.Graphics g,
                                              java.awt.Rectangle r,
                                              boolean active,
                                              java.awt.Color ds,
                                              java.awt.Color h,
                                              java.awt.Color c,
                                              java.awt.Color pc,
                                              java.awt.Color pcds)
Draws a border for the default button in a pane.
Parameters:
g - the graphics context
r - the bounding rectangle of the border
active - whether the button is active
ds - the control dark shadow colour to use
h - the control highlight colour to use
c - the control colour to use
pc - the primary control colour to use
pcds - the primary control dark shadow colour to use

drawArrow

protected static void drawArrow(java.awt.Graphics g,
                                java.awt.Rectangle r,
                                boolean active,
                                int orientation,
                                java.awt.Color ds,
                                java.awt.Color h,
                                java.awt.Color pc)
Draws an arrow inside the specified bounds rectangle.
Parameters:
g - the graphics context
r - the bounding rectangle of the arrow
active - if true, fills the arrow with the primary control colour
orientation - the orientation of the apex of the arrow (NORTH, EAST, SOUTH, or WEST)
ds - the control dark shadow colour to use
h - the control highlight colour to use
pc - the primary control colour to use

drawCheckbox

protected static void drawCheckbox(java.awt.Graphics g,
                                   java.awt.Rectangle r,
                                   boolean active,
                                   boolean value,
                                   java.awt.Color ds,
                                   java.awt.Color h,
                                   java.awt.Color c,
                                   java.awt.Color cs,
                                   java.awt.Color pc,
                                   java.awt.Color pcds,
                                   java.awt.Color f)
Draws a checkbox inside the specified bounds rectangle.
Parameters:
g - the graphics context
r - the bounding rectangle of the check
active - whether the checkbox is active
value - if true, draws a check mark
ds - the control dark shadow colour to use
h - the control highlight colour to use
c - the control colour to use
pc - the primary control colour to use
pcds - the primary control dark shadow colour to use
f - the colour to draw the check in

drawDisabledCheckbox

protected static void drawDisabledCheckbox(java.awt.Graphics g,
                                           java.awt.Rectangle r,
                                           boolean value,
                                           java.awt.Color d)
Draws a disabled checkbox inside the specified bounds rectangle.
Parameters:
g - the graphics context
r - the bounding rectangle of the check
value - if true, draws a check mark
d - the control disabled colour to use

drawTick

protected static void drawTick(java.awt.Graphics g,
                               java.awt.Rectangle r,
                               java.awt.Color c)
Draws a tick inside the specified bounds rectangle.
Parameters:
g - the graphics context
r - the bounding rectangle of the check
c - the colour to use

drawOption

protected static void drawOption(java.awt.Graphics g,
                                 java.awt.Rectangle r,
                                 boolean active,
                                 boolean value,
                                 java.awt.Color ds,
                                 java.awt.Color h,
                                 java.awt.Color c,
                                 java.awt.Color cs,
                                 java.awt.Color pc,
                                 java.awt.Color pcds,
                                 java.awt.Color f)
Draws an option inside the specified bounds rectangle.
Parameters:
g - the graphics context
r - the bounding rectangle of the circle
active - whether the option is active
value - if true, draws a dot in the circle
ds - the control dark shadow colour to use
h - the control highlight colour to use
c - the control colour to use
pc - the primary control colour to use
pcds - the primary control dark shadow colour to use
f - the colour to draw the dot in

drawDisabledOption

protected static void drawDisabledOption(java.awt.Graphics g,
                                         java.awt.Rectangle r,
                                         boolean value,
                                         java.awt.Color d)
Draws a disabled option inside the specified bounds rectangle.
Parameters:
g - the graphics context
r - the bounding rectangle of the circle
value - if true, draws a dot in the circle
d - the control disabled colour to use

drawOptionBorder

protected static void drawOptionBorder(java.awt.Graphics g,
                                       java.awt.Rectangle r,
                                       java.awt.Color ds,
                                       java.awt.Color h,
                                       java.awt.Color c)
Draws a border for options.
Parameters:
g - the graphics context
r - the bounding rectangle of the border
ds - the control dark shadow colour to use
h - the control highlight colour to use
c - the control colour to use

drawActiveOptionBorder

protected static void drawActiveOptionBorder(java.awt.Graphics g,
                                             java.awt.Rectangle r,
                                             java.awt.Color ds,
                                             java.awt.Color h,
                                             java.awt.Color c,
                                             java.awt.Color cs,
                                             java.awt.Color pc,
                                             java.awt.Color pcds)
Draws a border for active options.
Parameters:
g - the graphics context
r - the bounding rectangle of the border
ds - the control dark shadow colour to use
h - the control highlight colour to use
c - the control colour to use
pc - the primary control colour to use
pcds - the primary control dark shadow colour to use

drawExpander

protected static void drawExpander(java.awt.Graphics g,
                                   java.awt.Rectangle r,
                                   boolean active,
                                   boolean collapsed,
                                   java.awt.Color pc,
                                   java.awt.Color pch,
                                   java.awt.Color pcs,
                                   java.awt.Color pcds,
                                   java.awt.Color f)
Draws an expansion symbol.
Parameters:
g - the graphics context
r - the bounding rectangle of the symbol
active - whether the symbol is active (pressed)
collapsed - whether the symbol is collapsed
pc - the primary control colour to use
pch - the primary control highlight colour to use
pcs - the primary control shadow colour to use
pcds - the primary control dark shadow colour to use
f - the foreground colour to use

drawLabel

protected static void drawLabel(java.awt.Graphics g,
                                java.awt.Rectangle r,
                                java.awt.FontMetrics fm,
                                java.lang.String label,
                                int align,
                                java.awt.Color f)
Draws a multiline label in the specified bounds rectangle.
Parameters:
g - the graphics context
r - the bounding rectangle of the label
fm - the font metrics to apply to the string
label - the label string
align - the alignment of the label within the bounds
f - the colour of the text

getRows

protected static java.lang.String[] getRows(java.awt.FontMetrics fm,
                                            java.lang.String label,
                                            int width)
Returns the array of strings resulting from attempting to fit a string into a specified width, according to the specified font metrics and splitting the original string at spaces. This preserves line breaks.

drawImage

protected static void drawImage(java.awt.Graphics g,
                                java.awt.Rectangle r,
                                java.awt.Image image,
                                java.awt.image.ImageObserver observer,
                                int align)
Draws an image into the specified bounds rectangle, rescaling it if necessary.
Parameters:
g - the graphics context
r - the bounding rectangle of the image
image - the image to draw
align - how to align the image within the bounds

drawBackgroundImage

protected static void drawBackgroundImage(java.awt.Graphics g,
                                          java.awt.Image image,
                                          java.awt.Rectangle bounds,
                                          java.awt.Dimension bs,
                                          java.awt.Rectangle br,
                                          int mode,
                                          java.awt.image.ImageObserver observer)
Draws a background image for a root pane into the specified bounds rectangle according to the specified mode.
Parameters:
g - the graphics context
bs - the size of the image
bounds - the bounding rectangle of the target area
br - the bounding rectangle of the target area
image - the image to draw
mode - how to render the image within the bounds

addPropertyChangeListener

public void addPropertyChangeListener(java.beans.PropertyChangeListener l)
Adds a property change listener to receive notification of changes to this component.
Overrides:
addPropertyChangeListener in class java.awt.Component
Parameters:
l - the listener

removePropertyChangeListener

public void removePropertyChangeListener(java.beans.PropertyChangeListener l)
Removes a property change listener so it no longer receives notification of changes to this component.
Overrides:
removePropertyChangeListener in class java.awt.Component
Parameters:
l - the listener

processEvent

protected void processEvent(java.awt.AWTEvent event)
Overrides:
processEvent in class java.awt.Component

processMouseEvent

protected void processMouseEvent(java.awt.event.MouseEvent event)
Overrides:
processMouseEvent in class java.awt.Component

processMouseMotionEvent

protected void processMouseMotionEvent(java.awt.event.MouseEvent event)
Overrides:
processMouseMotionEvent in class java.awt.Component