Euphoria
skin.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <memory>
4 #include <optional>
5 
6 #include "base/rgb.h"
7 #include "core/easing.h"
8 #include "io/vfs_path.h"
9 
10 
11 namespace eu::render
12 {
13  struct DrawableFont;
14 }
15 
16 namespace eu::gui
17 {
19  {
21  float time = 0.0f;
22  };
23 
24  struct ButtonState
25  {
26  // std::string image;
27  float scale = 0;
28  Rgb image_color {0.0f};
29  Rgb text_color {1.0f};
30  float dx = 0;
31  float dy = 0;
32 
36  };
37 
38 
39  struct Skin
40  {
41  Skin() = default;
42  ~Skin();
43 
44  Skin(const Skin& other) = delete;
45  void operator=(const Skin&) = delete;
46  Skin(Skin&& other) = delete;
47  void operator=(Skin&&) = delete;
48 
49  std::string name;
50 
51  std::shared_ptr<render::DrawableFont> font;
52 
53  float text_size = 30.0f;
54 
55  std::optional<io::FilePath> button_image;
56 
60  };
61 }
Definition: rgb.h:62
Interpolation interpolation_color
Definition: skin.h:34
Interpolation interpolation_size
Definition: skin.h:35
Interpolation interpolation_position
Definition: skin.h:33
core::easing::Function type
Definition: skin.h:20
Skin(Skin &&other)=delete
ButtonState button_idle
Definition: skin.h:57
void operator=(const Skin &)=delete
std::shared_ptr< render::DrawableFont > font
Definition: skin.h:51
ButtonState button_active_hot
Definition: skin.h:59
Skin()=default
float text_size
Definition: skin.h:53
void operator=(Skin &&)=delete
ButtonState button_hot
Definition: skin.h:58
Skin(const Skin &other)=delete
std::optional< io::FilePath > button_image
Definition: skin.h:55
std::string name
Definition: skin.h:49