TGUI  1.3-dev
Loading...
Searching...
No Matches
tgui::SpinButtonRenderer Class Reference
Inheritance diagram for tgui::SpinButtonRenderer:
tgui::WidgetRenderer

Public Member Functions

void setBorders (const Borders &borders)
 Changes the size of the borders.
 
TGUI_NODISCARD Borders getBorders () const
 Returns the size of the borders.
 
void setBorderBetweenArrows (float space)
 Changes the space that is left between the arrows.
 
TGUI_NODISCARD float getBorderBetweenArrows () const
 Returns the space that is left between the arrows.
 
void setBackgroundColor (Color color)
 Changes the color of the background of the arrows.
 
TGUI_NODISCARD Color getBackgroundColor () const
 Returns the background color of the arrows.
 
void setBackgroundColorHover (Color color)
 Changes the background color of the arrows in the hover state (mouse standing on top of the spin button)
 
TGUI_NODISCARD Color getBackgroundColorHover () const
 Returns the background color of the arrows in the hover state (mouse standing on top of the spin button)
 
void setArrowColor (Color color)
 Changes the color of the arrows.
 
TGUI_NODISCARD Color getArrowColor () const
 Returns the color of the arrows.
 
void setArrowColorHover (Color color)
 Changes the color of the arrows in the hover state (mouse standing on top of the spin button)
 
TGUI_NODISCARD Color getArrowColorHover () const
 Returns the color of the arrows in the hover state (mouse standing on top of the spin button)
 
void setBorderColor (Color color)
 Changes the color of the borders.
 
TGUI_NODISCARD Color getBorderColor () const
 Returns the color of the borders.
 
void setTextureArrowUp (const Texture &texture)
 Changes the image that is used as the up arrow.
 
TGUI_NODISCARD const TexturegetTextureArrowUp () const
 Returns the image that is used as the up arrow.
 
void setTextureArrowUpHover (const Texture &texture)
 Changes the image that is used as the up arrow when the mouse is located on top of the spin button.
 
TGUI_NODISCARD const TexturegetTextureArrowUpHover () const
 Returns the image that is used as the up arrow when the mouse is located on top of the spin button.
 
void setTextureArrowDown (const Texture &texture)
 Changes the image that is used as the down arrow.
 
TGUI_NODISCARD const TexturegetTextureArrowDown () const
 Returns the image that is used as the up arrow.
 
void setTextureArrowDownHover (const Texture &texture)
 Changes the image that is used as the down arrow when the mouse is located on top of the spin button.
 
TGUI_NODISCARD const TexturegetTextureArrowDownHover () const
 Returns the image that is used as the down arrow when the mouse is located on top of the spin button.
 
 WidgetRenderer ()=default
 Default constructor.
 
 WidgetRenderer (const WidgetRenderer &)
 Copy constructor.
 
 WidgetRenderer (WidgetRenderer &&)=default
 Default move constructor.
 
 WidgetRenderer (const std::shared_ptr< RendererData > &data)
 Construct the renderer from renderer data.
 
- Public Member Functions inherited from tgui::WidgetRenderer
 WidgetRenderer ()=default
 Default constructor.
 
 WidgetRenderer (const WidgetRenderer &)
 Copy constructor.
 
 WidgetRenderer (WidgetRenderer &&)=default
 Default move constructor.
 
WidgetRendereroperator= (const WidgetRenderer &)
 Copy assignment operator.
 
WidgetRendereroperator= (WidgetRenderer &&)=default
 Default move assignment operator.
 
 WidgetRenderer (const std::shared_ptr< RendererData > &data)
 Construct the renderer from renderer data.
 
virtual ~WidgetRenderer ()=default
 Virtual destructor.
 
void setOpacity (float opacity)
 Changes the opacity of the widget.
 
TGUI_NODISCARD float getOpacity () const
 Returns the opacity of the widget.
 
void setOpacityDisabled (float opacity)
 Changes the opacity of the widget when it is disabled.
 
TGUI_NODISCARD float getOpacityDisabled () const
 Returns the opacity of the widget when it is disabled.
 
void setFont (const Font &font)
 Changes the font used for the text in the widget.
 
TGUI_NODISCARD Font getFont () const
 Returns the font associated with the widget (if any)
 
void setTextSize (unsigned int size)
 Changes the text size of the widget that is specified by the renderer.
 
TGUI_NODISCARD unsigned int getTextSize () const
 Returns text size of the widget that is specified by the renderer.
 
void setTransparentTexture (bool ignoreTransparentParts)
 Sets whether mouse events should be ignored on transparent parts of the texture of the widget in normal state.
 
TGUI_NODISCARD bool getTransparentTexture () const
 Returns whether mouse events should be ignored on transparent parts of the texture of the widget.
 
void setProperty (const String &property, ObjectConverter &&value)
 Changes a property of the renderer.
 
TGUI_NODISCARD ObjectConverter getProperty (const String &property) const
 Retrieves the value of a certain property.
 
TGUI_NODISCARD const std::map< String, ObjectConverter > & getPropertyValuePairs () const
 Gets a map with all properties and their values.
 
void subscribe (Widget *widget)
 Subscribes a callback function to changes in the renderer.
 
void unsubscribe (Widget *widget)
 Subscribes a callback function to changes in the renderer.
 
void setData (const std::shared_ptr< RendererData > &data)
 
TGUI_NODISCARD std::shared_ptr< RendererDatagetData () const
 Returns the renderer data.
 
