1
0
Fork 0
mirror of https://github.com/LadybirdBrowser/ladybird.git synced 2025-06-11 18:20:43 +09:00

LibGUI: Clip GUI::Frame children to the frame_inner_rect()

This way we don't draw the frame border underneath our children. :^)
This commit is contained in:
Andreas Kling 2020-08-25 21:25:35 +02:00
parent a265d40d6e
commit ac78531756
Notes: sideshowbarker 2024-07-19 03:09:29 +09:00
2 changed files with 8 additions and 0 deletions

View file

@ -48,6 +48,8 @@ public:
Gfx::IntRect frame_inner_rect_for_size(const Gfx::IntSize& size) const { return { m_thickness, m_thickness, size.width() - m_thickness * 2, size.height() - m_thickness * 2 }; }
Gfx::IntRect frame_inner_rect() const { return frame_inner_rect_for_size(size()); }
virtual Gfx::IntRect children_clip_rect() const override;
protected:
Frame();
void paint_event(PaintEvent&) override;