|
Multivalent API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmultivalent.VObject
multivalent.Behavior
multivalent.std.lens.Lens
VWindows that transform their content and compose with one another. Lenses are tools, such as a magnifying glass or show OCR content, that are associated with the window as a whole (specifically, with the Root), as opposed to individual Documents. Unlike other VWindows, Lenses are coordinated by a Lens Manager, which composes their effects. During paintBefore, as lenses implement ContextListener, they can add themselves to a Context's list of omnipresent in order to modify in all Documents within its bounds. To put lens creation in UI, add a reference to WindowUI in hub. Can write a lens with opaque content, but then it's not really a lens, which transforms their content, so use a VWindow or Note.
Xerox PARC Magic Lenses reference
LensMan
,
Context
,
ContextListener
,
WindowUI
Field Summary | |
---|---|
static java.lang.String |
ATTR_HEIGHT
|
static java.lang.String |
ATTR_TITLE
|
static java.lang.String |
ATTR_WIDTH
|
static java.lang.String |
ATTR_X
|
static java.lang.String |
ATTR_Y
|
static java.lang.String |
VAR_SHARED_LAYER
|
protected VFrame |
win_
|
Fields inherited from class multivalent.Behavior |
---|
ATTR_BEHAVIOR, name_ |
Fields inherited from class multivalent.VObject |
---|
attr_ |
Fields inherited from interface multivalent.ContextListener |
---|
LITTLE, LOT, PRIORITY_LENS, PRIORITY_MAX, PRIORITY_MIN, PRIORITY_SELECTION, PRIORITY_SPAN, PRIORITY_STRUCT, SOME |
Constructor Summary | |
---|---|
Lens()
|
Method Summary | |
---|---|
boolean |
appearance(Context cx,
boolean all)
Effect: Context attributes and signals. |
void |
close()
Removes from LensMan. |
void |
destroy()
Protocol. |
java.awt.Rectangle |
getContentBounds()
Bounds of corresponding VFrame's content area, exclusive of title bar. |
protected LensMan |
getLensMan()
Return lens manager behavior that coordinates lens intersections. |
int |
getPriority()
final because lens priority given by window stacking order. |
boolean |
paintAfter(Context cx,
Node node)
Effect: arbitrary drawing on top. |
boolean |
paintBefore(Context cx,
Node node)
Effect: Graphics2D transformation matrix. |
void |
restore(ESISNode n,
java.util.Map<java.lang.String,java.lang.Object> attr,
Layer layer)
Creates corresponding VFrame, and sets title and bounds, which are available for subclasses to tweak, |
ESISNode |
save()
Build up save data as ESIS tree, then write that out. |
boolean |
semanticEventAfter(SemanticEvent se,
java.lang.String msg)
Catch corresponding VFrame's windowClosed, windowRaised, .... |
void |
show()
Adds to LensMan. |
Methods inherited from class multivalent.Behavior |
---|
buildAfter, buildBefore, checkRep, clipboardAfter, clipboardBefore, createUI, eventAfter, eventBefore, formatAfter, formatBefore, getBrowser, getDocument, getInstance, getInstance, getLayer, getLogger, getName, getPreference, getRoot, isEditable, putPreference, redo, restoreChildren, semanticEventBefore, setName, toString, undo |
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 |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String ATTR_X
public static final java.lang.String ATTR_Y
public static final java.lang.String ATTR_WIDTH
public static final java.lang.String ATTR_HEIGHT
public static final java.lang.String ATTR_TITLE
public static final java.lang.String VAR_SHARED_LAYER
protected VFrame win_
Constructor Detail |
---|
public Lens()
Method Detail |
---|
public java.awt.Rectangle getContentBounds()
protected LensMan getLensMan()
LensMan
public final int getPriority()
getPriority
in interface ContextListener
public boolean appearance(Context cx, boolean all)
appearance
in interface ContextListener
all
- all attributes or exclude those that are not inherited
ContextListener
,
SignalLens
public boolean paintBefore(Context cx, Node node)
paintBefore
in class Behavior
Magnify
public boolean paintAfter(Context cx, Node node)
paintAfter
in class Behavior
Ruler
,
Bounds
,
Cypher
public boolean semanticEventAfter(SemanticEvent se, java.lang.String msg)
semanticEventAfter
in class Behavior
public ESISNode save()
Behavior
super.save()
.
Always have Behavior.ATTR_BEHAVIOR
from save (short) classname.
save
in class Behavior
public void restore(ESISNode n, java.util.Map<java.lang.String,java.lang.Object> attr, Layer layer)
restore
in class Behavior
public void destroy()
Behavior
destroy
in class Behavior
public void close()
public void show()
|
Multivalent API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |