Double checking maximum vertical scroll

Paul Dupuis paul at researchware.com
Mon Jul 19 13:44:25 EDT 2021


In a list field, if you are scrolling a field by script control, the max 
vertical scroll to display the last line would be:

put (the height of me - the topMargin of me - the bottomMargin of me) 
into tAdjustedHeight -- tope and bottom margins
if the showBorder of me is true then put tAdjustedHeight - (the 
borderWidth of me * 2) into tAdjustedHeight -- top and bottom borders
the formattedHeight of me - tAdjustedHeight into tMaxVerticalScroll

-- essentially you have to take the formattedHeight minus the field 
height and subtract out the margins and borders (if there are borders shown)

Is this correct? Am I missing anything?




More information about the use-livecode mailing list