HikoGUI
A low latency retained GUI
Loading...
Searching...
No Matches
src
TTauri
GUI
ThemeBook.hpp
1
// Copyright 2020 Pokitec
2
// All rights reserved.
3
4
#pragma once
5
6
#include "TTauri/GUI/ThemeMode.hpp"
7
#include "TTauri/GUI/Theme.hpp"
8
#include <limits>
9
#include <vector>
10
#include <new>
11
12
13
namespace
tt {
14
19
class
ThemeBook
{
20
std::vector<std::unique_ptr<Theme>
> themes;
21
std::string
_themeName;
22
ThemeMode _themeMode;
23
24
static
inline
char
const
*defaultThemeName =
"TTauri"
;
25
26
public
:
27
ThemeBook
(
std::vector<URL>
const
&theme_directories)
noexcept
;
28
29
[[nodiscard]]
std::vector<std::string>
themeNames()
const
noexcept
;
30
31
[[nodiscard]] ThemeMode themeMode()
const
noexcept
;
32
33
void
setThemeMode(ThemeMode themeMode)
noexcept
;
34
35
[[nodiscard]]
std::string
themeName()
const
noexcept
;
36
37
void
setThemeName(
std::string
const
&themeName)
noexcept
;
38
39
void
updateTheme()
noexcept
;
40
};
41
45
inline
ThemeBook
*themeBook;
46
47
}
tt::ThemeBook
ThemeBook keeps track of multiple themes.
Definition
ThemeBook.hpp:19
std::string
std::vector
Generated on Mon Apr 22 2024 12:53:56 for HikoGUI by
1.10.0