SmartFrog 3.10.000

org.smartfrog.services.display
Class WindowUtilities

java.lang.Object
  extended by org.smartfrog.services.display.WindowUtilities

Deprecated. 12 December 2001

public class WindowUtilities
extends java.lang.Object

Window Utilities to handle some common window and frame representation problems


Field Summary
protected static java.awt.Color[] colorList
          Deprecated. Default color list
protected static java.util.Hashtable colorNames
          Deprecated. Hastable to associate color and names
protected static boolean graphicsAvailable
          Deprecated. Boolean to indicate graphic mode available
protected static int usedColorListIndexes
          Deprecated. Selected color index
 
Method Summary
static boolean areGraphicsAvailable()
          Deprecated. Check if graphics is available
static void center(java.awt.Container parent, java.awt.Component comp)
          Deprecated. Centres a component inside a awt container.
static void disposeProgressBar(javax.swing.JProgressBar jpb)
          Deprecated. Disposes progress bar's container
static java.awt.Color getColorAssociated(java.lang.String name)
          Deprecated. Returns a color associated to the given name
static java.awt.Rectangle getScreenRectangle(java.awt.Component comp)
          Deprecated. Returns the usable screen rectangle size for a componen deleting the lower part of the screen not to hide the start bar.
static boolean getUserConfirmation(java.awt.Component cp, java.lang.String message)
          Deprecated. Asks the user confirmation
static java.lang.String getUserInputString(java.lang.String message)
          Deprecated. Inputs Dialog to retrieve a parameter
static void hideProgressBar(javax.swing.JProgressBar jpb)
          Deprecated. Hides the progress bar's container
static void incProgressBar(javax.swing.JProgressBar jpb)
          Deprecated. Increments the progress bar.
static void setPositionDisplay(java.awt.Container parent, java.awt.Component comp, java.lang.String positionDisplay)
          Deprecated. Positions a component inside a container if the conatiner is null the component is centered in the screen.
static void setPositionWindow(java.awt.Container parent, java.awt.Component comp, int positionN, int positionW)
          Deprecated. Positions a component inside a container.
static void showError(java.awt.Component cp, java.lang.String message)
          Deprecated. Outputs an error message to the user
static javax.swing.JWindow showLogo(javax.swing.ImageIcon logo)
          Deprecated. Shows the given Image as a logo on a simple window
static javax.swing.JProgressBar showLogoProgressBar(javax.swing.ImageIcon logo, int steps)
          Deprecated. Shows progress bar with logo
static void showMessage(java.awt.Component cp, java.lang.String message)
          Deprecated. Outputs a typed message to the user
static javax.swing.JProgressBar showProgressBar(java.lang.String message, int steps)
          Deprecated. Shows the progress bar.
static void showWarning(java.awt.Component cp, java.lang.String message)
          Deprecated. Outputs a warning message to the user
static boolean testGraphics()
          Deprecated. Tests the graphics and prints message that it is available.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

graphicsAvailable

protected static boolean graphicsAvailable
Deprecated. 
Boolean to indicate graphic mode available


colorNames

protected static java.util.Hashtable colorNames
Deprecated. 
Hastable to associate color and names


colorList

protected static java.awt.Color[] colorList
Deprecated. 
Default color list


usedColorListIndexes

protected static int usedColorListIndexes
Deprecated. 
Selected color index

Method Detail

areGraphicsAvailable

public static boolean areGraphicsAvailable()
Deprecated. 
Check if graphics is available

Returns:
true if graphics is available else false

testGraphics

public static boolean testGraphics()
Deprecated. 
Tests the graphics and prints message that it is available.

Returns:
true if graphics works fine else false

center

public static void center(java.awt.Container parent,
                          java.awt.Component comp)
Deprecated. 
Centres a component inside a awt container.

If the conatiner is null the component is centered in the screen.

Parameters:
parent - The awt container
comp - The component

setPositionWindow

public static void setPositionWindow(java.awt.Container parent,
                                     java.awt.Component comp,
                                     int positionN,
                                     int positionW)
Deprecated. 
Positions a component inside a container.

If the conatiner is null the component is centered in the screen.

Parameters:
parent - The container
comp - The component
positionN - The new position value at y axis
positionW - The new position value at x axis

setPositionDisplay

public static void setPositionDisplay(java.awt.Container parent,
                                      java.awt.Component comp,
                                      java.lang.String positionDisplay)
Deprecated. 
Positions a component inside a container if the conatiner is null the component is centered in the screen.

Parameters:
parent - The AWT parent
comp - The component
positionDisplay - The new direction for value

getScreenRectangle

public static java.awt.Rectangle getScreenRectangle(java.awt.Component comp)
Deprecated. 
Returns the usable screen rectangle size for a componen deleting the lower part of the screen not to hide the start bar.

Parameters:
comp - The component
Returns:
The screenRectangle value

showLogo

public static javax.swing.JWindow showLogo(javax.swing.ImageIcon logo)
Deprecated. 
Shows the given Image as a logo on a simple window

Parameters:
logo - image icon for the logo
Returns:
JWindow after setting the logo

showProgressBar

public static javax.swing.JProgressBar showProgressBar(java.lang.String message,
                                                       int steps)
Deprecated. 
Shows the progress bar.

Parameters:
message - Message displayed in progress bar.
steps - Steps
Returns:
JProgressBar with message

showLogoProgressBar

public static javax.swing.JProgressBar showLogoProgressBar(javax.swing.ImageIcon logo,
                                                           int steps)
Deprecated. 
Shows progress bar with logo

Parameters:
logo - logo
steps - steps
Returns:
JProgressBar object with logo

incProgressBar

public static void incProgressBar(javax.swing.JProgressBar jpb)
Deprecated. 
Increments the progress bar.

Parameters:
jpb - JProgressBar object

disposeProgressBar

public static void disposeProgressBar(javax.swing.JProgressBar jpb)
Deprecated. 
Disposes progress bar's container

Parameters:
jpb - JProgressBar object

hideProgressBar

public static void hideProgressBar(javax.swing.JProgressBar jpb)
Deprecated. 
Hides the progress bar's container

Parameters:
jpb - JProgressBar object

getColorAssociated

public static java.awt.Color getColorAssociated(java.lang.String name)
Deprecated. 
Returns a color associated to the given name

Parameters:
name - Color Name
Returns:
The color value associated with the color name

getUserInputString

public static java.lang.String getUserInputString(java.lang.String message)
Deprecated. 
Inputs Dialog to retrieve a parameter

Parameters:
message - message
Returns:
The userInputString value

getUserConfirmation

public static boolean getUserConfirmation(java.awt.Component cp,
                                          java.lang.String message)
Deprecated. 
Asks the user confirmation

Parameters:
cp - Component
message - Message
Returns:
The user confirmation value

showMessage

public static void showMessage(java.awt.Component cp,
                               java.lang.String message)
Deprecated. 
Outputs a typed message to the user

Parameters:
cp - Component
message - message

showWarning

public static void showWarning(java.awt.Component cp,
                               java.lang.String message)
Deprecated. 
Outputs a warning message to the user

Parameters:
cp - Component
message - warning message

showError

public static void showError(java.awt.Component cp,
                             java.lang.String message)
Deprecated. 
Outputs an error message to the user

Parameters:
cp - Component
message - error message

SmartFrog CORE 3.10.000

(C) Copyright 1998-2006 Hewlett-Packard Development Company, LP