From 9d91e6c4655341bd7fbf3b57e6c2f6b15dd6b35b Mon Sep 17 00:00:00 2001 From: "Denis.Zhdanov" Date: Wed, 11 Jul 2012 15:14:42 +0400 Subject: [PATCH] IDEA-88486 Regression => Guard console is broken Corrected cached console size update on processing lines which contain \r --- .../src/com/intellij/execution/impl/ConsoleViewImpl.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/platform/lang-impl/src/com/intellij/execution/impl/ConsoleViewImpl.java b/platform/lang-impl/src/com/intellij/execution/impl/ConsoleViewImpl.java index 9ef7a9e24def..de56727d663e 100644 --- a/platform/lang-impl/src/com/intellij/execution/impl/ConsoleViewImpl.java +++ b/platform/lang-impl/src/com/intellij/execution/impl/ConsoleViewImpl.java @@ -656,6 +656,7 @@ public class ConsoleViewImpl extends JPanel implements ConsoleView, ObservableCo } if (strings.length > 0) { document.insertString(document.getTextLength(), strings[strings.length - 1]); + myContentSize -= strings.length - 1; } } finally { @@ -1574,8 +1575,8 @@ public class ConsoleViewImpl extends JPanel implements ConsoleView, ObservableCo * replace text * * @param s text for replace - * @param start relativly to all document text - * @param end relativly to all document text + * @param start relatively to all document text + * @param end relatively to all document text */ private void replaceUserText(final String s, int start, int end) { if (start == end) {