X-Git-Url: https://git.localhorst.tv/?a=blobdiff_plain;ds=sidebyside;f=src%2Fui%2FLabel.hpp;h=7ba884b3d6d47430df5c406d05d28395a746946b;hb=a19fdf3d9f0d7ecbf6eeeec817856d85049a8336;hp=90ed738639e5761df8de90ee4a2817ab48cdc0f8;hpb=56f570e713c42d30109a214e68a2beed96ba1999;p=blobs.git diff --git a/src/ui/Label.hpp b/src/ui/Label.hpp index 90ed738..7ba884b 100644 --- a/src/ui/Label.hpp +++ b/src/ui/Label.hpp @@ -21,16 +21,16 @@ public: ~Label() override; public: - Label &Text(const std::string &); - Label &Font(const graphics::Font &); - Label &Foreground(const glm::vec4 &); - Label &Background(const glm::vec4 &); + Label *Text(const std::string &); + Label *Font(const graphics::Font &); + Label *Foreground(const glm::vec4 &); + Label *Background(const glm::vec4 &); glm::vec2 Size() override; void Draw(app::Assets &, graphics::Viewport &) noexcept override; private: - void Update(); + void FixLayout() override; private: const graphics::Font *font; @@ -38,7 +38,6 @@ private: graphics::Texture tex; glm::vec4 fg_color; glm::vec4 bg_color; - bool dirty; };