|
guillaume 2026.6.1
A C++ UI framework designed for modern desktop and extended reality (XR) applications.
|
The text styles of a theme: one TypeToken per TypeRole. More...
#include <headers/guillaume/theme/typescale.hpp>
Public Member Functions | |
| Typescale (void) | |
| Create the scale with the Material 3 baseline styles listed in TypeRole. | |
| ~Typescale (void)=default | |
| Default destructor. | |
| const TypeToken & | get (TypeRole role) const |
| Get the text style of a role. | |
| void | set (TypeRole role, const TypeToken &token) |
| Replace the text style of a role. | |
The text styles of a theme: one TypeToken per TypeRole.
Read a style through guillaume::getTypeToken. To change one, edit a copy of the theme and activate it:
Definition at line 120 of file typescale.hpp.
| guillaume::theme::Typescale::Typescale | ( | void | ) |
Create the scale with the Material 3 baseline styles listed in TypeRole.
Definition at line 59 of file typescale.cpp.

Get the text style of a role.
| role | The typescale role to look up. |
| std::out_of_range | When role is TypeRole::Count. |
Definition at line 84 of file typescale.cpp.
Replace the text style of a role.
| role | The typescale role to change. |
| token | The new style. Its font size and line height must be greater than 0. |
| std::out_of_range | When role is TypeRole::Count. |
| std::invalid_argument | When the font size or the line height is zero or negative. The role keeps its previous style. |
Definition at line 89 of file typescale.cpp.
