API:VerticalScrollbarSetPageSize
From RoR Wiki
UI Lua API · Scrollbar functions
Version: WAR 1.4.8
Meant to set the page size of a VerticalScrollbar. In the current client it sets the line size instead. See Details.
VerticalScrollbarSetPageSize(scrollbarName, size)
Arguments
- scrollbarName
string– Name of the VerticalScrollbar.- size
number– The value to store.
Returns
Nothing.
Details
- The client passes the arguments to the scrollbar in the wrong order:
sizebecomes the line size (returned by VerticalScrollbarGetLineSize). The page size and the maximum scroll position are not changed. - To set the page size, use VerticalScrollbarSetLineSize, which has the opposite mix-up. To set both values, call:
VerticalScrollbarSetLineSize( name, pageSize ) -- sets the page size (line size becomes the old page size) VerticalScrollbarSetPageSize( name, lineSize ) -- sets the line size
- The thumb is recalculated and the current position is clamped again. If that moves the position, the
OnScrollPosChangedhandler runs. - The stock UI never calls this function.
- The function needs at least two arguments and only reads the last two. Any extra arguments placed in front of them are ignored.
Errors
Error in function call 'VerticalScrollbarSetPageSize': Window %s does not existError in function call 'VerticalScrollbarSetPageSize': Window %s is not a VerticalScrollbar
Example
See the call order in Details.
