apwidgets
Class APToggleButton
java.lang.Object
apwidgets.APWidget
apwidgets.APTextView
apwidgets.APButton
apwidgets.APCompoundButton
apwidgets.APToggleButton
- All Implemented Interfaces:
- android.text.NoCopySpan, android.text.TextWatcher, android.view.View.OnClickListener
public class APToggleButton
- extends APCompoundButton
A Checkbox.Add instances to APWidgetContainer
.
- Author:
- Rikard Lundstedt
Nested classes/interfaces inherited from interface android.text.NoCopySpan |
android.text.NoCopySpan.Concrete |
Constructor Summary |
APToggleButton(int x,
int y,
int width,
int height,
java.lang.String text)
Creates a new toggle button. |
APToggleButton(int x,
int y,
java.lang.String text)
Creates a new toggle button. |
Method Summary |
java.lang.String |
getTextOff()
|
java.lang.String |
getTextOn()
|
void |
init(processing.core.PApplet argPApplet)
Initializes the toggle button. |
void |
setTextOff(java.lang.String textOff)
|
void |
setTextOn(java.lang.String textOn)
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
APToggleButton
public APToggleButton(int x,
int y,
java.lang.String text)
- Creates a new toggle button.
- Parameters:
x
- The x position of the check box.y
- The y position of the check box.text
- The text on the label of the check box.
APToggleButton
public APToggleButton(int x,
int y,
int width,
int height,
java.lang.String text)
- Creates a new toggle button.
- Parameters:
x
- The button's x position.y
- The button's y position.width
- The button's width.height
- The button's height.text
- The text on the button's label.
getTextOn
public java.lang.String getTextOn()
getTextOff
public java.lang.String getTextOff()
init
public void init(processing.core.PApplet argPApplet)
- Initializes the toggle button. Is called by
APWidgetContainer
as it is added to it.
- Overrides:
init
in class APCompoundButton
setTextOn
public void setTextOn(java.lang.String textOn)
setTextOff
public void setTextOff(java.lang.String textOff)