Fix graphical glitch wide chars would leave behind

Wide chars now 'own' the character next to them and are entirely responsible
for drawing and clean up
This commit is contained in:
Daniel Imms
2017-09-02 23:13:24 -07:00
parent 8427f7490d
commit fd4e9d8a1b
2 changed files with 24 additions and 2 deletions
+5
View File
@@ -128,6 +128,11 @@ export abstract class BaseRenderLayer implements IRenderLayer {
}
protected drawChar(terminal: ITerminal, char: string, code: number, width: number, x: number, y: number, fg: number, underline: boolean = false): void {
// Clear the cell next to this character if it's wide
if (width === 2) {
this.clearCells(x + 1, y, 1, 1);
}
let colorIndex = 0;
if (fg < 256) {
colorIndex = fg + 1;