From bbaebdcd000db6f1de707750f0c6bc74e5b2bd95 Mon Sep 17 00:00:00 2001 From: thankyouverycool <66646555+thankyouverycool@users.noreply.github.com> Date: Wed, 22 Sep 2021 09:59:48 -0400 Subject: [PATCH] FontEditor: Keep selected glyph in view on resize --- Userland/Applications/FontEditor/GlyphMapWidget.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Userland/Applications/FontEditor/GlyphMapWidget.cpp b/Userland/Applications/FontEditor/GlyphMapWidget.cpp index 29fa63ee8a..037e2b147f 100644 --- a/Userland/Applications/FontEditor/GlyphMapWidget.cpp +++ b/Userland/Applications/FontEditor/GlyphMapWidget.cpp @@ -41,6 +41,8 @@ void GlyphMapWidget::resize_event(GUI::ResizeEvent& event) int content_height = rows() * (font().glyph_height() + m_vertical_spacing) + frame_thickness(); set_content_size({ content_width, content_height }); + scroll_to_glyph(m_selected_glyph); + AbstractScrollableWidget::resize_event(event); }