Loading...
Searching...
No Matches
ml::SideMenuStyle Struct Reference

#include <Malena/Traits/Style/SideMenuStyle.h>

Inheritance diagram for ml::SideMenuStyle:
[legend]

Public Types

enum class  Anchor { LEFT , RIGHT }
enum class  Mode { OVERLAY , PUSH }

Public Member Functions

SideMenuStyleapplyFrom (const Theme &t)
 Populate all fields from the global Theme token set.
sf::Color getDisabledColor () const
sf::Color getDisabledTextColor () const
sf::Color getErrorColor () const
sf::Color getFillColor () const
sf::Color getFocusColor () const
const sf::FontgetFont () const
unsigned int getFontSize () const
unsigned int getFontSizeSmall () const
sf::Color getHoverColor () const
sf::Color getMutedColor () const
sf::Color getOutlineColor () const
float getOutlineThickness () const
float getPadding () const
float getRadius () const
sf::Color getTextColor () const
SideMenuStyleoperator= (const ControlSettings &c)
SideMenuStyleoperator= (const ControlTheme &c)
SideMenuStyleoperator= (const SideMenuSettings &s)
SideMenuStyleoperator= (const SideMenuTheme &t)
void setAnchor (Anchor a)
void setAnimDuration (float d)
void setBackdropColor (const sf::Color &c)
void setDisabledColor (const sf::Color &c)
void setDisabledTextColor (const sf::Color &c)
void setErrorColor (const sf::Color &c)
void setFillColor (const sf::Color &c)
void setFocusColor (const sf::Color &c)
void setFont (const sf::Font &&)=delete
void setFont (const sf::Font &f)
void setFontSize (unsigned int s)
void setFontSizeSmall (unsigned int s)
void setHamburgerBg (const sf::Color &c)
void setHamburgerColor (const sf::Color &c)
void setHamburgerSize (float s)
void setHoverColor (const sf::Color &c)
void setMode (Mode m)
void setMutedColor (const sf::Color &c)
void setOutlineColor (const sf::Color &c)
void setOutlineThickness (float t)
void setPadding (float p)
void setPanelBg (const sf::Color &c)
void setPanelHeight (float h)
void setPanelWidth (float w)
void setRadius (float r)
void setTextColor (const sf::Color &c)

Public Attributes

Anchor anchor = Anchor::LEFT
float animDuration = 0.25f
 seconds
sf::Color backdropColor = sf::Color(0, 0, 0, 160)
sf::Color disabledColor = sf::Color(60, 60, 60)
sf::Color disabledTextColor = sf::Color(120, 120, 120)
sf::Color errorColor = sf::Color(220, 70, 70)
sf::Color fillColor = sf::Color(40, 40, 40)
sf::Color focusColor = sf::Color(100, 60, 200)
const sf::Fontfont = &FontManager<>::getDefault()
unsigned int fontSize = 14
unsigned int fontSizeSmall = 11
sf::Color hamburgerBg = sf::Color::Transparent
sf::Color hamburgerColor = sf::Color(220, 220, 220)
float hamburgerSize = 48.f
 hit-area square
sf::Color hoverColor = sf::Color(70, 130, 230)
Mode mode = Mode::OVERLAY
sf::Color mutedColor = sf::Color(120, 120, 120)
sf::Color outlineColor = sf::Color(100, 100, 100)
float outlineThickness = 1.5f
float padding = 8.f
sf::Color panelBg = sf::Color(28, 28, 36)
float panelHeight = 0.f
 0 = use window height
float panelWidth = 280.f
float radius = 8.f
sf::Color textColor = sf::Color::White

Detailed Description

Definition at line 11 of file SideMenuStyle.h.

Member Enumeration Documentation

◆ Anchor

enum class ml::SideMenuSettings::Anchor
stronginherited
Enumerator
LEFT 
RIGHT 

Definition at line 13 of file SideMenuSettings.h.

◆ Mode

enum class ml::SideMenuSettings::Mode
stronginherited
Enumerator
OVERLAY 
PUSH 

Definition at line 12 of file SideMenuSettings.h.

