Datagrid: scrolling to the top of a record (dgRectOfIndex fails)

David Bovill david at architex.tv
Sat Oct 17 08:42:27 EDT 2009


It seems that this little utility is broken for records that are scrolled
above the datagrid.

This is because when a record is scrolled completely above the datagrid it
is set to invisible and set to the top of the screen / grid or perhaps even
deleted).

What I want to do is to be able to scroll a certain number of records off
the top of the screen. For that I can set the dgprop ["cache controls"] to
true and work out the height of all the "dgDataControlOfIndex [pIndex]"
above the row I want to scroll to. Working on this now, so will report back,
but would seem to be a useful property to add / fix here, which would allow
you to access the geometry of a row even though it has not been drawn to
screen?



More information about the use-livecode mailing list