From 7d09cc6d252c970b80ed7a49f8ab2180d5a564d2 Mon Sep 17 00:00:00 2001 From: paxcut <53811119+paxcut@users.noreply.github.com> Date: Tue, 11 Mar 2025 06:56:05 -0700 Subject: [PATCH] fix: Console editor not showing all output (#2133) This change is to fix a bug reported in discord by berkus and Naheulf about the console missing output lines. The bug was caused by using SetText which replaces the existing text with the text in the argument. To fix it use InsertText which puts the text at the current cursor position that was already set to the end of the current contents. Code was tested with pattern used to reproduce the bug and seemed to work when evaluated repeatedly. --- plugins/builtin/source/content/views/view_pattern_editor.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/builtin/source/content/views/view_pattern_editor.cpp b/plugins/builtin/source/content/views/view_pattern_editor.cpp index f9daeb45a..6826a0a49 100644 --- a/plugins/builtin/source/content/views/view_pattern_editor.cpp +++ b/plugins/builtin/source/content/views/view_pattern_editor.cpp @@ -1079,7 +1079,7 @@ namespace hex::plugin::builtin { skipNewLine = false; content += m_console->at(lineCount + i); } - m_consoleEditor.SetText(content); + m_consoleEditor.InsertText(content); m_consoleNeedsUpdate = false; }