diff options
author | Andreas Kling <kling@serenityos.org> | 2020-04-24 20:30:32 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-04-24 20:42:34 +0200 |
commit | 1587b530016f73c37fb60c11c7323794967cb979 (patch) | |
tree | b3ca3070d22ac3bb41f59cc64bb9df59ab00e705 /Libraries/LibGUI/TabWidget.h | |
parent | 9d8620f9565ee5d308883b57d5f834c90b85e3dd (diff) | |
download | serenity-1587b530016f73c37fb60c11c7323794967cb979.zip |
LibGUI: Allow overriding the padding inside a TabWidget
Diffstat (limited to 'Libraries/LibGUI/TabWidget.h')
-rw-r--r-- | Libraries/LibGUI/TabWidget.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Libraries/LibGUI/TabWidget.h b/Libraries/LibGUI/TabWidget.h index b566b0f3f7..6a8f28b733 100644 --- a/Libraries/LibGUI/TabWidget.h +++ b/Libraries/LibGUI/TabWidget.h @@ -50,7 +50,9 @@ public: void set_active_widget(Widget*); int bar_height() const { return 21; } - int container_padding() const { return 2; } + + int container_padding() const { return m_container_padding; } + void set_container_padding(int padding) { m_container_padding = padding; } void add_widget(const StringView&, Widget&); void remove_widget(Widget&); @@ -100,6 +102,7 @@ private: Vector<TabData> m_tabs; TabPosition m_tab_position { TabPosition::Top }; int m_hovered_tab_index { -1 }; + int m_container_padding { 2 }; }; } |