|
java-gnome version 4.0.19 | ||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Objectorg.freedesktop.bindings.Pointer
org.freedesktop.bindings.Proxy
org.gnome.glib.Object
org.gnome.gtk.Action
org.gnome.gtk.ToggleAction
public class ToggleAction
A ToggleAction
is an equivalent of a Action
but used
in general to create CheckMenuItem
. It has an "active"
state which indicates whether the action has been checked or not.
Nested Class Summary | |
---|---|
static interface |
ToggleAction.Toggled
Signal emitted when the ToggleAction is toggled
A ToggleAction is activated when the user clicks a
ToolButton proxy, when (s)he activates an associated MenuItem or when
toggled() is called. |
Nested classes/interfaces inherited from class org.gnome.gtk.Action |
---|
Action.Activate |
Constructor Summary | |
---|---|
ToggleAction(String name,
Stock stock)
Create a new ToggleAction from a Stock item. |
|
ToggleAction(String name,
Stock stock,
ToggleAction.Toggled handler)
Create a new ToggleAction based on a Stock item, and connect a handler to its ToggleAction.Toggled signal. |
|
ToggleAction(String name,
String label)
Create a new ToggleAction. |
|
ToggleAction(String name,
String label,
String tooltip,
Stock stock)
Create a new ToggleAction. |
|
ToggleAction(String name,
String label,
String tooltip,
Stock stock,
ToggleAction.Toggled handler)
Create a new ToggleAction, and connect a handler to its ToggleAction.Toggled signal. |
|
ToggleAction(String name,
String label,
ToggleAction.Toggled handler)
Create a new ToggleAction, and connect a handler to its ToggleAction.Toggled signal. |
Method Summary | |
---|---|
void |
connect(ToggleAction.Toggled handler)
Connect a handler to the ToggleAction.Toggled signal. |
void |
emitToggled()
Emit the ToggleAction.Toggled signal. |
boolean |
getActive()
Return the checked state of the ToggleAction . |
boolean |
getDrawAsRadio()
Return whether the action may have proxies like a RadioAction . |
void |
setActive(boolean setting)
Set the checked state of the ToggleAction . |
void |
setDrawAsRadio(boolean setting)
Set whether the action may have proxies like a RadioAction . |
Methods inherited from class org.gnome.gtk.Action |
---|
connect, createMenuItem, createToolItem, emitActivate, getSensitive, getTooltip, getVisible, isSensitive, isVisible, setAccelerator, setSensitive, setTooltip, setVisible |
Methods inherited from class org.freedesktop.bindings.Pointer |
---|
toString |
Methods inherited from class Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ToggleAction(String name, Stock stock)
public ToggleAction(String name, Stock stock, ToggleAction.Toggled handler)
ToggleAction.Toggled
signal. Complements the
<init>(String, Stock)
constructor.
public ToggleAction(String name, String label)
name
- A unique name for the ToggleAction.label
- The text that will be displayed in the proxy Widgets. You
usually will want to localize it to the user language.public ToggleAction(String name, String label, String tooltip, Stock stock)
name
- A unique name for the ToggleAction.label
- The text that will be displayed in the proxy Widgets. You
usually will want to localize it to the user language.tooltip
- A Tooltip or little help message for the ToggleAction. Also
localized.stock
- The Stock icon to display in proxy Widgets.public ToggleAction(String name, String label, String tooltip, Stock stock, ToggleAction.Toggled handler)
ToggleAction.Toggled
signal.
name
- A unique name for the ToggleAction.label
- The text that will be displayed in the proxy Widgets. You
usually will want to localize it to the user language.tooltip
- A Tooltip or little help message for the ToggleAction. Also
localized.stock
- The stock icon to display in proxy Widgets.handler
- A handler to connect to the
ToggleAction.Toggled
signal. Typically this
will be used to actually start the operation related to this
ToggleAction.public ToggleAction(String name, String label, ToggleAction.Toggled handler)
ToggleAction.Toggled
signal.
name
- A unique name for the ToggleAction.label
- The label that will be displayed in the proxy Widgets. You
usually will want to localize it to the user language.handler
- A handler to connect to the
ToggleAction.Toggled
signal. Usually will will
start from here the operation related to the Action.Method Detail |
---|
public void connect(ToggleAction.Toggled handler)
ToggleAction.Toggled
signal.
public void emitToggled()
ToggleAction.Toggled
signal.
public boolean getActive()
ToggleAction
.
public boolean getDrawAsRadio()
RadioAction
.
public void setActive(boolean setting)
ToggleAction
.
public void setDrawAsRadio(boolean setting)
RadioAction
.
|
![]() java-gnome |
||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |