Multivalent API

multivalent.gui
Class VCheckbox

java.lang.Object
  extended by multivalent.VObject
      extended by multivalent.Node
          extended by multivalent.INode
              extended by multivalent.node.IParaBox
                  extended by multivalent.gui.VButton
                      extended by multivalent.gui.VCheckbox
All Implemented Interfaces:
java.lang.Cloneable, EventListener, java.util.EventListener

public class VCheckbox
extends VButton

Checkbox widget: toggle ON and OFF. Usable as button and menu item.

Version:
$Revision: 1.5 $ $Date: 2002/01/27 02:00:01 $

Field Summary
 
Fields inherited from class multivalent.INode
border, INSETS, INSETS_ZERO, margin, padding
 
Fields inherited from class multivalent.Node
align, ALIGN_INVALID, ATTR_ID, ATTR_SCRIPT, baseline, BASELINE, bbox, BOTH, BOTTOM, CENTER, CHAR, FILL, floats, INHERIT, JUSTIFY, LEFT, MAXNONSTRUCTDEPTH, MIDDLE, name_, NONE, observers_, parent_, PROBEWIDTH, RIGHT, sticky_, stickycnt_, TOP, valid_, valign
 
Fields inherited from class multivalent.VObject
attr_
 
Constructor Summary
VCheckbox(java.lang.String name, java.util.Map<java.lang.String,java.lang.Object> attr, INode parent)
           
 
Method Summary
 boolean formatNode(int width, int height, Context cx)
          Ensure that padding on left is large enough for checkbox.
 boolean getState()
           
 void invoke()
          Change state, then call associated VScript, if any.
 void paintNode(java.awt.Rectangle docclip, Context cx)
          Draw checkbox too.
 void setState(boolean b)
           
 
Methods inherited from class multivalent.gui.VButton
breakAfter, breakBefore, dx, dy, event, eventNode
 
Methods inherited from class multivalent.node.IParaBox
reformat
 
Methods inherited from class multivalent.INode
addCategory, appendChild, checkRep, childAt, childNum, clipboardNode, clone, contains, dump, eventBeforeAfter, findDFS, formatBeforeAfter, getElementById, getFirstChild, getFirstLeaf, getLastChild, getLastLeaf, getNextSibling, getPreviousSibling, insertChildAt, isStruct, markDirtySubtreeDown, paintBeforeAfter, removeAllChildren, removeChild, removeChildAt, setChildAt, setName, size, structChildAt, structChildNum, structsize
 
Methods inherited from class multivalent.Node
addObserver, addSticky, addSticky, childNum, clipboardBeforeAfter, cmp, commonAncestor, commonAncestor, contains, deleteObserver, dump, dump, findBFS, findBFS, findBFS, findDFS, findDFS, findDFS, getAbsLocation, getActivesAt, getActivesAt, getActivesAt, getBbox, getBrowser, getDocument, getIScrollPane, getName, getNextLeaf, getNextNode, getNodeName, getObservers, getParentNode, getPrevLeaf, getPrevNode, getRelLocation, getRoot, getSticky, indexSticky, intersects, isLeaf, isValid, markDirty, markDirtySubtree, markDirtyTo, morphInto, remove, removeSticky, removeSticky, removeTidy, repaint, repaint, repaint, repaint, scrollTo, scrollTo, setParentNode, setValid, sizeSticky, spanChunky, spanChunky, structChildNum, toString
 
Methods inherited from class multivalent.VObject
attrEntrySetIterator, attrKeysIterator, clearAttributes, getAttr, getAttr, getAttributes, getGlobal, getValue, hasAttributes, putAttr, removeAttr, setAttributes
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

VCheckbox

public VCheckbox(java.lang.String name,
                 java.util.Map<java.lang.String,java.lang.Object> attr,
                 INode parent)
Method Detail

getState

public boolean getState()

setState

public void setState(boolean b)

formatNode

public boolean formatNode(int width,
                          int height,
                          Context cx)
Ensure that padding on left is large enough for checkbox.

Overrides:
formatNode in class VButton
See Also:
FixedI

paintNode

public void paintNode(java.awt.Rectangle docclip,
                      Context cx)
Draw checkbox too.

Overrides:
paintNode in class VButton

invoke

public void invoke()
Change state, then call associated VScript, if any.

Overrides:
invoke in class VButton

Multivalent API