API:VerticalScrollbarGetMaxScrollPosition
From RoR Wiki
UI Lua API · Scrollbar functions
Version: WAR 1.4.8
Returns the maximum scroll position of a VerticalScrollbar.
maxPosition = VerticalScrollbarGetMaxScrollPosition(scrollbarName)
Arguments
- scrollbarName
string– Name of the VerticalScrollbar.
Returns
- maxPosition
number– The maximum scroll position.
Details
- The highest position the scrollbar can actually reach is this value minus the page size (see VerticalScrollbarGetPageSize).
- The stock UI never calls this function.
Errors
The error messages use the name ButtonGetPressedFlag:
Error in function call 'ButtonGetPressedFlag': Window %s does not existError in function call 'ButtonGetPressedFlag': Window %s is not a VerticalScrollbar
Example
A minimal example built from the signature:
local lastPos = VerticalScrollbarGetMaxScrollPosition( "MyScrollbar" ) - VerticalScrollbarGetPageSize( "MyScrollbar" )
