Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Oberhuber2013-02-21 21:39:09 +0000
committerMartin Oberhuber2013-02-21 21:56:37 +0000
commit2e79b7eda4c02236a3a9f4c65469c8f3cb8bdabd (patch)
tree3cea766486d9a0400606a0d442c6964441e4e053
parent86973f7e4539debf6edd033b5eb4aae5c74ea558 (diff)
downloadorg.eclipse.tm-2e79b7eda4c02236a3a9f4c65469c8f3cb8bdabd.tar.gz
org.eclipse.tm-2e79b7eda4c02236a3a9f4c65469c8f3cb8bdabd.tar.xz
org.eclipse.tm-2e79b7eda4c02236a3a9f4c65469c8f3cb8bdabd.zip
[401386] Regression: No header on top due to incorrect ESC[K handling
Change-Id: I5b2b584728c8f271de4b2089c2739a5fcb86bd5b Signed-off-by: Martin Oberhuber <martin.oberhuber@windriver.com>
-rw-r--r--terminal/plugins/org.eclipse.tm.terminal/src/org/eclipse/tm/internal/terminal/emulator/VT100Emulator.java8
1 files changed, 6 insertions, 2 deletions
diff --git a/terminal/plugins/org.eclipse.tm.terminal/src/org/eclipse/tm/internal/terminal/emulator/VT100Emulator.java b/terminal/plugins/org.eclipse.tm.terminal/src/org/eclipse/tm/internal/terminal/emulator/VT100Emulator.java
index c693708e8..6c0a953eb 100644
--- a/terminal/plugins/org.eclipse.tm.terminal/src/org/eclipse/tm/internal/terminal/emulator/VT100Emulator.java
+++ b/terminal/plugins/org.eclipse.tm.terminal/src/org/eclipse/tm/internal/terminal/emulator/VT100Emulator.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2003, 2012 Wind River Systems, Inc. and others.
+ * Copyright (c) 2003, 2013 Wind River Systems, Inc. and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -18,6 +18,7 @@
* Michael Scharf (Wind River) - [262996] get rid of TerminalState.OPENED
* Martin Oberhuber (Wind River) - [334969] Fix multi-command SGR sequence
* Kris De Volder (VMWare) - [392107] Switched interpretation for ESC[0K and ESC[1K sequences
+ * Martin Oberhuber (Wind River) - [401386] Regression: No header on top due to incorrect ESC[K interpretation
*******************************************************************************/
package org.eclipse.tm.internal.terminal.emulator;
@@ -661,7 +662,10 @@ public class VT100Emulator implements ControlListener {
* moving the cursor.
*/
private void processAnsiCommand_K() {
- int ansiParameter = getAnsiParameter(0);
+ //Bug 401386: missing parameter must be interpreted as 0, and not 1 like most other defaults.
+ int ansiParameter = 0;
+ if (ansiParameters[0].length() > 0)
+ ansiParameter = getAnsiParameter(0);
switch (ansiParameter) {
case 0:

Back to the top