Is there a way to determine the line number of the top line of a text field?

The field's textheight is NOT set as the text present comes from html and 
different heading levels are present.

Context:
I am using an rTree object to provide an hierarchical list of these headings 
and clicking on a node within the tree scrolls the field so that the 
appropriate line is placed at the top of the field.

Issue:
I would like to display the current section (heading) name in a small "heading" 
field above the display field based on the user scrolling through the field.
As they scroll past the next heading line I would like the "heading" field to 
reflect this.

However there doesn't seem to be a way of going the other way. Getting the line 
of the field sitting at the top of the field.

Its as if the field contents and its actual display are using two different 
systems, text chunks versus pixel graphics.
Livecode can seemlessly go from specifying the text chunk translating it to the 
appropriate pixel value of the vscroll, but it can't do the reverse.


James





_______________________________________________
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

Reply via email to