All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class COM.ibm.beans.gauge.BorderBackground

java.lang.Object
   |
   +----COM.ibm.beans.gauge.BorderBackground

public class BorderBackground
extends Object
implements Background

This class implements a range of standard border types with variable widths.


Variable Index

 o CRAFTED_RAISED
A 3D crafted raised border style.
 o CRAFTED_RECESSED
A 3D crafted recessed border style.
 o MARGIN
A plain margin border style.
 o NONE
No border style.

Constructor Index

 o BorderBackground(int)
Create a BorderBackground with the given border style.
 o BorderBackground(int, int, int, int)
Create a BorderBackground with the given border style and widths.
 o BorderBackground(int, int, int, int, Color, Color)
Create a BorderBackground with the given border style, widths, and colors.

Method Index

 o copyright()
 
 o dispose()
 
 o insets()
Return the insets occupied by the border.
 o render(Graphics, int, int, int, int)
Render the border onto a graphics, within the rectangle specified.
 o setBackground(Color)
Set the background color for the border.
 o setBorder(int)
Set the border style.
 o setBorder(int, int, int, int)
Set the border style and widths.
 o setBorder(int, int, int, int, Color, Color)
Set the border style and widths and colors.
 o setForeground(Color)
Set the foreground color for the border.

Variables

 o NONE

 public static final int NONE
No border style.

 o MARGIN

 public static final int MARGIN
A plain margin border style.

 o CRAFTED_RAISED

 public static final int CRAFTED_RAISED
A 3D crafted raised border style.

 o CRAFTED_RECESSED

 public static final int CRAFTED_RECESSED
A 3D crafted recessed border style.

Constructors

 o BorderBackground

 public BorderBackground(int borderstyle)
Create a BorderBackground with the given border style. The border width is one.
Parameters:
borderstyle - the border style flag.

 o BorderBackground

 public BorderBackground(int borderstyle,
                         int outergap,
                         int borderwidth,
                         int innergap)
Create a BorderBackground with the given border style and widths.
Parameters:
borderstyle - the border style flag.
outergap - the pixel width to leave outside the border.
borderwidth - the pixel width of the border itself.
innergap - the pixel width to leave inside the border.

 o BorderBackground

 public BorderBackground(int borderstyle,
                         int outergap,
                         int borderwidth,
                         int innergap,
                         Color background,
                         Color foreground)
Create a BorderBackground with the given border style, widths, and colors.
Parameters:
borderstyle - the border style flag.
outergap - the pixel width to leave outside the border.
borderwidth - the pixel width of the border itself.
innergap - the pixel width to leave inside the border.
background - the color for background areas of the border.
foreground - the color for foreground areas of the border.

Methods

 o copyright

 public static String copyright()

 o setBorder

 public void setBorder(int borderstyle)
Set the border style.
Parameters:
borderstyle - the border style flag.

 o setBorder

 public void setBorder(int borderstyle,
                       int outergap,
                       int borderwidth,
                       int innergap)
Set the border style and widths.
Parameters:
borderstyle - the border style flag.
outergap - the pixel width to leave outside the border.
borderwidth - the pixel width of the border itself.
innergap - the pixel width to leave inside the border.

 o setBorder

 public void setBorder(int borderstyle,
                       int outergap,
                       int borderwidth,
                       int innergap,
                       Color background,
                       Color foreground)
Set the border style and widths and colors.
Parameters:
borderstyle - the border style flag.
outergap - the pixel width to leave outside the border.
borderwidth - the pixel width of the border itself.
innergap - the pixel width to leave inside the border.
background - the color for background areas of the border.
foreground - the color for foreground areas of the border.

 o setBackground

 public void setBackground(Color background)
Set the background color for the border. This color is used for outer and inner margins. If null is specified, the current graphics color is used when the border is rendered.

 o setForeground

 public void setForeground(Color foreground)
Set the foreground color for the border. This color is used for the border itself. If null is specified, the current graphics color is used when the border is rendered.

 o render

 public void render(Graphics g,
                    int x,
                    int y,
                    int width,
                    int height)
Render the border onto a graphics, within the rectangle specified. Plain margins are drawn in the current graphics foreground color.

 o insets

 public Insets insets()
Return the insets occupied by the border. These insets are determined by the border style and widths.

 o dispose

 public void dispose()

All Packages  Class Hierarchy  This Package  Previous  Next  Index

Copyright © Taligent, Inc. 1996 - 1997.
Copyright
© IBM Corporation 1996 - 1997.
All Rights Reserved.