To get the current range for the scroll bar, call:
|
||
|
|
|
|
|
|
|
|
|
|
|
|
To get the current value for the scroll bar, call:
|
||
|
|
|
|
|
|
The scroll bar type can be HSBAR or VSBAR. The value returned by wn_sbval() represents the thumb's current value within the range.
You can determine the position of the thumb in the page region by calling:
|
||
|
|
|
|
|
|
The value returned is the thumb's position in the page region. Numbering of character positions in the page region starts at 0. If you want to translate this value into a window coordinate, you must add the number of characters in the border before the page region begins (i.e., half the cover size).
For auto-update scroll bars, the minimum value is 0. The maximum for a vertical scroll bar is the number of the last row in the underlying memory screen buffer or memory file. The maximum for a horizontal scroll bar is the number of the last column. The current value for an auto-update vertical scroll bar is maintained as the current row of the underlying memory file or buffer. The current value for an auto-update horizontal scroll bar is maintained as the current column of the underlying memory file or buffer.