CScrollBar



Implements ScrollBar control.

You can find more information in comments below. Overrided methods can be found in corresponding base classes and interfaces.

class CScrollBar :public virtual IScrollBar, public CControl
{
public:
    void(*OnScroll)(IControl *sender); // Event called when scrolling 

    // IControl methods 
    void Refresh(const bool refresh_children) override;

    CScrollBar();
    CScrollBar(IControl *parent);
    CScrollBar(IForm *parent);
    ~CScrollBar() override;

    IFont *getControlFont() override;
    RectF getRenderRect() override;

    bool setFont(IFont *value, const bool copy = true) override;
    bool setWantTabs(const bool value) override;
    bool setTabStop(const bool value) override;
    bool setDeactivateByTab(const bool value) override;
    bool setUseParentFont(const bool value) override;
    bool setDPI(const Point &value) override;

    bool setScroll(IBuiltInScroll *scroll);

    float getMin() override;
    float getMax() override;
    float getPosition() override;
    bool isVertical() override;

    bool setMin(const float value) override;
    bool setMax(const float value) override;
    bool setPosition(const float value) override;
    bool setVertical(const bool value) override;

    float getScrollerSize(); // Return scroller size 
    // Return scrolling parameters 
    float getDeltaSmall();
    float getDeltaMedium();
    float getDeltaLarge();

    bool setScrollerSize(const float value); // Set scroller size 
    // Set scrolling parameters 
    bool setDeltaSmall(const float value);
    bool setDeltaMedium(const float value);
    bool setDeltaLarge(const float value);

    // Following getters works only if assocciated IScroll is instance of CScroll 
    CBuiltInScroll::STATE getState();
    CBuiltInScroll::ELEMENT getHoveredElement();
    CBuiltInScroll::ELEMENT getActiveElement();
    float getScrollInterval();
    float getArrowSize();
    float getBorderWidth();
    float getBorderRadius();
    Color getBorderColor(const CBuiltInScroll::STATE state);
    Color getBackgroundColor(const CBuiltInScroll::STATE state);
    Gradient *getBackgroundGradient(const CBuiltInScroll::STATE state);
    int getShadowRadius(const CBuiltInScroll::STATE state);
    PointF getShadowShift(const CBuiltInScroll::STATE state);
    Color getShadowColor(const CBuiltInScroll::STATE state);
    float getStartArrowBorderWidth();
    float getStartArrowBorderRadius();
    Color getStartArrowBorderColor(const CBuiltInScroll::ELEMENT_STATE state);
    Color getStartArrowBackgroundColor(const CBuiltInScroll::ELEMENT_STATE state);
    Gradient *getStartArrowBackgroundGradient(const CBuiltInScroll::ELEMENT_STATE state);
    Color getStartArrowColor1(const CBuiltInScroll::ELEMENT_STATE state);
    Color getStartArrowColor2(const CBuiltInScroll::ELEMENT_STATE state);
    Color getStartArrowColor3(const CBuiltInScroll::ELEMENT_STATE state);
    float getEndArrowBorderWidth();
    float getEndArrowBorderRadius();
    Color getEndArrowBorderColor(const CBuiltInScroll::ELEMENT_STATE state);
    Color getEndArrowBackgroundColor(const CBuiltInScroll::ELEMENT_STATE state);
    Gradient *getEndArrowBackgroundGradient(const CBuiltInScroll::ELEMENT_STATE state);
    Color getEndArrowColor1(const CBuiltInScroll::ELEMENT_STATE state);
    Color getEndArrowColor2(const CBuiltInScroll::ELEMENT_STATE state);
    Color getEndArrowColor3(const CBuiltInScroll::ELEMENT_STATE state);
    float getScrollerBorderWidth();
    float getScrollerBorderRadius();
    Color getScrollerBorderColor(const CBuiltInScroll::ELEMENT_STATE state);
    Color getScrollerBackgroundColor(const CBuiltInScroll::ELEMENT_STATE state);
    Gradient *getScrollerBackgroundGradient(const CBuiltInScroll::ELEMENT_STATE state);
    Color getScrollerLinesBorderColor(const CBuiltInScroll::ELEMENT_STATE state);
    Color getScrollerLinesBackgroundColor(const CBuiltInScroll::ELEMENT_STATE state);
    PointF getScrollerLinesSize();
    float getScrollerLinesDistance();
    float getScrollerLinesBorderWidth();

    // Following setters works only if assocciated IScroll is instance of CScroll 
    bool setScrollInterval(const float value);
    bool setArrowSize(const float value);
    bool setBorderWidth(const float value);
    bool setBorderRadius(const float value);
    bool setBorderColor(const CBuiltInScroll::STATE state, const Color &value);
    bool setBackgroundColor(const CBuiltInScroll::STATE state, const Color &value);
    bool setShadowRadius(const CBuiltInScroll::STATE state, const int value);
    bool setShadowShift(const CBuiltInScroll::STATE state, const PointF &value);
    bool setShadowColor(const CBuiltInScroll::STATE state, const Color &value);
    bool setStartArrowBorderWidth(const float value);
    bool setStartArrowBorderRadius(const float value);
    bool setStartArrowBorderColor(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setStartArrowBackgroundColor(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setStartArrowColor1(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setStartArrowColor2(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setStartArrowColor3(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setEndArrowBorderWidth(const float value);
    bool setEndArrowBorderRadius(const float value);
    bool setEndArrowBorderColor(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setEndArrowBackgroundColor(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setEndArrowColor1(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setEndArrowColor2(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setEndArrowColor3(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setScrollerBorderWidth(const float value);
    bool setScrollerBorderRadius(const float value);
    bool setScrollerBorderColor(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setScrollerBackgroundColor(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setScrollerLinesBorderColor(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setScrollerLinesBackgroundColor(const CBuiltInScroll::ELEMENT_STATE state, const Color &value);
    bool setScrollerLinesSize(const PointF &value);
    bool setScrollerLinesDistance(const float value);
    bool setScrollerLinesBorderWidth(const float value);
};
Namespace: nitisa::standard
Include: Standard/Controls/ScrollBar/ScrollBar.h