From 848a838170401b21186fbdacea6d000841e604e4 Mon Sep 17 00:00:00 2001 From: Christopher Jeffrey Date: Sat, 10 Aug 2013 17:21:57 -0500 Subject: [PATCH] optimize widechar check. --- lib/term.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/term.js b/lib/term.js index 91c92684..74a73911 100644 --- a/lib/term.js +++ b/lib/term.js @@ -1039,7 +1039,7 @@ Terminal.prototype.refresh = function(start, end) { if (ch <= ' ') { out += ' '; } else { - // if (wideChars.test(ch)) i++; + // if (ch > '\uff00' && wideChars.test(ch)) i++; out += ch; } break; @@ -1242,7 +1242,7 @@ Terminal.prototype.write = function(data) { this.x++; this.updateRange(this.y); - // if (wideChars.test(ch)) { + // if (ch > '\uff00' && wideChars.test(ch)) { // if (this.cols < 2) { // this.lines[this.y + this.ybase][this.x - 1][1] = ' '; // break;