Member Function Documentation

◆ applyFrom()

SideMenuStyle & ml::SideMenuStyle::applyFrom ( const Theme & t)
inlinevirtual

Populate all fields from the global Theme token set.

Subclasses call GraphicTheme::applyFrom(t) first, then apply their own token mappings.

Reimplemented from ml::ControlTheme.

Definition at line 21 of file SideMenuStyle.h.

◆ getDisabledColor()

sf::Color ml::ControlTheme::getDisabledColor ( ) const
inlinenodiscardinherited

Definition at line 75 of file ControlTheme.h.

◆ getDisabledTextColor()

sf::Color ml::ControlTheme::getDisabledTextColor ( ) const
inlinenodiscardinherited

Definition at line 76 of file ControlTheme.h.

◆ getErrorColor()

sf::Color ml::ControlTheme::getErrorColor ( ) const
inlinenodiscardinherited

Definition at line 74 of file ControlTheme.h.

◆ getFillColor()

sf::Color ml::GraphicTheme::getFillColor ( ) const
inlinenodiscardinherited

Definition at line 67 of file GraphicTheme.h.

◆ getFocusColor()

sf::Color ml::ControlTheme::getFocusColor ( ) const
inlinenodiscardinherited

Definition at line 73 of file ControlTheme.h.

◆ getFont()

const sf::Font * ml::ControlTheme::getFont ( ) const
inlinenodiscardinherited

Definition at line 80 of file ControlTheme.h.

◆ getFontSize()

unsigned int ml::ControlTheme::getFontSize ( ) const
inlinenodiscardinherited

Definition at line 81 of file ControlTheme.h.

◆ getFontSizeSmall()

unsigned int ml::ControlTheme::getFontSizeSmall ( ) const
inlinenodiscardinherited

Definition at line 82 of file ControlTheme.h.

◆ getHoverColor()

sf::Color ml::ControlTheme::getHoverColor ( ) const
inlinenodiscardinherited

Definition at line 72 of file ControlTheme.h.

◆ getMutedColor()

sf::Color ml::ControlTheme::getMutedColor ( ) const
inlinenodiscardinherited

Definition at line 78 of file ControlTheme.h.

◆ getOutlineColor()

sf::Color ml::GraphicTheme::getOutlineColor ( ) const
inlinenodiscardinherited

Definition at line 68 of file GraphicTheme.h.

◆ getOutlineThickness()

float ml::GraphicTheme::getOutlineThickness ( ) const
inlinenodiscardinherited

Definition at line 69 of file GraphicTheme.h.

◆ getPadding()

float ml::ControlTheme::getPadding ( ) const
inlinenodiscardinherited

Definition at line 79 of file ControlTheme.h.

◆ getRadius()

float ml::GraphicTheme::getRadius ( ) const
inlinenodiscardinherited

Definition at line 70 of file GraphicTheme.h.

◆ getTextColor()

sf::Color ml::ControlTheme::getTextColor ( ) const
inlinenodiscardinherited

Definition at line 77 of file ControlTheme.h.

◆ operator=() [1/4]

SideMenuStyle & ml::SideMenuStyle::operator= ( const ControlSettings & c)
inline

Definition at line 19 of file SideMenuStyle.h.

◆ operator=() [2/4]

SideMenuStyle & ml::SideMenuStyle::operator= ( const ControlTheme & c)
inline

Definition at line 17 of file SideMenuStyle.h.

◆ operator=() [3/4]

SideMenuStyle & ml::SideMenuStyle::operator= ( const SideMenuSettings & s)
inline

Definition at line 13 of file SideMenuStyle.h.

◆ operator=() [4/4]

SideMenuStyle & ml::SideMenuStyle::operator= ( const SideMenuTheme & t)
inline

Definition at line 15 of file SideMenuStyle.h.

◆ setAnchor()

void ml::SideMenuSettings::setAnchor ( Anchor a)
inlineinherited

Definition at line 28 of file SideMenuSettings.h.

◆ setAnimDuration()

void ml::SideMenuSettings::setAnimDuration ( float d)
inlineinherited

Definition at line 31 of file SideMenuSettings.h.

◆ setBackdropColor()

void ml::SideMenuTheme::setBackdropColor ( const sf::Color & c)
inlineinherited

Definition at line 33 of file SideMenuTheme.h.

◆ setDisabledColor()

void ml::ControlTheme::setDisabledColor ( const sf::Color & c)
inlineinherited

Definition at line 87 of file ControlTheme.h.

◆ setDisabledTextColor()

void ml::ControlTheme::setDisabledTextColor ( const sf::Color & c)
inlineinherited

Definition at line 88 of file ControlTheme.h.

◆ setErrorColor()

void ml::ControlTheme::setErrorColor ( const sf::Color & c)
inlineinherited

Definition at line 86 of file ControlTheme.h.

◆ setFillColor()

void ml::GraphicTheme::setFillColor ( const sf::Color & c)
inlineinherited

Definition at line 72 of file GraphicTheme.h.

◆ setFocusColor()

void ml::ControlTheme::setFocusColor ( const sf::Color & c)
inlineinherited

Definition at line 85 of file ControlTheme.h.

◆ setFont() [1/2]

void ml::ControlTheme::setFont ( const sf::Font && )
deleteinherited

◆ setFont() [2/2]

void ml::ControlTheme::setFont ( const sf::Font & f)
inlineinherited

Definition at line 92 of file ControlTheme.h.

◆ setFontSize()

void ml::ControlTheme::setFontSize ( unsigned int s)
inlineinherited

Definition at line 94 of file ControlTheme.h.

◆ setFontSizeSmall()

void ml::ControlTheme::setFontSizeSmall ( unsigned int s)
inlineinherited

Definition at line 95 of file ControlTheme.h.

◆ setHamburgerBg()

void ml::SideMenuTheme::setHamburgerBg ( const sf::Color & c)
inlineinherited

Definition at line 35 of file SideMenuTheme.h.

◆ setHamburgerColor()

void ml::SideMenuTheme::setHamburgerColor ( const sf::Color & c)
inlineinherited

Definition at line 34 of file SideMenuTheme.h.

◆ setHamburgerSize()

void ml::SideMenuSettings::setHamburgerSize ( float s)
inlineinherited

Definition at line 32 of file SideMenuSettings.h.

◆ setHoverColor()

void ml::ControlTheme::setHoverColor ( const sf::Color & c)
inlineinherited

Definition at line 84 of file ControlTheme.h.

◆ setMode()

void ml::SideMenuSettings::setMode ( Mode m)
inlineinherited

Definition at line 27 of file SideMenuSettings.h.

◆ setMutedColor()

void ml::ControlTheme::setMutedColor ( const sf::Color & c)
inlineinherited

Definition at line 90 of file ControlTheme.h.

◆ setOutlineColor()

void ml::GraphicTheme::setOutlineColor ( const sf::Color & c)
inlineinherited

Definition at line 73 of file GraphicTheme.h.

◆ setOutlineThickness()

void ml::GraphicTheme::setOutlineThickness ( float t)
inlineinherited

Definition at line 74 of file GraphicTheme.h.

◆ setPadding()

void ml::ControlTheme::setPadding ( float p)
inlineinherited

Definition at line 91 of file ControlTheme.h.

◆ setPanelBg()

void ml::SideMenuTheme::setPanelBg ( const sf::Color & c)
inlineinherited

Definition at line 32 of file SideMenuTheme.h.

◆ setPanelHeight()

void ml::SideMenuSettings::setPanelHeight ( float h)
inlineinherited

Definition at line 30 of file SideMenuSettings.h.

◆ setPanelWidth()

void ml::SideMenuSettings::setPanelWidth ( float w)
inlineinherited

Definition at line 29 of file SideMenuSettings.h.

◆ setRadius()

void ml::GraphicTheme::setRadius ( float r)
inlineinherited

Definition at line 75 of file GraphicTheme.h.

◆ setTextColor()

void ml::ControlTheme::setTextColor ( const sf::Color & c)
inlineinherited

Definition at line 89 of file ControlTheme.h.

Member Data Documentation

◆ anchor

Anchor ml::SideMenuSettings::anchor = Anchor::LEFT
inherited

Definition at line 16 of file SideMenuSettings.h.

◆ animDuration

float ml::SideMenuSettings::animDuration = 0.25f
inherited

seconds

Definition at line 19 of file SideMenuSettings.h.

◆ backdropColor

sf::Color ml::SideMenuTheme::backdropColor = sf::Color(0, 0, 0, 160)
inherited

Definition at line 13 of file SideMenuTheme.h.

◆ disabledColor

sf::Color ml::ControlTheme::disabledColor = sf::Color(60, 60, 60)
inherited

Definition at line 33 of file ControlTheme.h.

◆ disabledTextColor

sf::Color ml::ControlTheme::disabledTextColor = sf::Color(120, 120, 120)
inherited

Definition at line 34 of file ControlTheme.h.

◆ errorColor

sf::Color ml::ControlTheme::errorColor = sf::Color(220, 70, 70)
inherited

Definition at line 32 of file ControlTheme.h.

◆ fillColor

sf::Color ml::GraphicTheme::fillColor = sf::Color(40, 40, 40)
inherited

Definition at line 43 of file GraphicTheme.h.

◆ focusColor

sf::Color ml::ControlTheme::focusColor = sf::Color(100, 60, 200)
inherited

Definition at line 31 of file ControlTheme.h.

◆ font

const sf::Font* ml::ControlTheme::font = &FontManager<>::getDefault()
inherited

Definition at line 39 of file ControlTheme.h.

◆ fontSize

unsigned int ml::ControlTheme::fontSize = 14
inherited

Definition at line 40 of file ControlTheme.h.

◆ fontSizeSmall

unsigned int ml::ControlTheme::fontSizeSmall = 11
inherited

Definition at line 41 of file ControlTheme.h.

◆ hamburgerBg

sf::Color ml::SideMenuTheme::hamburgerBg = sf::Color::Transparent
inherited

Definition at line 15 of file SideMenuTheme.h.

◆ hamburgerColor

sf::Color ml::SideMenuTheme::hamburgerColor = sf::Color(220, 220, 220)
inherited

Definition at line 14 of file SideMenuTheme.h.

◆ hamburgerSize

float ml::SideMenuSettings::hamburgerSize = 48.f
inherited

hit-area square

Definition at line 20 of file SideMenuSettings.h.

◆ hoverColor

sf::Color ml::ControlTheme::hoverColor = sf::Color(70, 130, 230)
inherited

Definition at line 30 of file ControlTheme.h.

◆ mode

Mode ml::SideMenuSettings::mode = Mode::OVERLAY
inherited

Definition at line 15 of file SideMenuSettings.h.

◆ mutedColor

sf::Color ml::ControlTheme::mutedColor = sf::Color(120, 120, 120)
inherited

Definition at line 36 of file ControlTheme.h.

◆ outlineColor

sf::Color ml::GraphicTheme::outlineColor = sf::Color(100, 100, 100)
inherited

Definition at line 44 of file GraphicTheme.h.

◆ outlineThickness

float ml::GraphicTheme::outlineThickness = 1.5f
inherited

Definition at line 45 of file GraphicTheme.h.

◆ padding

float ml::ControlTheme::padding = 8.f
inherited

Definition at line 37 of file ControlTheme.h.

◆ panelBg

sf::Color ml::SideMenuTheme::panelBg = sf::Color(28, 28, 36)
inherited

Definition at line 12 of file SideMenuTheme.h.

◆ panelHeight

float ml::SideMenuSettings::panelHeight = 0.f
inherited

0 = use window height

Definition at line 18 of file SideMenuSettings.h.

◆ panelWidth

float ml::SideMenuSettings::panelWidth = 280.f
inherited

Definition at line 17 of file SideMenuSettings.h.

◆ radius

float ml::GraphicTheme::radius = 8.f
inherited

Definition at line 46 of file GraphicTheme.h.

◆ textColor

sf::Color ml::ControlTheme::textColor = sf::Color::White
inherited

Definition at line 35 of file ControlTheme.h.


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