TGUI_NODISCARD std::shared_ptr< RendererDataclone () const
 Gets a clone of the renderer data.
 

Additional Inherited Members

- Protected Attributes inherited from tgui::WidgetRenderer
std::shared_ptr< RendererDatam_data = RendererData::create()
 

Member Function Documentation

◆ getArrowColor()

TGUI_NODISCARD Color tgui::SpinButtonRenderer::getArrowColor ( ) const

Returns the color of the arrows.

Returns
arrow color

◆ getArrowColorHover()

TGUI_NODISCARD Color tgui::SpinButtonRenderer::getArrowColorHover ( ) const

Returns the color of the arrows in the hover state (mouse standing on top of the spin button)

Returns
arrow color

◆ getBackgroundColor()

TGUI_NODISCARD Color tgui::SpinButtonRenderer::getBackgroundColor ( ) const

Returns the background color of the arrows.

Returns
background color

◆ getBackgroundColorHover()

TGUI_NODISCARD Color tgui::SpinButtonRenderer::getBackgroundColorHover ( ) const

Returns the background color of the arrows in the hover state (mouse standing on top of the spin button)

Returns
background color

◆ getBorderBetweenArrows()

TGUI_NODISCARD float tgui::SpinButtonRenderer::getBorderBetweenArrows ( ) const

Returns the space that is left between the arrows.

Returns
space between the arrows

◆ getBorderColor()

TGUI_NODISCARD Color tgui::SpinButtonRenderer::getBorderColor ( ) const

Returns the color of the borders.

Returns
Border color

◆ getBorders()

TGUI_NODISCARD Borders tgui::SpinButtonRenderer::getBorders ( ) const

Returns the size of the borders.

Returns
border size

◆ getTextureArrowDown()

TGUI_NODISCARD const Texture & tgui::SpinButtonRenderer::getTextureArrowDown ( ) const

Returns the image that is used as the up arrow.

Returns
down arrow texture

◆ getTextureArrowDownHover()

TGUI_NODISCARD const Texture & tgui::SpinButtonRenderer::getTextureArrowDownHover ( ) const

Returns the image that is used as the down arrow when the mouse is located on top of the spin button.

Returns
down hover arrow texture

◆ getTextureArrowUp()

TGUI_NODISCARD const Texture & tgui::SpinButtonRenderer::getTextureArrowUp ( ) const

Returns the image that is used as the up arrow.

Returns
up arrow texture

◆ getTextureArrowUpHover()

TGUI_NODISCARD const Texture & tgui::SpinButtonRenderer::getTextureArrowUpHover ( ) const

Returns the image that is used as the up arrow when the mouse is located on top of the spin button.

Returns
up hover arrow texture

◆ setArrowColor()

void tgui::SpinButtonRenderer::setArrowColor ( Color color)

Changes the color of the arrows.

Parameters
colorNew arrow color

Note that this color is ignored when an up and down arrow texture were set.

◆ setArrowColorHover()

void tgui::SpinButtonRenderer::setArrowColorHover ( Color color)

Changes the color of the arrows in the hover state (mouse standing on top of the spin button)

Parameters
colorNew arrow color

◆ setBackgroundColor()

void tgui::SpinButtonRenderer::setBackgroundColor ( Color color)

Changes the color of the background of the arrows.

Parameters
colorNew background color

Note that this color is ignored when you set an image as background.

◆ setBackgroundColorHover()

void tgui::SpinButtonRenderer::setBackgroundColorHover ( Color color)

Changes the background color of the arrows in the hover state (mouse standing on top of the spin button)

Parameters
colorNew background color

◆ setBorderBetweenArrows()

void tgui::SpinButtonRenderer::setBorderBetweenArrows ( float space)

Changes the space that is left between the arrows.

Parameters
spaceThe space between the arrows

◆ setBorderColor()

void tgui::SpinButtonRenderer::setBorderColor ( Color color)

Changes the color of the borders.

Parameters
colorNew border color

◆ setBorders()

void tgui::SpinButtonRenderer::setBorders ( const Borders & borders)

Changes the size of the borders.

Parameters
bordersSize of the borders

◆ setTextureArrowDown()

void tgui::SpinButtonRenderer::setTextureArrowDown ( const Texture & texture)

Changes the image that is used as the down arrow.

Parameters
textureThe new down arrow texture

When this image and the up image are set, the arrow color property will be ignored.

◆ setTextureArrowDownHover()

void tgui::SpinButtonRenderer::setTextureArrowDownHover ( const Texture & texture)

Changes the image that is used as the down arrow when the mouse is located on top of the spin button.

Parameters
textureThe new down hover arrow texture

◆ setTextureArrowUp()

void tgui::SpinButtonRenderer::setTextureArrowUp ( const Texture & texture)

Changes the image that is used as the up arrow.

Parameters
textureThe new up arrow texture

When this image and the down image are set, the arrow color property will be ignored.

◆ setTextureArrowUpHover()

void tgui::SpinButtonRenderer::setTextureArrowUpHover ( const Texture & texture)

Changes the image that is used as the up arrow when the mouse is located on top of the spin button.

Parameters
textureThe new up hover arrow texture

◆ WidgetRenderer()

tgui::WidgetRenderer::WidgetRenderer ( const std::shared_ptr< RendererData > & data)
inline

Construct the renderer from renderer data.

Parameters
dataRenderer data to initialize the renderer with

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