setting the default folder to the folder where the stack is..

Ken Norris pixelbird at interisland.net
Thu Dec 20 00:43:01 EST 2001


Hi John,

I am waiting on the key to begin to learn Rev. I have been in HC for a while
this year, though. If Rev has similar functions, I would investigate:

selectedChunk
clickChunk
foundChunk

Best regards,
Ken N.

----------

on 12/16/01 2:48 PM, John at johng at cablespeed.com wrote:

> 
> Hope someone can help.  I have an application that needs to look the
> text the user is typing and editing in real time.  For each keystroke I
> need to work out what the current word is.  This is complicated a bit by
> the fact that the user is free to edit text anywhere in the field -
> simply capturing keystrokes and building the word as they type will not
> work because they could have begun editing a word in previously typed
> text.  The following example solves the problem but is very, very slow
> (to the point of making it unusable).
> 
> on keyDown
> global keyDownPoint
> put the selectedLoc into keyDownPoint   --get the location of the
> insertion point
> pass keyDown
> end keyDown
> 
> 
> on keyup
> global keyDownPoint
> put the selectedLoc into lastPoint             --get the location of
> the insertion point
> click at keyDownPoint                          --click at the word
> based on the KeyDown event
> put the clicktext & return after field "debug" --so I can see what has
> happened
> click at lastPoint                             --put the insertion
> point back so I don't type 'backwards'
> pass keyUp
> end keyup
> 
> 
> Does anyone know of a way to do this that is reasonably fast?  Any
> thoughts at all would be appreciated.
> 
> Thanks,
> John Miskimins
> 
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> http://lists.runrev.com/mailman/listinfo/use-revolution




More information about the use-livecode mailing list