|
LEONARDI Application Composer - 8.9.0.40 by W4 S.A. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectleon.view.win.swing.component.LyAbstractBooleanPanelManager
public abstract class LyAbstractBooleanPanelManager
This component handles a checkbox with two or three states.
When optional, the mode is three states: BOOLEAN_CHECKED
, BOOLEAN_UNCHECKED
and BOOLEAN_EMPTY
.
When not optional, there is only two states: CHECKED and UNCHECKED
Field Summary | |
---|---|
static java.lang.String |
__VERSION
|
static int |
BOOLEAN_CHECKED
Checked status. |
static int |
BOOLEAN_EMPTY
Empty status. |
static int |
BOOLEAN_UNCHECKED
Unchecked status. |
Constructor Summary | |
---|---|
LyAbstractBooleanPanelManager(java.awt.Component comp)
Class constructor of a boolean panel manager. |
Method Summary | |
---|---|
void |
addActionListener(java.awt.event.ActionListener listener)
Registers a new listener on this component. |
java.awt.Component |
getComponent()
Gets the component linked to this manager. |
abstract java.awt.Image |
getImageOffScreen(java.awt.Dimension offScreenSize)
Returns the offscreen image if any. |
java.awt.Dimension |
getPreferredSize()
The size of this component. |
abstract java.awt.Graphics |
getTargetGraphics(java.awt.Image offScreenImage,
java.awt.Graphics defaultGraphics)
Returns the graphics context of the specified offscreen image or the default graphics context if none is available. |
java.lang.Boolean |
getValue()
Returns the status of the component. |
boolean |
isEnabled()
Returns the enabled status of this component. |
boolean |
isOptional()
Returns the optional status of the component. |
void |
nextStatus()
Cycles through the different status of this component. |
void |
paintCommon(java.awt.Graphics g)
Draws the title panel in this graphics. |
abstract void |
paintOnScreen(java.awt.Image offScreenImage,
java.awt.Graphics onScreenGraphics)
Paints the specified offscreen image to the onscreen graphics context. |
void |
redraw()
Redraws the component. |
void |
removeActionListener(java.awt.event.ActionListener listener)
Removes a previously registered listener on this component. |
void |
setEnabled(boolean enabled)
Enables this component. |
void |
setImages(java.awt.Image background,
java.awt.Image hoover,
java.awt.Image selectEmpty,
java.awt.Image selectFalse,
java.awt.Image selectTrue)
Sets the images for this component. |
void |
setLabels(java.lang.String emptyLabel,
java.lang.String checkedLabel,
java.lang.String uncheckedLabel)
Sets the labels of this component. |
void |
setOptional(boolean optional)
Sets the optional parameter of this component. |
void |
setValue(java.lang.Boolean status)
Sets the current status of the component and redraws it. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String __VERSION
public static final int BOOLEAN_EMPTY
public static final int BOOLEAN_CHECKED
public static final int BOOLEAN_UNCHECKED
Constructor Detail |
---|
public LyAbstractBooleanPanelManager(java.awt.Component comp)
comp
- the panel component that is initializedMethod Detail |
---|
public void setImages(java.awt.Image background, java.awt.Image hoover, java.awt.Image selectEmpty, java.awt.Image selectFalse, java.awt.Image selectTrue)
background
- the background image of this componenthoover
- the hoover image used for this componentselectEmpty
- the image used when BOOLEAN_EMPTY status is selectedselectFalse
- the image used when BOOLEAN_FALSE status is selectedselectTrue
- the image used when BOOLEAN_TRUE status is selectedpublic void setLabels(java.lang.String emptyLabel, java.lang.String checkedLabel, java.lang.String uncheckedLabel)
emptyLabel
- label displayed when the selection is emptycheckedLabel
- label displayed when the selection is checkeduncheckedLabel
- label displayed when the selection is uncheckedsetLabels(String, String, String)
public void redraw()
public java.lang.Boolean getValue()
setValue(Boolean)
public void setValue(java.lang.Boolean status)
status
- the new statusgetValue()
public boolean isEnabled()
public boolean isOptional()
public void setEnabled(boolean enabled)
enabled
- true to enable this componentpublic void setOptional(boolean optional)
optional
- the optional status of the componentpublic java.awt.Dimension getPreferredSize()
null
null
_selectEmpty
, _selectChecked
and _selectUnchecked
, if the background and hoover image are
null
public void addActionListener(java.awt.event.ActionListener listener)
listener
- a new listenerremoveActionListener(ActionListener)
public void removeActionListener(java.awt.event.ActionListener listener)
listener
- the listener to removeaddActionListener(ActionListener)
public void nextStatus()
public java.awt.Component getComponent()
public abstract java.awt.Image getImageOffScreen(java.awt.Dimension offScreenSize)
offScreenSize
- size of the offscreen image
public abstract java.awt.Graphics getTargetGraphics(java.awt.Image offScreenImage, java.awt.Graphics defaultGraphics)
offScreenImage
- the image to get its graphics contextdefaultGraphics
- the default graphics context if the image doesn't have one
public abstract void paintOnScreen(java.awt.Image offScreenImage, java.awt.Graphics onScreenGraphics)
offScreenImage
- the offscreen image to paint on the onscreen contextonScreenGraphics
- the graphics context to paint the offscreen image onpublic void paintCommon(java.awt.Graphics g)
g
- the graphics context to paint the images on
|
(c) January 2013 - W4 S.A. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |