diff options
Diffstat (limited to 'include/gui/ScrollablePage.hpp')
-rw-r--r-- | include/gui/ScrollablePage.hpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/include/gui/ScrollablePage.hpp b/include/gui/ScrollablePage.hpp index 2ad3c92..9d4623b 100644 --- a/include/gui/ScrollablePage.hpp +++ b/include/gui/ScrollablePage.hpp @@ -12,10 +12,16 @@ namespace gsr { bool on_event(mgl::Event &event, mgl::Window &window, mgl::vec2f offset) override; void draw(mgl::Window &window, mgl::vec2f offset) override; - mgl::vec2f get_size() override { return size; } + mgl::vec2f get_size() override; + + void set_margins(float top, float bottom, float left, float right); private: - float get_border_size(mgl::Window &window) const; + float get_border_size() const; private: mgl::vec2f size; + float margin_top_scale = 0.0f; + float margin_bottom_scale = 0.0f; + float margin_left_scale = 0.0f; + float margin_right_scale = 0.0f; }; }
\ No newline at end of file |