multivalent.std

Class SpeedRead

public class SpeedRead extends Behavior

Starting at cursor/selection, flash words up at some rate, after and superior to Vortex. Not sure if this is a good way to do it, but it only took two hours to implement, and makes a great example of Multivalent's advantages over that applet: don't need three copies of text, can start at any point in document, works on any page vs ones prepared with applet.

Version: $Revision: 1.4 $ $Date: 2002/02/01 03:01:42 $

Field Summary
static StringATTR_DELAY
static StringMSG_DELAY
Sets the delay between words, in milliseconds.
static StringMSG_FASTER
Show words faster by decreasing the delay.
static StringMSG_PAUSE
Another semantic command, which should be given more descriptive name.
static StringMSG_SLOWER
Another semantic command, which should be given more descriptive name.
Method Summary
voiddestroy()
booleaneventAfter(AWTEvent e, Point rel, Node n)
Arrow keys adjust speed (actually delay).
booleaneventBefore(AWTEvent e, Point rel, Node n)
Click in content area to pause.
booleanpaintAfter(Context cx, Node node)
Draw in frame, rather than change content node, format, paint cycle -- probably wrong choice as doesn't compose.
booleanpaintBefore(Context cx, Node node)
voidrestore(ESISNode n, Map<String,Object> attr, Layer layer)
Create VFrame.
booleansemanticEventAfter(SemanticEvent se, String msg)
Take action: windowClosed, pause, faster, ....
booleansemanticEventBefore(SemanticEvent se, String msg)
Entries in frame popup: pause, faster, slower, ....

Field Detail

ATTR_DELAY

public static final String ATTR_DELAY

MSG_DELAY

public static final String MSG_DELAY
Sets the delay between words, in milliseconds.

"speedreadDelay": arg= java.lang.Number delay.

MSG_FASTER

public static final String MSG_FASTER
Show words faster by decreasing the delay.

"speedreadFaster".

MSG_PAUSE

public static final String MSG_PAUSE
Another semantic command, which should be given more descriptive name.

"togglePause".

MSG_SLOWER

public static final String MSG_SLOWER
Another semantic command, which should be given more descriptive name.

"speedreadSlower".

Method Detail

destroy

public void destroy()

eventAfter

public boolean eventAfter(AWTEvent e, Point rel, Node n)
Arrow keys adjust speed (actually delay).

eventBefore

public boolean eventBefore(AWTEvent e, Point rel, Node n)
Click in content area to pause.

paintAfter

public boolean paintAfter(Context cx, Node node)
Draw in frame, rather than change content node, format, paint cycle -- probably wrong choice as doesn't compose.

paintBefore

public boolean paintBefore(Context cx, Node node)

restore

public void restore(ESISNode n, Map<String,Object> attr, Layer layer)
Create VFrame.

semanticEventAfter

public boolean semanticEventAfter(SemanticEvent se, String msg)
Take action: windowClosed, pause, faster, ....

semanticEventBefore

public boolean semanticEventBefore(SemanticEvent se, String msg)
Entries in frame popup: pause, faster, slower, ....