controlP5
Class CheckBox

java.lang.Object
  extended by controlP5.ControllerGroup
      extended by controlP5.ControlGroup
          extended by controlP5.RadioButton
              extended by controlP5.CheckBox
All Implemented Interfaces:
ControllerInterface, ControlListener

public class CheckBox
extends RadioButton

A checkBox is a multiple-choice radioButton. items are added to a checkBox and can be organized is rows and columns. items of a checkBox are of type Toggle.

Author:
andreas schlegel

Constructor Summary
CheckBox(ControlP5 theControlP5, ControllerGroup theParent, java.lang.String theName, int theX, int theY)
          a CheckBox should only be added to controlP5 by using controlP5.addCheckBox()
 
Method Summary
 void activate(int theIndex)
          activate an individual item of the checkox-item-list.
 void activate(java.lang.String theRadioButtonName)
           
 void activateAll()
          activate all checkBox items.
 void deactivate(int theIndex)
          deactivate a radio button.
 void deactivate(java.lang.String theRadioButtonName)
          deactivate a RadioButton and set the value of the radio controller to the default value (-1).
 void toggle(int theIndex)
           
 void toggle(java.lang.String theRadioButtonName)
           
 
Methods inherited from class controlP5.RadioButton
addItem, addItem, controlEvent, deactivateAll, getItem, getState, getState, removeItem, setItemHeight, setItemsPerRow, setItemWidth, setSpacingColumn, setSpacingRow, updateLayout
 
Methods inherited from class controlP5.ControlGroup
activateEvent, addCloseButton, addToXMLElement, arrayValue, getBackgroundHeight, hideBar, isBarVisible, mousePressed, removeCloseButton, setBackgroundColor, setBackgroundHeight, setBarHeight, showBar, stringValue, value
 
Methods inherited from class controlP5.ControllerGroup
absolutePosition, add, addCanvas, addDrawable, captionLabel, close, color, continuousUpdateEvents, controller, draw, getAsXML, getColor, getTab, getWindow, hide, id, init, isMoveable, isOpen, isUpdate, isVisible, isXMLsavable, keyEvent, moveTo, moveTo, moveTo, moveTo, moveTo, moveTo, moveTo, name, open, position, remove, remove, remove, removeCanvas, setColorActive, setColorBackground, setColorForeground, setColorLabel, setColorValue, setGroup, setGroup, setId, setLabel, setMousePressed, setMoveable, setOpen, setPosition, setTab, setTab, setTab, setUpdate, setVisible, show, update, updateAbsolutePosition, updateEvents, updateInternalEvents, valueLabel
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CheckBox

public CheckBox(ControlP5 theControlP5,
                ControllerGroup theParent,
                java.lang.String theName,
                int theX,
                int theY)
a CheckBox should only be added to controlP5 by using controlP5.addCheckBox()

Parameters:
theControlP5 -
theParent -
theName -
theX -
theY -
Method Detail

activateAll

public final void activateAll()
activate all checkBox items.


activate

public final void activate(int theIndex)
activate an individual item of the checkox-item-list.

Overrides:
activate in class RadioButton

deactivate

public final void deactivate(int theIndex)
Description copied from class: RadioButton
deactivate a radio button. the radio button must be active before deactivating to trigger an event.

Overrides:
deactivate in class RadioButton

toggle

public final void toggle(int theIndex)
Overrides:
toggle in class RadioButton

toggle

public final void toggle(java.lang.String theRadioButtonName)

activate

public final void activate(java.lang.String theRadioButtonName)
Overrides:
activate in class RadioButton

deactivate

public final void deactivate(java.lang.String theRadioButtonName)
Description copied from class: RadioButton
deactivate a RadioButton and set the value of the radio controller to the default value (-1).

Overrides:
deactivate in class RadioButton


processing library controlP5 by Andreas Schlegel. (c) 2010