diff options
author | Darin Wright | 2004-08-27 21:08:12 +0000 |
---|---|---|
committer | Darin Wright | 2004-08-27 21:08:12 +0000 |
commit | 5e0560d63622e72513067192ca82e98331e6443e (patch) | |
tree | bed20f61883778eb7ea9f7a8927cd3a9978e9cab | |
parent | 6706de437c83158c8ae29683d2c1db229ecb9927 (diff) | |
download | eclipse.platform.debug-5e0560d63622e72513067192ca82e98331e6443e.tar.gz eclipse.platform.debug-5e0560d63622e72513067192ca82e98331e6443e.tar.xz eclipse.platform.debug-5e0560d63622e72513067192ca82e98331e6443e.zip |
Bug 72167 - ProcessConsole should extend IOConsole [windows hack]
-rw-r--r-- | org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ConsoleLineNotifier.java | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ConsoleLineNotifier.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ConsoleLineNotifier.java index 0e3ca2035..834771414 100644 --- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ConsoleLineNotifier.java +++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ConsoleLineNotifier.java @@ -138,8 +138,12 @@ public class ConsoleLineNotifier implements IPatternMatchListener { IDocument document = fConsole.getDocument(); int line = document.getLineOfOffset(event.getOffset()); String delimiter = document.getLineDelimiter(line); - int delimLength = delimiter != null ? delimiter.length() : 0; - Region region = new Region(event.getOffset(), event.getLength() - delimLength); + // int delimLength = delimiter != null ? delimiter.length() : 0; + // TODO: looks like a bug in text support - on Windows, line delim is /r/n + // but the event on includes /r + String text = document.get(event.getOffset(), event.getLength()); + int delimStart = text.lastIndexOf(delimiter.charAt(0)); + Region region = new Region(event.getOffset(), delimStart); lineAppended(region); } catch (BadLocationException e) {} } |