Wrap all characters temporarily in spans to force fixed with

Fixes #467
This commit is contained in:
Daniel Imms
2017-05-07 16:08:01 -07:00
parent 23e6a475ee
commit 3baa6b9237
3 changed files with 14 additions and 4 deletions
+9 -2
View File
@@ -283,8 +283,12 @@ export class Renderer {
}
}
// TODO: Consider performance implications of not pulling these from the pool
if (ch_width === 2) {
out += '<span class="xterm-wide-char">';
innerHTML += '<span class="xterm-wide-char">';
} else {
// TODO: Only wrap unicode characters that may vary in width
innerHTML += '<span class="xterm-normal-char">';
}
switch (ch) {
case '&':
@@ -310,7 +314,10 @@ export class Renderer {
break;
}
if (ch_width === 2) {
out += '</span>';
innerHTML += '</span>';
} else {
// TODO: Only wrap unicode characters that may vary in width
innerHTML += '</span>';
}
attr = data;