Force a sync render after resize occurs
Fixes #4922 Related microsoft/vscode#230120
This commit is contained in:
@@ -202,6 +202,9 @@ export class WebglRenderer extends Disposable implements IRenderer {
|
||||
// Force a full refresh. Resizing `_glyphRenderer` should clear it already,
|
||||
// so there is no need to clear it again here.
|
||||
this._clearModel(false);
|
||||
|
||||
// Render synchronously to avoid flicker when the canvas is cleared
|
||||
this._onRequestRedraw.fire({ start: 0, end: this._terminal.rows - 1, sync: true });
|
||||
}
|
||||
|
||||
public handleCharSizeChanged(): void {
|
||||
@@ -617,7 +620,8 @@ export class WebglRenderer extends Disposable implements IRenderer {
|
||||
// the change as it's an exact multiple of the cell sizes.
|
||||
this._canvas.width = width;
|
||||
this._canvas.height = height;
|
||||
this._requestRedrawViewport();
|
||||
// Render synchronously to avoid flicker when the canvas is cleared
|
||||
this._onRequestRedraw.fire({ start: 0, end: this._terminal.rows - 1, sync: true });
|
||||
}
|
||||
|
||||
private _requestRedrawViewport(): void {
|
||||
|
||||
Reference in New Issue
Block a user