mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 18:27:35 +00:00
Add concept of size increments to windowing system.
Use this to implement incremental resizing for Terminal so that we only ever resize to fit a perfect number of rows and columns. This is very nice. :^)
This commit is contained in:
parent
fd575055c2
commit
6084cd0c56
12 changed files with 47 additions and 4 deletions
|
@ -70,6 +70,12 @@ public:
|
|||
bool has_painted_since_last_resize() const { return m_has_painted_since_last_resize; }
|
||||
void set_has_painted_since_last_resize(bool b) { m_has_painted_since_last_resize = b; }
|
||||
|
||||
Size size_increment() const { return m_size_increment; }
|
||||
void set_size_increment(const Size& increment) { m_size_increment = increment; }
|
||||
|
||||
Size base_size() const { return m_base_size; }
|
||||
void set_base_size(const Size& size) { m_base_size = size; }
|
||||
|
||||
// For InlineLinkedList.
|
||||
// FIXME: Maybe make a ListHashSet and then WSWindowManager can just use that.
|
||||
WSWindow* m_next { nullptr };
|
||||
|
@ -89,4 +95,6 @@ private:
|
|||
int m_window_id { -1 };
|
||||
float m_opacity { 1 };
|
||||
Rect m_last_lazy_resize_rect;
|
||||
Size m_size_increment;
|
||||
Size m_base_size;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue