Merge from vscode 64980ea1f3f532c82bb6c28d27bba9ef2c5b4463 (#7206)

* Merge from vscode 64980ea1f3f532c82bb6c28d27bba9ef2c5b4463

* fix config changes

* fix strictnull checks
This commit is contained in:
Anthony Dresser
2019-09-15 22:38:26 -07:00
committed by GitHub
parent fa6c52699e
commit ea0f9e6ce9
1226 changed files with 21541 additions and 17633 deletions

View File

@@ -15,6 +15,7 @@ import { Color } from 'vs/base/common/color';
import { registerColor } from 'vs/platform/theme/common/colorRegistry';
import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation';
import { LinkDetector } from 'vs/workbench/contrib/debug/browser/linkDetector';
import { EditorOption } from 'vs/editor/common/config/editorOptions';
const $ = dom.$;
// theming
@@ -62,7 +63,7 @@ export class ExceptionWidget extends ZoneWidget {
protected _fillContainer(container: HTMLElement): void {
this.setCssClass('exception-widget');
// Set the font size and line height to the one from the editor configuration.
const fontInfo = this.editor.getConfiguration().fontInfo;
const fontInfo = this.editor.getOption(EditorOption.fontInfo);
container.style.fontSize = `${fontInfo.fontSize}px`;
container.style.lineHeight = `${fontInfo.lineHeight}px`;
@@ -89,7 +90,7 @@ export class ExceptionWidget extends ZoneWidget {
// Reload the height with respect to the exception text content and relayout it to match the line count.
this.container!.style.height = 'initial';
const lineHeight = this.editor.getConfiguration().lineHeight;
const lineHeight = this.editor.getOption(EditorOption.lineHeight);
const arrowHeight = Math.round(lineHeight / 3);
const computedLinesNumber = Math.ceil((this.container!.offsetHeight + arrowHeight) / lineHeight);