Ascent Phase Corp.

org.ascentphase.suit
Class TitleBar

java.lang.Object
  |
  +--org.ascentphase.suit.Widget
        |
        +--org.ascentphase.suit.TitleBar

public class TitleBar
extends Widget

This widget draws the titlebar on the Panel.

Version:
Author:
huyd

Field Summary
protected  java.lang.String title
          The text of the titlebar
protected  int width
          The width, in pixels, of the titlebar
 
Fields inherited from class org.ascentphase.suit.Widget
cmdToThrow
 
Constructor Summary
TitleBar(java.lang.String title, int width)
          Initialize the titlebar with the given text and width in pixels.
 
Method Summary
 void paint(Graphics g)
          Draws the widget.
 
Methods inherited from class org.ascentphase.suit.Widget
contains, getCommand, keyPressed, keyReleased, pointerDragged, pointerPressed, pointerReleased, setCommand
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

title

protected java.lang.String title
The text of the titlebar


width

protected int width
The width, in pixels, of the titlebar

Constructor Detail

TitleBar

public TitleBar(java.lang.String title,
                int width)
Initialize the titlebar with the given text and width in pixels.

Parameters:
title - the text title.
width - the width of the titlebar in pixels.
Method Detail

paint

public void paint(Graphics g)
Draws the widget.

Specified by:
paint in class Widget
Parameters:
g - the Graphics object to draw with.

Ascent Phase Corp.

Copyright © 2002 Ascent Phase Corp. All Rights Reserved.