Where is the web site?
James Hurley
jhurley0305 at sbcglobal.net
Mon Jun 23 17:29:39 EDT 2008
Wilhelm Sanke wrote:
Thanks Wilhelm. I have submitted the request the the site you cited.
I think it should be very easy for RR to include the clickWord
function in the Revolution vocabulary.
And thanks for the extension. I try it out.
Jim Hurley
>
> The website for reporting bugs and enhancements is
>
> <http://www.runrev.com/support/quality-control-center/> or
> <http://quality.runrev.com/qacenter/>
>
> I second you enhancement request.
>
> Your "kludge"-solution is surely one of the best you can come up
> with in
> Revolution. The only problem you could encounter is the case when the
> text of the line contains more than one instance of the word, because
> wordoffset always finds the *first* instance of the word and not
> necessarily the word you clicked at.
>
> In a related context - getting the wordnumber of a clicked-at word
> in a
> field and at the same time hilite the clicked word - I have found the
> following solution:
>
> Script of the text field:
>
> on mouseUp
> Global gchunk, gtext
> put the mousechunk into gchunk
> put the mousetext into gtext
> send "mouseup" to btn "wordoffset"
> end mouseUp
>
> Script of btn "wordoffset":
>
> on mouseUp
> Global gchunk, gtext
> put fld 1 into tField
> put tfield into tfield2
> put word 2 of gchunk into tBegin
> put "#" before char tBegin of Tfield2
> put "#" before gtext
> put wordoffset(gtext,tfield2) into tword
> put "word" &&tword&&"in field 1" into fld "wordnumber"
> set the traversalon of fld 1 to true
> select word tword of fld 1
> end mouseUp
More information about the use-livecode
mailing list