|
Multivalent API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmultivalent.VObject
multivalent.Node
multivalent.Leaf
multivalent.gui.VScrollbar
Scrollbars, both vertical and horizontal. Communication is done with logical values, as opposed to visual or display coordinates. Unless otherwise noted, method parameters and return values that are geometric are relative to the source being scrolled, not the internal scrollbar display. The scrollbar visually indicates the amount of the document displayed.
IScrollPane
Field Summary | |
---|---|
static int |
BOTTOMARROW
Logical parts of scrollbar reported by idLocation(Point) . |
static int |
BOTTOMTROUGH
Logical parts of scrollbar reported by idLocation(Point) . |
static int |
HORIZONTAL
Scrollbar orientation to pass in constructor. |
static int |
NIB
Logical parts of scrollbar reported by idLocation(Point) . |
static int |
NOWHERE
Logical parts of scrollbar reported by idLocation(Point) . |
static byte |
SHOW_ALWAYS
Policy for showing scrollbar. |
static byte |
SHOW_AS_NEEDED
Policy for showing scrollbar. |
static byte |
SHOW_NEVER
Policy for showing scrollbar. |
static int |
SIZE
Width of scrollbar (height if horizontal). |
static int |
TOPARROW
Logical parts of scrollbar reported by idLocation(Point) . |
static int |
TOPTROUGH
Logical parts of scrollbar reported by idLocation(Point) . |
static int |
VERTICAL
Scrollbar orientation to pass in constructor. |
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 | |
---|---|
VScrollbar(int orientation)
|
|
VScrollbar(java.lang.String name,
java.util.Map<java.lang.String,java.lang.Object> attr,
INode parent,
int orientation)
|
Method Summary | |
---|---|
void |
event(java.awt.AWTEvent e)
|
boolean |
eventNode(java.awt.AWTEvent e,
java.awt.Point rel)
unless overridden, leaves see if owner is interested |
boolean |
formatNode(int width,
int height,
Context cx)
Handles span transitions on node and elided portions. |
int |
getBlockIncrement()
|
int |
getLineIncrement()
|
int |
getMax()
|
int |
getMin()
|
byte |
getShowPolicy()
|
int |
getValue()
|
int |
idLocation(java.awt.Point rel)
Figure out what scrollbar part lies under the passed point, such as TOPARROW . |
boolean |
paintNodeContent(Context cx,
int start,
int end)
Subclass for different scrollbar appearances. |
void |
setMinMax(int minimum,
int maximum)
Set min and max values of source. |
void |
setShowPolicy(byte policy)
|
void |
setValue(int value)
Same as setValue(value, false) . |
void |
setValue(int value,
boolean pickplace)
Value is in source coordinates. |
Methods inherited from class multivalent.Leaf |
---|
append, checkRep, clipboardBeforeAfter, clipboardNode, copy, cut, delete, dx, dy, eatme, eventBeforeAfter, formatBeforeAfter, formatNodeContent, getFirstLeaf, getLastLeaf, insert, insert, isLeaf, lengthTo, markDirtySubtreeDown, offset2rel, paintBeforeAfter, paintNode, paste, paste, removeTidy, setName, split, subelement, subelementCalc, subelementHit |
Methods inherited from class multivalent.Node |
---|
addObserver, addSticky, addSticky, breakAfter, breakBefore, childNum, clipboardBeforeAfter, clone, cmp, commonAncestor, commonAncestor, contains, contains, deleteObserver, dump, dump, dump, findBFS, findBFS, findBFS, findDFS, findDFS, findDFS, findDFS, getAbsLocation, getActivesAt, getActivesAt, getActivesAt, getBbox, getBrowser, getDocument, getElementById, getIScrollPane, getName, getNextLeaf, getNextNode, getNodeName, getObservers, getParentNode, getPrevLeaf, getPrevNode, getRelLocation, getRoot, getSticky, indexSticky, intersects, isStruct, isValid, markDirty, markDirtySubtree, markDirtyTo, morphInto, reformat, remove, removeSticky, removeSticky, repaint, repaint, repaint, repaint, scrollTo, scrollTo, setParentNode, setValid, size, 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 |
Field Detail |
---|
public static final byte SHOW_NEVER
public static final byte SHOW_AS_NEEDED
public static final byte SHOW_ALWAYS
public static final int VERTICAL
public static final int HORIZONTAL
public static final int NOWHERE
idLocation(Point)
.
public static final int TOPARROW
idLocation(Point)
.
public static final int TOPTROUGH
idLocation(Point)
.
public static final int NIB
idLocation(Point)
.
public static final int BOTTOMTROUGH
idLocation(Point)
.
public static final int BOTTOMARROW
idLocation(Point)
.
public static int SIZE
Constructor Detail |
---|
public VScrollbar(int orientation)
public VScrollbar(java.lang.String name, java.util.Map<java.lang.String,java.lang.Object> attr, INode parent, int orientation)
Method Detail |
---|
public void setMinMax(int minimum, int maximum)
public int getMin()
public int getMax()
public int getValue()
public void setShowPolicy(byte policy)
public byte getShowPolicy()
public void setValue(int value, boolean pickplace)
pickplace
- Smart scrolling, after Tk's text widget -pickplace option:
If the location is already shown, do nothing;
if it's a little way off the screen (top or bottom), scroll just enough to bring it into view;
if it's far away, show it centered.public void setValue(int value)
setValue(value, false)
.
public int getBlockIncrement()
public int getLineIncrement()
public boolean formatNode(int width, int height, Context cx)
Leaf
formatNode
in class Leaf
public boolean paintNodeContent(Context cx, int start, int end)
paintNodeContent
in class Leaf
public boolean eventNode(java.awt.AWTEvent e, java.awt.Point rel)
Leaf
eventNode
in class Leaf
TreeEvent
,
SemanticEvent
public void event(java.awt.AWTEvent e)
event
in interface EventListener
public int idLocation(java.awt.Point rel)
TOPARROW
.
|
Multivalent API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |