Loading...
Searching...
No Matches
SelectSettings.h
Go to the documentation of this file.
1//
2// SelectSettings.h
3//
4
5#ifndef MALENA_SELECTSETTINGS_H
6#define MALENA_SELECTSETTINGS_H
7
8#pragma once
9
12
13namespace ml
14{
25 {
26 float itemHeight = 40.f;
27 float maxVisibleItems = 6.f;
28 unsigned int descCharSize = 11;
29
30 // ── Assignment from parent levels ─────────────────────────────────────
31
33 { static_cast<InputSettings&>(*this) = i; return *this; }
34
36 { static_cast<InputSettings&>(*this) = c; return *this; }
37
39 { static_cast<InputSettings&>(*this) = g; return *this; }
40
41 // ── Getters / setters ─────────────────────────────────────────────────
42
43 [[nodiscard]] float getItemHeight() const { return itemHeight; }
44 [[nodiscard]] float getMaxVisibleItems() const { return maxVisibleItems; }
45 [[nodiscard]] unsigned int getDescCharSize() const { return descCharSize; }
46
47 void setItemHeight(float h) { itemHeight = h; }
48 void setMaxVisibleItems(float n) { maxVisibleItems = n; }
49 void setDescCharSize(unsigned int s){ descCharSize = s; }
50 };
51
52} // namespace ml
53
54#endif // MALENA_SELECTSETTINGS_H
Definition Component.h:22
Settings trait for interactive UI controls — layout only.
Base settings trait for all visual components — geometry only.
Layout and behaviour settings shared by all input controls.
Layout and behaviour settings for Select.
float getMaxVisibleItems() const
void setDescCharSize(unsigned int s)
unsigned int getDescCharSize() const
void setItemHeight(float h)
void setMaxVisibleItems(float n)
float getItemHeight() const
SelectSettings & operator=(const ControlSettings &c)
SelectSettings & operator=(const InputSettings &i)
SelectSettings & operator=(const GraphicSettings &g)
unsigned int descCharSize