fi.hut.tml.xsmiles.gui.components.havi
Class HaviLabelCompound

java.lang.Object
  extended byfi.hut.tml.xsmiles.gui.components.havi.HaviLabelCompound
All Implemented Interfaces:
java.util.EventListener, java.awt.event.TextListener, XCompound, XLabelCompound

public class HaviLabelCompound
extends java.lang.Object
implements XLabelCompound, java.awt.event.TextListener

A caption object

Author:
Mikko Honkala

Field Summary
protected  int axis
          the axis depends on the caption side CSS attribute
protected  XCaption caption
          the caption component
static short CAPTION_BOTTOM
           
static short CAPTION_LEFT
           
static short CAPTION_RIGHT
           
static short CAPTION_TOP
           
protected  java.lang.String captionSide
          the caption-side string
protected  XComponent component
          the component itself
protected  java.awt.Component container
          the top-level container, containing the caption and the content component
protected  double currentZoom
           
protected  boolean layoutDone
           
static int X_AXIS
          Specifies that components should be laid out left to right.
static int Y_AXIS
          Specifies that components should be laid out top to bottom.
 
Constructor Summary
HaviLabelCompound(XComponent comp, XCaption capt, java.lang.String captSide)
           
 
Method Summary
 void add(XComponent c)
           
protected  void createContainer()
          creates the main container
 java.awt.Component getComponent()
          Return the visual component for this extension element
 java.awt.Dimension getSize()
          Returns the size of this compound
 void init()
           
protected  void layoutComponent()
          layouts the component using the caption, content and the main container parts of the control for havi, the components must be CSS formatted before this layout!!!!
 void remove(XComponent c)
           
 void removeAll()
          Remove all components from conatiner.
 void setVisible(boolean v)
          Set this drawing area visible.
 void setZoom(double zoom)
          Set's this components zoom (1.0 is the default).
 void textValueChanged(java.awt.event.TextEvent e)
          Invoked when the value of the text has changed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

caption

protected XCaption caption
the caption component


component

protected XComponent component
the component itself


captionSide

protected java.lang.String captionSide
the caption-side string


container

protected java.awt.Component container
the top-level container, containing the caption and the content component


axis

protected int axis
the axis depends on the caption side CSS attribute


layoutDone

protected boolean layoutDone

currentZoom

protected double currentZoom

X_AXIS

public static final int X_AXIS
Specifies that components should be laid out left to right.

See Also:
Constant Field Values

Y_AXIS

public static final int Y_AXIS
Specifies that components should be laid out top to bottom.

See Also:
Constant Field Values

CAPTION_TOP

public static final short CAPTION_TOP
See Also:
Constant Field Values

CAPTION_BOTTOM

public static final short CAPTION_BOTTOM
See Also:
Constant Field Values

CAPTION_LEFT

public static final short CAPTION_LEFT
See Also:
Constant Field Values

CAPTION_RIGHT

public static final short CAPTION_RIGHT
See Also:
Constant Field Values
Constructor Detail

HaviLabelCompound

public HaviLabelCompound(XComponent comp,
                         XCaption capt,
                         java.lang.String captSide)
Method Detail

init

public void init()

createContainer

protected void createContainer()
creates the main container


layoutComponent

protected void layoutComponent()
layouts the component using the caption, content and the main container parts of the control for havi, the components must be CSS formatted before this layout!!!!


setZoom

public void setZoom(double zoom)
Set's this components zoom (1.0 is the default).

Specified by:
setZoom in interface XCompound

getComponent

public java.awt.Component getComponent()
Description copied from interface: XCompound
Return the visual component for this extension element

Specified by:
getComponent in interface XCompound

getSize

public java.awt.Dimension getSize()
Description copied from interface: XCompound
Returns the size of this compound

Specified by:
getSize in interface XCompound

setVisible

public void setVisible(boolean v)
Set this drawing area visible.

Specified by:
setVisible in interface XCompound
Parameters:
v - true=visible, false=invisible

add

public void add(XComponent c)
Specified by:
add in interface XCompound
Parameters:
c - The component to be added

remove

public void remove(XComponent c)
Specified by:
remove in interface XCompound
Parameters:
c - Remove component c

removeAll

public void removeAll()
Remove all components from conatiner.

Specified by:
removeAll in interface XCompound

textValueChanged

public void textValueChanged(java.awt.event.TextEvent e)
Invoked when the value of the text has changed. The code written for this method performs the operations that need to occur when text changes.

Specified by:
textValueChanged in interface java.awt.event.TextListener


X-Smiles 1.2