|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectfi.hut.tml.xsmiles.gui.components.general.ComponentBase
Interface to plain GUI component The GUI component package contains an abstract set of components that can generally be used.
| Field Summary | |
java.awt.Component |
content
the content component |
protected java.awt.Font |
currentFont
|
protected double |
currentZoom
The current zoom level of this component (default = 1.00) |
protected java.awt.Color |
defaultBGColor
the default background color |
protected java.awt.Font |
defaultFont
|
protected java.awt.Dimension |
defaultSize
|
protected java.lang.String |
fInputMode
|
protected java.lang.String |
hintText
|
protected static java.awt.Dimension |
minSize
|
protected org.w3c.dom.css.CSSStyleDeclaration |
style
The CSS for the main component |
| Constructor Summary | |
ComponentBase()
|
|
| Method Summary | |
void |
addActionListener(java.awt.event.ActionListener al)
|
void |
addFocusListener(java.awt.event.FocusListener fl)
|
void |
addHelpListener(java.awt.event.ActionListener fl)
add a listener for help events |
void |
addMouseListener(java.awt.event.MouseListener ml)
|
java.awt.Component |
getAddableComponent()
|
java.awt.Component |
getComponent()
|
java.awt.Color |
getDefaultBackgroundColor()
the default background color for this type of component null = transparent. |
java.awt.Dimension |
getDefaultSize()
returns the default size, calculated in the beginning |
boolean |
getEnabled()
|
CSSFormatter |
getFormatter()
|
int |
getHeight()
|
java.awt.Dimension |
getMinimumSize()
return the minimum size for this component at zoom level 1.0 |
java.awt.Dimension |
getPreferredSize(java.awt.Component comp)
in AWT, we must do extra tricks to get the preferred size before the component is on screen |
java.awt.Component |
getSizableComponent()
|
java.awt.Dimension |
getSize()
|
java.awt.Component |
getStylableComponent()
|
org.w3c.dom.css.CSSStyleDeclaration |
getStyle()
|
int |
getWidth()
|
int |
getX()
|
int |
getY()
|
void |
removeActionListener(java.awt.event.ActionListener al)
|
void |
removeFocusListener(java.awt.event.FocusListener fl)
|
void |
removeHelpListener(java.awt.event.ActionListener fl)
remove a listener for help events |
void |
removeMouseListener(java.awt.event.MouseListener ml)
|
void |
setBackground(java.awt.Color bg)
set the background, if null, then reset to default |
void |
setBounds(int x,
int y,
int width,
int height)
Set the bounds of Container |
protected void |
setDefaultSize()
Called in the beginning to find out the default size (CSS+component) |
void |
setEnabled(boolean b)
|
void |
setFocus()
set the focus to this control |
void |
setFont(java.awt.Font f)
Sets the content components font |
void |
setForeground(java.awt.Color bg)
set the foreground |
void |
setHintText(java.lang.String text)
set the hint text |
void |
setInputMode(java.lang.String inputmode)
set the input mode attribute (from XForms) |
void |
setStyle(org.w3c.dom.css.CSSStyleDeclaration a_style)
Apply a style to the component. |
void |
setVisible(boolean v)
Set this drawing area visible. |
void |
setZoom(double zoom)
Set's this components zoom (1.0 is the default). |
protected void |
sizeComponent(double zoom)
|
void |
sizeComponent(double zoom,
java.awt.Dimension size)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected org.w3c.dom.css.CSSStyleDeclaration style
protected static final java.awt.Dimension minSize
protected double currentZoom
protected java.awt.Font currentFont
protected java.awt.Font defaultFont
protected java.awt.Dimension defaultSize
protected java.awt.Color defaultBGColor
protected java.lang.String hintText
public java.awt.Component content
protected java.lang.String fInputMode
| Constructor Detail |
public ComponentBase()
| Method Detail |
public void setVisible(boolean v)
v - true=visible, false=invisiblepublic void setFont(java.awt.Font f)
public void setInputMode(java.lang.String inputmode)
public boolean getEnabled()
public void setEnabled(boolean b)
b - Active or not activepublic org.w3c.dom.css.CSSStyleDeclaration getStyle()
public java.awt.Component getAddableComponent()
public java.awt.Component getSizableComponent()
public java.awt.Component getStylableComponent()
public java.awt.Component getComponent()
public java.awt.Color getDefaultBackgroundColor()
public void setBackground(java.awt.Color bg)
public void setForeground(java.awt.Color bg)
public void setBounds(int x,
int y,
int width,
int height)
x - X locationy - X locationwidth - X locationheight - X locationpublic java.awt.Dimension getDefaultSize()
public int getX()
public int getY()
public int getWidth()
public int getHeight()
public java.awt.Dimension getSize()
public java.awt.Dimension getMinimumSize()
public void addActionListener(java.awt.event.ActionListener al)
public void removeActionListener(java.awt.event.ActionListener al)
public void addFocusListener(java.awt.event.FocusListener fl)
public void removeFocusListener(java.awt.event.FocusListener fl)
public void addMouseListener(java.awt.event.MouseListener ml)
public void removeMouseListener(java.awt.event.MouseListener ml)
public void setFocus()
public void setHintText(java.lang.String text)
public void setZoom(double zoom)
protected void sizeComponent(double zoom)
public void sizeComponent(double zoom,
java.awt.Dimension size)
public void setStyle(org.w3c.dom.css.CSSStyleDeclaration a_style)
protected void setDefaultSize()
public java.awt.Dimension getPreferredSize(java.awt.Component comp)
public CSSFormatter getFormatter()
public void addHelpListener(java.awt.event.ActionListener fl)
public void removeHelpListener(java.awt.event.ActionListener fl)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||