TGUI  1.6.1
Loading...
Searching...
No Matches

Base class for widgets with a single scrollbar. More...

#include <TGUI/Widgets/Scrollbar.hpp>

Inheritance diagram for tgui::ScrollbarChildInterface:
tgui::ChatBox tgui::Label tgui::ListBox tgui::RichTextLabel

Public Member Functions

 ScrollbarChildInterface ()
 Default constructor.
 
 ScrollbarChildInterface (const ScrollbarChildInterface &)
 Copy constructor.
 
 ScrollbarChildInterface (ScrollbarChildInterface &&) noexcept
 Move constructor.
 
virtual ~ScrollbarChildInterface ()=default
 Destructor.
 
ScrollbarChildInterfaceoperator= (const ScrollbarChildInterface &)
 Overload of copy assignment operator.
 
ScrollbarChildInterfaceoperator= (ScrollbarChildInterface &&) noexcept
 Move assignment.
 
ScrollbarAccessorgetScrollbar ()
 Returns an object that provides access to the widget's scrollbar.
 
const ScrollbarAccessorgetScrollbar () const
 Returns an object that provides access to the widget's scrollbar.
 

Protected Member Functions

virtual void scrollbarValueChanged ()
 Called when the value of the scrollbar has been changed via getScrollbar()->setValue(...)
 
virtual void scrollbarPolicyChanged ()
 Called when the policy of the scrollbar has been changed via getScrollbar()->setPolicy(...)
 
virtual void scrollbarScrollAmountChanged ()
 Called when the scroll amount of the scrollbar has been changed via getScrollbar()->setScrollAmount(...)
 
void saveScrollbarPolicy (std::unique_ptr< DataIO::Node > &node) const
 This function should be called inside the save function in order to save the configured scrollbar policy.
 
void loadScrollbarPolicy (const std::unique_ptr< DataIO::Node > &node)
 This function should be called inside the load function in order to load the wanted scrollbar policy.
 

Protected Attributes

CopiedSharedPtr< ScrollbarChildWidgetm_scrollbar
 
ScrollbarAccessor m_scrollbarAccessor
 

Detailed Description

Base class for widgets with a single scrollbar.

This class exists so that these widgets wouldn't need to define their own copy constructor and assignment operators.

Since
TGUI 1.5

Member Function Documentation

◆ getScrollbar() [1/2]

ScrollbarAccessor * tgui::ScrollbarChildInterface::getScrollbar ( )
nodiscard

Returns an object that provides access to the widget's scrollbar.

Returns
Pointer to object that allows reading scrollbar properties and allows setting some of them

◆ getScrollbar() [2/2]

const ScrollbarAccessor * tgui::ScrollbarChildInterface::getScrollbar ( ) const
nodiscard

Returns an object that provides access to the widget's scrollbar.

Returns
Pointer to object that allows reading scrollbar properties (there is also a non-const function for setting)

◆ scrollbarPolicyChanged()

virtual void tgui::ScrollbarChildInterface::scrollbarPolicyChanged ( )
protectedvirtual

Called when the policy of the scrollbar has been changed via getScrollbar()->setPolicy(...)

Reimplemented in tgui::Label.

◆ scrollbarValueChanged()

virtual void tgui::ScrollbarChildInterface::scrollbarValueChanged ( )
protectedvirtual

Called when the value of the scrollbar has been changed via getScrollbar()->setValue(...)

Reimplemented in tgui::ListBox.


The documentation for this class was generated from the following file: