Skip to content

Commit

Permalink
Fix default webgl renderer
Browse files Browse the repository at this point in the history
Part of #118064
  • Loading branch information
Tyriar committed Mar 25, 2021
1 parent ab317a2 commit b70c4fe
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/vs/workbench/contrib/terminal/browser/terminalInstance.ts
Original file line number Diff line number Diff line change
Expand Up @@ -529,7 +529,9 @@ export class TerminalInstance extends Disposable implements ITerminalInstance {
this._wrapperElement.appendChild(this._xtermElement);
this._container.appendChild(this._wrapperElement);
xterm.open(this._xtermElement);
if (this._configHelper.config.rendererType === 'experimentalWebgl') {

const suggestedRendererType = this._storageService.get(SUGGESTED_RENDERER_TYPE, StorageScope.GLOBAL);
if (this._configHelper.config.rendererType === 'auto' && (suggestedRendererType === 'auto' || suggestedRendererType === undefined) || this._configHelper.config.rendererType === 'experimentalWebgl') {
this._enableWebglRenderer();
}

Expand Down Expand Up @@ -1255,7 +1257,7 @@ export class TerminalInstance extends Disposable implements ITerminalInstance {
this._safeSetOption('rightClickSelectsWord', config.rightClickBehavior === 'selectWord');
this._safeSetOption('wordSeparator', config.wordSeparators);
const suggestedRendererType = this._storageService.get(SUGGESTED_RENDERER_TYPE, StorageScope.GLOBAL);
if ((suggestedRendererType === 'auto' && config.rendererType === 'auto') || config.rendererType === 'experimentalWebgl') {
if (config.rendererType === 'auto' && (suggestedRendererType === 'auto' || suggestedRendererType === undefined) || config.rendererType === 'experimentalWebgl') {
this._enableWebglRenderer();
} else {
this._disposeOfWebglRenderer();
Expand Down

0 comments on commit b70c4fe

Please sign in to comment.