1//************************************ bs::framework - Copyright 2018 Marko Pintera **************************************//
2//*********** Licensed under the MIT license. See LICENSE.md for full terms. This notice is not to be removed. ***********//
3#pragma once
4
5#include "BsPrerequisites.h"
6#include "GUI/BsGUIScrollBar.h"
7
8namespace bs
9{
10 /** @addtogroup GUI
11 * @{
12 */
13
14 /** Specialization of a GUIScrollBar for vertical scrolling. */
15 class BS_EXPORT GUIScrollBarVert : public GUIScrollBar
16 {
17 public:
18 /** Returns type name of the GUI element used for finding GUI element styles. */
19 static const String& getGUITypeName(bool resizeable);
20
21 /**
22 * Creates a new vertical scroll bar.
23 *
24 * @param[in] styleName Optional style to use for the element. Style will be retrieved from GUISkin of the
25 * GUIWidget the element is used on. If not specified default style is used.
26 */
27 static GUIScrollBarVert* create(const String& styleName = StringUtil::BLANK);
28
29 /**
30 * Creates a new vertical scroll bar.
31 *
32 * @param[in] resizable If true the scrollbar will have additional handles that allow the scroll handle to
33 * be resized. This allows you to adjust the size of the visible scroll area.
34 * @param[in] styleName Optional style to use for the element. Style will be retrieved from GUISkin of the
35 * GUIWidget the element is used on. If not specified default style is used.
36 */
37 static GUIScrollBarVert* create(bool resizable, const String& styleName = StringUtil::BLANK);
38
39 /**
40 * Creates a new vertical scroll bar.
41 *
42 * @param[in] options Options that allow you to control how is the element positioned and sized.
43 * This will override any similar options set by style.
44 * @param[in] styleName Optional style to use for the element. Style will be retrieved from GUISkin of the
45 * GUIWidget the element is used on. If not specified default style is used.
46 */
47 static GUIScrollBarVert* create(const GUIOptions& options, const String& styleName = StringUtil::BLANK);
48
49 /**
50 * Creates a new vertical scroll bar.
51 *
52 * @param[in] resizable If true the scrollbar will have additional handles that allow the scroll handle to
53 * be resized. This allows you to adjust the size of the visible scroll area.
54 * @param[in] options Options that allow you to control how is the element positioned and sized.
55 * This will override any similar options set by style.
56 * @param[in] styleName Optional style to use for the element. Style will be retrieved from GUISkin of the
57 * GUIWidget the element is used on. If not specified default style is used.
58 */
59 static GUIScrollBarVert* create(bool resizable, const GUIOptions& options, const String& styleName = StringUtil::BLANK);
60 protected:
61 GUIScrollBarVert(bool resizable, const String& styleName, const GUIDimensions& dimensions);
62 ~GUIScrollBarVert() = default;
63 };
64
65 /** @} */
66}