org.smartui
Class SmartComponent

java.lang.Object
  |
  +--java.awt.Component
        |
        +--org.smartui.SmartComponent
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, Smart
Direct Known Subclasses:
Label3D

public class SmartComponent
extends java.awt.Component
implements Smart

SmartComponent is the component which can be transparent and can be used by other controls without being added as a control.

See Also:
Serialized Form

Inner classes inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent
 
Field Summary
protected  java.awt.Rectangle cliprect
           
 boolean transparent
           
 
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
SmartComponent()
          Creates new SmartComponent, default is transparent
 
Method Summary
 java.awt.Color getBackground()
           
 java.awt.Component getFather()
           
 java.awt.Font getFont()
           
 java.awt.Color getForeground()
           
 java.awt.Container getParent()
           
 java.awt.Dimension getPreferredSize()
           
 boolean isShowing()
           
 boolean isValid()
           
 void paint(java.awt.Graphics g)
          Paint grapchis according the transparent property
 void propertyChanged()
           
 void setFather(java.awt.Component cp)
           
 void update(java.awt.Graphics g)
          Update grapchis according the transparent property
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, deliverEvent, disable, disableEvents, dispatchEvent, doLayout, enable, enable, enableEvents, enableInputMethods, firePropertyChange, getAccessibleContext, getAlignmentX, getAlignmentY, getBounds, getBounds, getColorModel, getComponentAt, getComponentAt, getComponentOrientation, getCursor, getDropTarget, getFontMetrics, getGraphics, getGraphicsConfiguration, getHeight, getInputContext, getInputMethodRequests, getListeners, getLocale, getLocation, getLocation, getLocationOnScreen, getMaximumSize, getMinimumSize, getName, getPeer, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, invalidate, isDisplayable, isDoubleBuffered, isEnabled, isFocusTraversable, isLightweight, isOpaque, isVisible, keyDown, keyUp, layout, list, list, list, list, list, locate, location, lostFocus, minimumSize, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, paramString, postEvent, preferredSize, prepareImage, prepareImage, print, printAll, processComponentEvent, processEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFont, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, show, size, toString, transferFocus, validate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

transparent

public boolean transparent

cliprect

protected java.awt.Rectangle cliprect
Constructor Detail

SmartComponent

public SmartComponent()
Creates new SmartComponent, default is transparent
Method Detail

getFather

public java.awt.Component getFather()
Specified by:
getFather in interface Smart

setFather

public void setFather(java.awt.Component cp)
Specified by:
setFather in interface Smart

getPreferredSize

public java.awt.Dimension getPreferredSize()
Overrides:
getPreferredSize in class java.awt.Component

isShowing

public boolean isShowing()
Overrides:
isShowing in class java.awt.Component
Returns:
true if it is showing on the screen

isValid

public boolean isValid()
Overrides:
isValid in class java.awt.Component
Returns:
true if the component is valid

getFont

public java.awt.Font getFont()
Overrides:
getFont in class java.awt.Component
Returns:
the Font

getBackground

public java.awt.Color getBackground()
Overrides:
getBackground in class java.awt.Component
Returns:
the Background

getForeground

public java.awt.Color getForeground()
Overrides:
getForeground in class java.awt.Component
Returns:
the Foreground

getParent

public java.awt.Container getParent()
Overrides:
getParent in class java.awt.Component
Returns:
the Parent Container

update

public void update(java.awt.Graphics g)
Update grapchis according the transparent property
Overrides:
update in class java.awt.Component

paint

public void paint(java.awt.Graphics g)
Paint grapchis according the transparent property
Overrides:
paint in class java.awt.Component

propertyChanged

public void propertyChanged()
Specified by:
propertyChanged in interface Smart