Fix non-default backgrounds on left cell of wide/overlapping chars
Fixes #1031
This commit is contained in:
@@ -224,11 +224,6 @@ export abstract class BaseRenderLayer implements IRenderLayer {
|
|||||||
* @param bold Whether the text is bold.
|
* @param bold Whether the text is bold.
|
||||||
*/
|
*/
|
||||||
protected drawChar(terminal: ITerminal, char: string, code: number, width: number, x: number, y: number, fg: number, bg: number, bold: boolean): void {
|
protected drawChar(terminal: ITerminal, char: string, code: number, width: number, x: number, y: number, fg: number, bg: number, bold: boolean): 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;
|
let colorIndex = 0;
|
||||||
if (fg < 256) {
|
if (fg < 256) {
|
||||||
colorIndex = fg + 2;
|
colorIndex = fg + 2;
|
||||||
|
|||||||
@@ -146,6 +146,11 @@ export class TextRenderLayer extends BaseRenderLayer {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Clear the cell next to this character if it's wide
|
||||||
|
if (width === 2) {
|
||||||
|
this.clearCells(x + 1, y, 1, 1);
|
||||||
|
}
|
||||||
|
|
||||||
// Draw background
|
// Draw background
|
||||||
if (bg < 256) {
|
if (bg < 256) {
|
||||||
this._ctx.save();
|
this._ctx.save();
|
||||||
|
|||||||
Reference in New Issue
Block a user