LibGUI: Add horizontal and vertical totals to Margins
This commit is contained in:
parent
dba6f0bc4b
commit
309874b4fb
Notes:
sideshowbarker
2024-07-17 18:08:55 +09:00
Author: https://github.com/frhun Commit: https://github.com/SerenityOS/serenity/commit/309874b4fb Pull-request: https://github.com/SerenityOS/serenity/pull/14478 Issue: https://github.com/SerenityOS/serenity/issues/14420
1 changed files with 10 additions and 0 deletions
|
@ -95,6 +95,16 @@ public:
|
|||
return m_top + m_bottom;
|
||||
}
|
||||
|
||||
[[nodiscard]] int horizontal_total() const
|
||||
{
|
||||
return m_left + m_right;
|
||||
}
|
||||
|
||||
[[nodiscard]] int vertical_total() const
|
||||
{
|
||||
return m_top + m_bottom;
|
||||
}
|
||||
|
||||
private:
|
||||
int m_top { 0 };
|
||||
int m_right { 0 };
|
||||
|
|
Loading…
Add table
Reference in a new issue