1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 21:17:44 +00:00

Terminal: Update window size increments on terminal font change

This fixes an issue where the window resize overlay would display
inaccurate "columns x rows" after a font change. This happened because
we kept using size increments derived from the original font.
This commit is contained in:
Andreas Kling 2022-08-14 19:22:37 +02:00
parent c3873d8709
commit 418c6eb13b

View file

@ -89,6 +89,7 @@ public:
if (font.is_null())
font = Gfx::FontDatabase::default_fixed_width_font();
m_parent_terminal.set_font_and_resize_to_fit(*font);
m_parent_terminal.apply_size_increments_to_window(*m_parent_terminal.window());
m_parent_terminal.window()->resize(m_parent_terminal.size());
} else if (group == "Cursor" && key == "Shape") {
auto cursor_shape = VT::TerminalWidget::parse_cursor_shape(value).value_or(VT::CursorShape::Block);