From d1dcfbc33a4042cc1ab1be7b327712e5ee3b09b6 Mon Sep 17 00:00:00 2001 From: Bruno Van de Velde Date: Sat, 7 Oct 2017 11:53:22 +0200 Subject: [PATCH] :beetle: Text could still be typed in TextBox when no scrollbar was present and the TextBox was full --- src/TGUI/Widgets/TextBox.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/TGUI/Widgets/TextBox.cpp b/src/TGUI/Widgets/TextBox.cpp index 909d2d1a..c1f4e00f 100644 --- a/src/TGUI/Widgets/TextBox.cpp +++ b/src/TGUI/Widgets/TextBox.cpp @@ -912,7 +912,7 @@ namespace tgui insert(); // Undo the insert if the text does not fit - if (oldText.getSize() + 1 != m_text.getSize()) + if (m_lines.size() > getInnerSize().y / m_lineHeight) { m_text = oldText; m_selStart = oldSelStart;