]> git.proxmox.com Git - mirror_xterm.js.git/commitdiff
Merge remote-tracking branch 'ups/master' into set_row_height_explicitly
authorDaniel Imms <daimms@microsoft.com>
Tue, 6 Jun 2017 21:34:07 +0000 (14:34 -0700)
committerDaniel Imms <daimms@microsoft.com>
Tue, 6 Jun 2017 21:34:07 +0000 (14:34 -0700)
1  2 
src/xterm.js

diff --combined src/xterm.js
index cd9f127e53406eaf1bf5b13e223f731ece4ce6be,bf359a92ef931dce6fc5467c24c25f38623ac845..3ace764ca36135be72dcfe73125d88cc11278776
@@@ -763,8 -763,7 +763,8 @@@ Terminal.loadAddon = function(addon, ca
  Terminal.prototype.updateCharSizeCSS = function() {
    this.charSizeStyleElement.textContent =
        `.xterm-wide-char{width:${this.charMeasure.width * 2}px;}` +
 -      `.xterm-normal-char{width:${this.charMeasure.width}px;}`
 +      `.xterm-normal-char{width:${this.charMeasure.width}px;}` +
 +      `.xterm-rows > div{height:${this.charMeasure.height}px;}`;
  }
  
  /**
@@@ -1253,7 -1252,13 +1253,13 @@@ Terminal.prototype.innerWrite = functio
      this.refreshStart = this.y;
      this.refreshEnd = this.y;
  
-     this.parser.parse(data);
+     // HACK: Set the parser state based on it's state at the time of return.
+     // This works around the bug #662 which saw the parser state reset in the
+     // middle of parsing escape sequence in two chunks. For some reason the
+     // state of the parser resets to 0 after exiting parser.parse. This change
+     // just sets the state back based on the correct return statement.
+     var state = this.parser.parse(data);
+     this.parser.setState(state);
  
      this.updateRange(this.y);
      this.refresh(this.refreshStart, this.refreshEnd);