public class VButton extends VAbstractButton
VButton class implements the visual button that
acts as a button model. The button creates different visual presentations
according to the style and the state.AbstractButton,
Button,
ToggleButton,
直列化された形式| 修飾子とタイプ | フィールドと説明 |
|---|---|
protected V3DButtonBorder |
border
The border of the button.
|
protected java.awt.Insets |
insets
The insets of the button.
|
static int |
TOGGLE
The button style constat for the toggle style.
|
static int |
TRIGGER
The button style constat for the trigger style.
|
statedisabledBackground, disabledForeground, disabledLabel1, disabledLabel2, enabled, focused, focusedBordervisualizable| 修飾子 | コンストラクタと説明 |
|---|---|
|
VButton()
Constructs a trigger button with the
false state. |
|
VButton(boolean state)
Constructs a trigger button with the specified state.
|
|
VButton(boolean state,
int style)
Constructs a button with the specified state and the specified style.
|
|
VButton(int style)
Constructs a button with the
false state,
and the specified style. |
|
VButton(java.lang.String str)
Constructs a trigger button with the
false state,
and the specified string. |
|
VButton(java.lang.String str,
boolean state)
Constructs a trigger button with the specified string and the
specified state.
|
|
VButton(java.lang.String str,
boolean state,
int style)
Constructs a button with the specified string, the specified state,
and the specified style.
|
|
VButton(java.lang.String str,
int style)
Constructs a button with the
false state,
the specified string, and the specified style. |
|
VButton(Text text)
Constructs a trigger button with the
false state,
and the specified text. |
|
VButton(Text text,
boolean state)
Constructs a trigger button with the specified text and the
specified state.
|
|
VButton(Text text,
boolean state,
int style)
Constructs a button with the specified text, the specified state,
and the specified style.
|
|
VButton(Text text,
int style)
Constructs a button with the
false state,
the specified text, and the specified style. |
|
VButton(Visualizable visualizable)
Constructs a trigger button with the
false state,
and the specified visual object. |
|
VButton(Visualizable visualizable,
boolean state)
Constructs a trigger button with the specified visual object
and the specified state.
|
protected |
VButton(Visualizable visualizable,
boolean enabled,
boolean focused,
boolean state,
int style)
Constructs a button with the specified visual object,
states, and style.
|
protected |
VButton(Visualizable visualizable,
boolean enabled,
boolean focused,
boolean state,
int style,
V3DButtonBorder border)
Constructs a button with the specified visual object,
states, style, and border.
|
|
VButton(Visualizable visualizable,
boolean state,
int style)
Constructs a button with the specified visual object,
the specified state, and the specified style.
|
|
VButton(Visualizable visualizable,
int style)
Constructs a button with the
false state,
the specified visual object, and the specified style. |
| 修飾子とタイプ | メソッドと説明 |
|---|---|
java.lang.Object |
clone()
Returns a clone of this button.
|
VLabel |
deriveLabel(Visualizable visualizable)
Creates a new button by replicating this button with a new visual
object associated with it.
|
java.awt.Insets |
getInsets()
Returns the insets of this button.
|
java.awt.Dimension |
getSize()
Returns the size of this button.
|
int |
getStyle()
Returns the style of the button.
|
void |
paint(java.awt.Graphics g,
java.awt.Point p,
java.awt.Component comp)
Paints the button at the specified location with the component.
|
protected void |
paintBorder(java.awt.Graphics g,
int x,
int y,
int width,
int height)
Paints the border of the button with the specified dimension
at the specified location.
|
void |
setInsets(java.awt.Insets insets)
Sets the insets of this button to be the specified insets.
|
void |
setSize(java.awt.Dimension d)
Resizes the button to the specified dimension.
|
void |
setState(boolean b)
Sets the button to the specifed boolean state.
|
void |
setStyle(int style)
Sets the style of the button to the specified style.
|
canActivate, getState, isActive, setActiveclearDisabledVisualizable, getDisabledBackground, getDisabledForeground, getFocusedSize, isEnabled, isFocused, makeDisabledLabel, paint, paint, paintDisabled, paintDisabled, paintEnabled, paintFocused, setDisabledBackground, setDisabledForeground, setEnabled, setFocused, setFocusedSize, setVisualizablegetVisualizable, isResizableprotected V3DButtonBorder border
protected java.awt.Insets insets
public static final int TRIGGER
public static final int TOGGLE
public VButton()
false state.public VButton(boolean state)
state - the state of the button.public VButton(int style)
false state,
and the specified style.style - the style of teh button.public VButton(boolean state,
int style)
state - the state of teh button.style - the style of teh button.public VButton(java.lang.String str)
false state,
and the specified string.str - the string.public VButton(java.lang.String str,
boolean state)
str - the string.state - the state of the button.public VButton(java.lang.String str,
int style)
false state,
the specified string, and the specified style.str - the string.style - the style of the button.public VButton(java.lang.String str,
boolean state,
int style)
str - the string.state - the state of teh button.style - the style of teh button.public VButton(Text text)
false state,
and the specified text.text - the text.public VButton(Text text, boolean state)
text - the text.state - the state of the button.public VButton(Text text, int style)
false state,
the specified text, and the specified style.text - the text.style - the style of the button.public VButton(Text text, boolean state, int style)
text - the text.state - the state of teh button.style - the style of teh button.public VButton(Visualizable visualizable)
false state,
and the specified visual object.visualizable - the visual object.public VButton(Visualizable visualizable, boolean state)
visualizable - the visual object.state - the state of the button.public VButton(Visualizable visualizable, int style)
false state,
the specified visual object, and the specified style.visualizable - the visual object.style - the style of the button.public VButton(Visualizable visualizable, boolean state, int style)
visualizable - the visual object.state - the state of teh button.style - the style of teh button.protected VButton(Visualizable visualizable, boolean enabled, boolean focused, boolean state, int style)
visualizable - the visual object.enabled - the enabled state of teh button.focused - the focused state of teh button.state - the state of teh button.style - the style of teh button.protected VButton(Visualizable visualizable, boolean enabled, boolean focused, boolean state, int style, V3DButtonBorder border)
visualizable - the visual object.enabled - the enabled state of teh button.focused - the focused state of teh button.state - the state of teh button.style - the style of teh button.border - the border of teh button.public VLabel deriveLabel(Visualizable visualizable)
deriveLabel クラス内 VLabelvisualizable - the visual object for the new button.public int getStyle()
public void setStyle(int style)
public void setState(boolean b)
setState クラス内 VAbstractButtonb - the boolean state.VAbstractButton.setState(boolean)public java.awt.Insets getInsets()
public void setInsets(java.awt.Insets insets)
insets - the insets.public java.awt.Dimension getSize()
getSize インタフェース内 VisualizablegetSize クラス内 VLabelVisualizable.getSize()public void setSize(java.awt.Dimension d)
setSize インタフェース内 VisualizablesetSize クラス内 VLabeld - the visual object dimension.Visualizable.setSize(java.awt.Dimension)public void paint(java.awt.Graphics g,
java.awt.Point p,
java.awt.Component comp)
public java.lang.Object clone()
clone インタフェース内 Visualizableclone クラス内 VAbstractButtonprotected void paintBorder(java.awt.Graphics g,
int x,
int y,
int width,
int height)