Skip to content

Commit 41e8ae3

Browse files
authored
Merge pull request #5209 from Tyriar/5206
Ensure last ligature cell is updated
2 parents b3f3cf1 + 7fab293 commit 41e8ae3

File tree

1 file changed

+4
-9
lines changed

1 file changed

+4
-9
lines changed

addons/addon-webgl/src/WebglRenderer.ts

+4-9
Original file line numberDiff line numberDiff line change
@@ -314,14 +314,6 @@ export class WebglRenderer extends Disposable implements IRenderer {
314314
this._updateCursorBlink();
315315
}
316316

317-
public registerCharacterJoiner(handler: (text: string) => [number, number][]): number {
318-
return -1;
319-
}
320-
321-
public deregisterCharacterJoiner(joinerId: number): boolean {
322-
return false;
323-
}
324-
325317
public renderRows(start: number, end: number): void {
326318
if (!this._isAttached) {
327319
if (this._coreBrowserService.window.document.body.contains(this._core.screenElement!) && this._charSizeService.width && this._charSizeService.height) {
@@ -510,14 +502,17 @@ export class WebglRenderer extends Disposable implements IRenderer {
510502
cell = this._workCell;
511503

512504
// Null out non-first cells
513-
for (x++; x < lastCharX; x++) {
505+
for (x++; x <= lastCharX; x++) {
514506
j = ((y * terminal.cols) + x) * RENDER_MODEL_INDICIES_PER_CELL;
515507
this._glyphRenderer.value!.updateCell(x, y, NULL_CELL_CODE, 0, 0, 0, NULL_CELL_CHAR, 0, 0);
516508
this._model.cells[j] = NULL_CELL_CODE;
509+
// Don't re-resolve the cell color since multi-colored ligature backgrounds are not
510+
// supported
517511
this._model.cells[j + RENDER_MODEL_BG_OFFSET] = this._cellColorResolver.result.bg;
518512
this._model.cells[j + RENDER_MODEL_FG_OFFSET] = this._cellColorResolver.result.fg;
519513
this._model.cells[j + RENDER_MODEL_EXT_OFFSET] = this._cellColorResolver.result.ext;
520514
}
515+
x--; // Go back to the previous update cell for next iteration
521516
}
522517
}
523518
}

0 commit comments

Comments
 (0)