Forráskód Böngészése

LibGUI: Fix broken text rendering in TextEditor

This patch reintroduces the translation previously mistakenly removed
when adding support for different underline-styles.

Thanks for reporting the bug, kennethmyhra!
Tobias Christiansen 3 éve
szülő
commit
9a28c8dc74
1 módosított fájl, 1 hozzáadás és 0 törlés
  1. 1 0
      Userland/Libraries/LibGUI/TextEditor.cpp

+ 1 - 0
Userland/Libraries/LibGUI/TextEditor.cpp

@@ -550,6 +550,7 @@ void TextEditor::paint_event(PaintEvent& event)
                         painter.fill_rect(span_rect, text_attributes.background_color.value());
                         painter.fill_rect(span_rect, text_attributes.background_color.value());
                     }
                     }
                     draw_text(span_rect, text, *font, m_text_alignment, text_attributes);
                     draw_text(span_rect, text, *font, m_text_alignment, text_attributes);
+                    span_rect.translate_by(span_rect.width(), 0);
                 };
                 };
                 for (;;) {
                 for (;;) {
                     if (span_index >= document().spans().size()) {
                     if (span_index >= document().spans().size()) {