From 2c1a417513cc0794af25625decd9b1dc79577fc3 Mon Sep 17 00:00:00 2001 From: thankyouverycool <66646555+thankyouverycool@users.noreply.github.com> Date: Wed, 2 Feb 2022 19:32:28 -0500 Subject: [PATCH] LibGUI: Fix typo in TextEditor::paint_event --- Userland/Libraries/LibGUI/TextEditor.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Userland/Libraries/LibGUI/TextEditor.cpp b/Userland/Libraries/LibGUI/TextEditor.cpp index 640624e893..8e71d1ca3f 100644 --- a/Userland/Libraries/LibGUI/TextEditor.cpp +++ b/Userland/Libraries/LibGUI/TextEditor.cpp @@ -403,8 +403,8 @@ void TextEditor::paint_event(PaintEvent& event) // NOTE: This lambda and TextEditor::text_width_for_font() are used to substitute all glyphs with m_substitution_code_point if necessary. // Painter::draw_text() and Gfx::Font::width() should not be called directly, but using this lambda and TextEditor::text_width_for_font(). - auto draw_text = [&](Gfx::IntRect const& rect, auto const& raw_text, Gfx::Font const& font, Gfx::TextAlignment alignment, Gfx::TextAttributes attributes, bool substitue = true) { - if (m_substitution_code_point && substitue) { + auto draw_text = [&](Gfx::IntRect const& rect, auto const& raw_text, Gfx::Font const& font, Gfx::TextAlignment alignment, Gfx::TextAttributes attributes, bool substitute = true) { + if (m_substitution_code_point && substitute) { painter.draw_text(rect, substitution_code_point_view(raw_text.length()), font, alignment, attributes.color); } else { painter.draw_text(rect, raw_text, font, alignment, attributes.color);