trichview.support
Pixel coords of itemoffest in table cell |
Author |
Message |
Justin Turberville |
Posted: 08/13/2002 15:19:45 I've found that in some cases just getting the coords of the item containing the selection is not good enough - if it contains a large amount of contiguous text, the selection may not be scrolled into view. I know you said it would be a lot more difficult and am sorry to ask... It only needs be a ballpark y coord so a shortcut method would probably be fine if you can think of one. I tried this where the data height adjusted by the offset in the length is added, but it doesn't allow for line height variations: if (fcurdata is TRVTableCellData) then TRVTableCellData(fcurdata).getoriginex(x,y) else frichview.getitemcoords(itemno,x,y); // Adjust for offset inc(y,round(TCustomRVFormattedData(fcurdata).getheight*(itemoffs/length(fcur data.items[itemno])))); frichview.scrollto(y); |
Powered by ABC Amber Outlook Express Converter