|
GuiScrollCtrl Class Reference
[Container Controls]
A container that allows to view one or more possibly larger controls inside its area by providing horizontal and/or vertical scroll bars. More...
Public Member Functions | |
void | computeSizes () |
Refresh sizing and positioning of child controls. | |
Point2I | getScrollPosition () |
Get the current coordinates of the scrolled content. | |
int | getScrollPositionX () |
Get the current X coordinate of the scrolled content. | |
int | getScrollPositionY () |
Get the current Y coordinate of the scrolled content. | |
void | scrollToBottom () |
Scroll all the way to the bottom of the vertical scrollbar and the left of the horizontal bar. | |
void | scrollToObject (GuiControl control) |
Scroll the control so that the given child control is visible. | |
void | scrollToTop () |
Scroll all the way to the top of the vertical and left of the horizontal scrollbar. | |
void | setScrollPosition (int x, int y) |
Set the position of the scrolled content. | |
Callbacks | |
void | onScroll () |
Called each time the child controls are scrolled by some amount. | |
Public Attributes | |
Scolling | |
Point2I | childMargin |
Padding region to put around child contents. | |
bool | constantThumbHeight |
GuiScrollBarBehavior | hScrollBar |
When to display the horizontal scrollbar. | |
bool | lockHorizScroll |
Horizontal scrolling not allowed if set. | |
bool | lockVertScroll |
Vertical scrolling not allowed if set. | |
int | mouseWheelScrollSpeed |
Pixels/Tick - if not positive then mousewheel scrolling occurs instantly (like other scrolling). | |
GuiScrollBarBehavior | vScrollBar |
When to display the vertical scrollbar. | |
bool | willFirstRespond |
Detailed Description
A container that allows to view one or more possibly larger controls inside its area by providing horizontal and/or vertical scroll bars.
Member Function Documentation
void GuiScrollCtrl::computeSizes | ( | ) |
Refresh sizing and positioning of child controls.
Point2I GuiScrollCtrl::getScrollPosition | ( | ) |
Get the current coordinates of the scrolled content.
- Returns:
- The current position of the scrolled content.
int GuiScrollCtrl::getScrollPositionX | ( | ) |
Get the current X coordinate of the scrolled content.
- Returns:
- The current X coordinate of the scrolled content.
int GuiScrollCtrl::getScrollPositionY | ( | ) |
Get the current Y coordinate of the scrolled content.
- Returns:
- The current Y coordinate of the scrolled content.
void GuiScrollCtrl::onScroll | ( | ) |
Called each time the child controls are scrolled by some amount.
void GuiScrollCtrl::scrollToBottom | ( | ) |
Scroll all the way to the bottom of the vertical scrollbar and the left of the horizontal bar.
void GuiScrollCtrl::scrollToObject | ( | GuiControl | control | ) |
Scroll the control so that the given child control is visible.
- Parameters:
-
control A child control.
void GuiScrollCtrl::scrollToTop | ( | ) |
Scroll all the way to the top of the vertical and left of the horizontal scrollbar.
void GuiScrollCtrl::setScrollPosition | ( | int | x, | |
int | y | |||
) |
Set the position of the scrolled content.
- Parameters:
-
x Position on X axis. y Position on y axis.
Member Data Documentation
Point2I GuiScrollCtrl::childMargin |
Padding region to put around child contents.
When to display the horizontal scrollbar.
Horizontal scrolling not allowed if set.
Vertical scrolling not allowed if set.
Pixels/Tick - if not positive then mousewheel scrolling occurs instantly (like other scrolling).
When to display the vertical scrollbar.