GClasses
|
Makes a horizontal scroll bar. More...
#include <GWidgets.h>
Public Member Functions | |
GWidgetHorizScrollBar (GWidgetGroup *pParent, int x, int y, int w, int h, int nViewSize, int nModelSize) | |
virtual | ~GWidgetHorizScrollBar () |
virtual WidgetType | type () |
int | viewSize () |
Returns the current view size. | |
int | modelSize () |
Returns the current model size. | |
void | setViewSize (int n) |
Sets the size of the view area that this scroll bar represents (The size of the sliding tab is determined by the ratio of the size of the view over the size of the model) | |
void | setModelSize (int n) |
Sets the size of the model that this scroll bar represents (The size of the sliding tab is determined by the ratio of the size of the view over the size of the model) | |
int | pos () |
Gets the current scroll position of this scroll bar. | |
void | setPos (int n) |
Sets the current scroll position. | |
virtual void | draw (GImage *pCanvas, int x, int y) |
Draws this widget on pCanvas at (x,y) | |
Protected Member Functions | |
virtual void | onPushVCRButton (GWidgetVCRButton *pButton) |
virtual void | onSlideTab (GWidgetSliderTab *pTab, int dx, int dy) |
virtual void | onClickTab (GWidgetSliderTab *pTab) |
int | buttonWidth () |
Protected Attributes | |
int | m_nViewSize |
int | m_nModelSize |
int | m_nPos |
GWidgetVCRButton * | m_pLeftButton |
GWidgetVCRButton * | m_pRightButton |
GWidgetSliderTab * | m_pLeftTab |
GWidgetSliderTab * | m_pTab |
GWidgetSliderTab * | m_pRightTab |
Makes a horizontal scroll bar.
GClasses::GWidgetHorizScrollBar::GWidgetHorizScrollBar | ( | GWidgetGroup * | pParent, |
int | x, | ||
int | y, | ||
int | w, | ||
int | h, | ||
int | nViewSize, | ||
int | nModelSize | ||
) |
virtual GClasses::GWidgetHorizScrollBar::~GWidgetHorizScrollBar | ( | ) | [virtual] |
int GClasses::GWidgetHorizScrollBar::buttonWidth | ( | ) | [protected] |
virtual void GClasses::GWidgetHorizScrollBar::draw | ( | GImage * | pCanvas, |
int | x, | ||
int | y | ||
) | [virtual] |
Draws this widget on pCanvas at (x,y)
Implements GClasses::GWidget.
int GClasses::GWidgetHorizScrollBar::modelSize | ( | ) | [inline] |
Returns the current model size.
virtual void GClasses::GWidgetHorizScrollBar::onClickTab | ( | GWidgetSliderTab * | pTab | ) | [protected, virtual] |
Reimplemented from GClasses::GWidgetGroup.
virtual void GClasses::GWidgetHorizScrollBar::onPushVCRButton | ( | GWidgetVCRButton * | pButton | ) | [protected, virtual] |
Reimplemented from GClasses::GWidgetGroup.
virtual void GClasses::GWidgetHorizScrollBar::onSlideTab | ( | GWidgetSliderTab * | pTab, |
int | dx, | ||
int | dy | ||
) | [protected, virtual] |
Reimplemented from GClasses::GWidgetGroup.
int GClasses::GWidgetHorizScrollBar::pos | ( | ) | [inline] |
Gets the current scroll position of this scroll bar.
void GClasses::GWidgetHorizScrollBar::setModelSize | ( | int | n | ) |
Sets the size of the model that this scroll bar represents (The size of the sliding tab is determined by the ratio of the size of the view over the size of the model)
void GClasses::GWidgetHorizScrollBar::setPos | ( | int | n | ) |
Sets the current scroll position.
void GClasses::GWidgetHorizScrollBar::setViewSize | ( | int | n | ) |
Sets the size of the view area that this scroll bar represents (The size of the sliding tab is determined by the ratio of the size of the view over the size of the model)
virtual WidgetType GClasses::GWidgetHorizScrollBar::type | ( | ) | [inline, virtual] |
Implements GClasses::GWidget.
int GClasses::GWidgetHorizScrollBar::viewSize | ( | ) | [inline] |
Returns the current view size.
int GClasses::GWidgetHorizScrollBar::m_nModelSize [protected] |
int GClasses::GWidgetHorizScrollBar::m_nPos [protected] |
int GClasses::GWidgetHorizScrollBar::m_nViewSize [protected] |
GWidgetSliderTab* GClasses::GWidgetHorizScrollBar::m_pTab [protected] |