From 7b05bf1c2016df1b0c23014e298328c23a623bc1 Mon Sep 17 00:00:00 2001 From: thankyouverycool <66646555+thankyouverycool@users.noreply.github.com> Date: Sun, 16 Apr 2023 18:35:19 -0400 Subject: [PATCH] LibGUI: Always paint Statusbar's vertical lines when not maximized Fixes MasterWord's single Statusbar::Segment not painting vertical lines despite its window being unmaximized. This was only an issue for non-resizable windows as the Statusbar resizing corner otherwise negates spans_entire_window_horizontally() when not maximized. --- Userland/Libraries/LibGUI/Statusbar.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Userland/Libraries/LibGUI/Statusbar.cpp b/Userland/Libraries/LibGUI/Statusbar.cpp index baa172dbe9..93dfaecec3 100644 --- a/Userland/Libraries/LibGUI/Statusbar.cpp +++ b/Userland/Libraries/LibGUI/Statusbar.cpp @@ -151,7 +151,8 @@ void Statusbar::Segment::paint_event(PaintEvent& event) Painter painter(*this); painter.add_clip_rect(event.rect()); - Gfx::StylePainter::current().paint_frame(painter, rect(), palette(), m_shape, Gfx::FrameShadow::Sunken, m_thickness, spans_entire_window_horizontally()); + bool skip_vertical_lines = window()->is_maximized() && spans_entire_window_horizontally(); + Gfx::StylePainter::current().paint_frame(painter, rect(), palette(), m_shape, Gfx::FrameShadow::Sunken, m_thickness, skip_vertical_lines); if (is_clickable()) Button::paint_event(event);