On 11/18/2014, 1:08 PM, dunb...@aol.com wrote:
I tried a bunch of stuff like that; your thinking seems sound. I
thought mine did as well. Sometimes it sets a line properly, and
sometimes, especially with small textSize lines near large ones, not
at all. In fact, several lines away.
I am still not having any issues at all with this handler:
on doScroll pNum
put the formattedheight of line 1 to pNum of fld 1 into tScroll
set the scroll of fld 1 to tScroll
set the hilitedline of fld 1 to pNum
end doScroll
It places the correct line at the top, no matter which line is currently
selected, and selects the designated line of the field.
The thing that makes this work is that it does require having
listbehavior set to true. Once that's done, the engine handles all the
details without any trouble.
Here is the handler I used to set up the field content. I add the line
numbers so I can see whether the correct line does in fact get selected.
on setup
get the colornames
repeat with x = 1 to the number of lines in it
put x & space before line x of it
end repeat
put it into fld 1
repeat with x = 1 to the number of lines in fld 1 step 2
set the textsize of line x of fld 1 to random(40)+12
end repeat
end setup
--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com
_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode