getting the word and line chunk of words simultaneously
Bill Marriott
wjm at wjm.org
Thu Dec 11 03:28:03 EST 2008
Did you have a look at the functions offset and lineoffset?
put "football" into myWord
put "Text position:" && offset(myWord,theContainer)
put lineOffset(myWord,theContainer) into L
put "Line:" && L
put "Line position:" && offset(myWord,line L of theContainer)
"James Hale" <james at thehales.id.au> wrote
> I do not just want the word position within the text itself.
>
> I also want the line the word is located and the position within that
> line.
>
> So, as an example I end up with the following for one word, say
> "football"
>
> Word: football
> Text position: 132
> Line: 4
> Line Position: 13
More information about the use-livecode
mailing list