monaco-editor-core 0.56.0-dev-20260121 → 0.56.0-dev-20260122
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm/nls.messages.cs.js +1 -1
- package/esm/nls.messages.de.js +1 -1
- package/esm/nls.messages.es.js +1 -1
- package/esm/nls.messages.fr.js +1 -1
- package/esm/nls.messages.it.js +1 -1
- package/esm/nls.messages.ja.js +1 -1
- package/esm/nls.messages.ko.js +1 -1
- package/esm/nls.messages.pl.js +1 -1
- package/esm/nls.messages.pt-br.js +1 -1
- package/esm/nls.messages.ru.js +1 -1
- package/esm/nls.messages.tr.js +1 -1
- package/esm/nls.messages.zh-cn.js +1 -1
- package/esm/nls.messages.zh-tw.js +1 -1
- package/esm/vs/base/browser/markdownRenderer.js +0 -1
- package/esm/vs/base/browser/markdownRenderer.js.map +1 -1
- package/esm/vs/base/browser/ui/codicons/codicon/codicon.ttf +0 -0
- package/esm/vs/base/common/codiconsLibrary.js +2 -0
- package/esm/vs/base/common/codiconsLibrary.js.map +1 -1
- package/esm/vs/base/common/network.js +0 -2
- package/esm/vs/base/common/network.js.map +1 -1
- package/esm/vs/editor/browser/editorBrowser.js.map +1 -1
- package/esm/vs/editor/browser/observableCodeEditor.js +41 -0
- package/esm/vs/editor/browser/observableCodeEditor.js.map +1 -1
- package/esm/vs/editor/browser/view.js +3 -0
- package/esm/vs/editor/browser/view.js.map +1 -1
- package/esm/vs/editor/browser/viewParts/viewLines/viewLine.js +14 -0
- package/esm/vs/editor/browser/viewParts/viewLines/viewLine.js.map +1 -1
- package/esm/vs/editor/browser/viewParts/viewLines/viewLines.js +7 -0
- package/esm/vs/editor/browser/viewParts/viewLines/viewLines.js.map +1 -1
- package/esm/vs/editor/browser/widget/codeEditor/codeEditorWidget.js +6 -0
- package/esm/vs/editor/browser/widget/codeEditor/codeEditorWidget.js.map +1 -1
- package/esm/vs/editor/browser/widget/multiDiffEditor/style.css +2 -41
- package/esm/vs/editor/contrib/floatingMenu/browser/floatingMenu.css +2 -1
- package/esm/vs/editor/contrib/floatingMenu/browser/floatingMenu.js +54 -45
- package/esm/vs/editor/contrib/floatingMenu/browser/floatingMenu.js.map +1 -1
- package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/components/gutterIndicatorView.js.map +1 -1
- package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/utils/utils.js +2 -8
- package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/utils/utils.js.map +1 -1
- package/esm/vs/editor/standalone/browser/services/standaloneWebWorkerService.js +2 -1
- package/esm/vs/editor/standalone/browser/services/standaloneWebWorkerService.js.map +1 -1
- package/esm/vs/platform/actionWidget/browser/actionList.js +5 -5
- package/esm/vs/platform/actionWidget/browser/actionList.js.map +1 -1
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src/vs/editor/browser/view.ts","vs/editor/browser/view.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;;;;;;;;;;AAEhG,OAAO,KAAK,GAAG,MAAM,2BAA2B,CAAC;AACjD,OAAO,EAAe,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AAEnF,OAAO,EAAE,YAAY,EAAE,MAAM,mCAAmC,CAAC;AAEjE,OAAO,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AACpF,OAAO,EAAE,UAAU,EAAE,eAAe,EAAe,MAAM,gCAAgC,CAAC;AAE1F,OAAO,EAAE,4BAA4B,EAAE,MAAM,6BAA6B,CAAC;AAC3E,OAAO,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AAEhE,OAAO,EAAqB,gBAAgB,EAA8B,MAAM,4BAA4B,CAAC;AAC7G,OAAO,EAAoB,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC5E,OAAO,EAAE,mBAAmB,EAAE,kBAAkB,EAAE,MAAM,wB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,CAAC;IAEO,OAAO;QACd,MAAM,OAAO,GAAG,IAAI,CAAC,mBAAmB,IAAI,IAAI,CAAC,+BAA+B,CAAC;QACjF,IAAI,IAAI,CAAC,SAAS,KAAK,OAAO,EAAE,CAAC;YAChC,IAAI,CAAC,SAAS,GAAG,OAAO,CAAC;YACzB,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;QAChC,CAAC;IACF,CAAC;IAEM,QAAQ;QACd,OAAO,IAAI,CAAC,SAAS,IAAI,KAAK,CAAC;IAChC,CAAC;CACD","file":"view.js","sourceRoot":"file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nimport * as dom from '../../base/browser/dom.js';\nimport { FastDomNode, createFastDomNode } from '../../base/browser/fastDomNode.js';\nimport { IMouseWheelEvent } from '../../base/browser/mouseEvent.js';\nimport { inputLatency } from '../../base/browser/performance.js';\nimport { CodeWindow } from '../../base/browser/window.js';\nimport { BugIndicatingError, onUnexpectedError } from '../../base/common/errors.js';\nimport { Disposable, DisposableStore, IDisposable } from '../../base/common/lifecycle.js';\nimport { IPointerHandlerHelper } from './controller/mouseHandler.js';\nimport { PointerHandlerLastRenderData } from './controller/mouseTarget.js';\nimport { PointerHandler } from './controller/pointerHandler.js';\nimport { IContentWidget, IContentWidgetPosition, IEditorAriaOptions, IGlyphMarginWidget, IGlyphMarginWidgetPosition, IMouseTarget, IOverlayWidget, IOverlayWidgetPosition, IViewZoneChangeAccessor } from './editorBrowser.js';\nimport { LineVisibleRanges, RenderingContext, RestrictedRenderingContext } from './view/renderingContext.js';\nimport { ICommandDelegate, ViewController } from './view/viewController.js';\nimport { ContentViewOverlays, MarginViewOverlays } from './view/viewOverlays.js';\nimport { PartFingerprint, PartFingerprints, ViewPart } from './view/viewPart.js';\nimport { ViewUserInputEvents } from './view/viewUserInputEvents.js';\nimport { BlockDecorations } from './viewParts/blockDecorations/blockDecorations.js';\nimport { ViewContentWidgets } from './viewParts/contentWidgets/contentWidgets.js';\nimport { CurrentLineHighlightOverlay, CurrentLineMarginHighlightOverlay } from './viewParts/currentLineHighlight/currentLineHighlight.js';\nimport { DecorationsOverlay } from './viewParts/decorations/decorations.js';\nimport { EditorScrollbar } from './viewParts/editorScrollbar/editorScrollbar.js';\nimport { GlyphMarginWidgets } from './viewParts/glyphMargin/glyphMargin.js';\nimport { IndentGuidesOverlay } from './viewParts/indentGuides/indentGuides.js';\nimport { LineNumbersOverlay } from './viewParts/lineNumbers/lineNumbers.js';\nimport { ViewLines } from './viewParts/viewLines/viewLines.js';\nimport { LinesDecorationsOverlay } from './viewParts/linesDecorations/linesDecorations.js';\nimport { Margin } from './viewParts/margin/margin.js';\nimport { MarginViewLineDecorationsOverlay } from './viewParts/marginDecorations/marginDecorations.js';\nimport { Minimap } from './viewParts/minimap/minimap.js';\nimport { ViewOverlayWidgets } from './viewParts/overlayWidgets/overlayWidgets.js';\nimport { DecorationsOverviewRuler } from './viewParts/overviewRuler/decorationsOverviewRuler.js';\nimport { OverviewRuler } from './viewParts/overviewRuler/overviewRuler.js';\nimport { Rulers } from './viewParts/rulers/rulers.js';\nimport { ScrollDecorationViewPart } from './viewParts/scrollDecoration/scrollDecoration.js';\nimport { SelectionsOverlay } from './viewParts/selections/selections.js';\nimport { ViewCursors } from './viewParts/viewCursors/viewCursors.js';\nimport { ViewZones } from './viewParts/viewZones/viewZones.js';\nimport { WhitespaceOverlay } from './viewParts/whitespace/whitespace.js';\nimport { IEditorConfiguration } from '../common/config/editorConfiguration.js';\nimport { EditorOption } from '../common/config/editorOptions.js';\nimport { Position } from '../common/core/position.js';\nimport { Range } from '../common/core/range.js';\nimport { Selection } from '../common/core/selection.js';\nimport { ScrollType } from '../common/editorCommon.js';\nimport { GlyphMarginLane, IGlyphMarginLanesModel } from '../common/model.js';\nimport { ViewEventHandler } from '../common/viewEventHandler.js';\nimport * as viewEvents from '../common/viewEvents.js';\nimport { ViewportData } from '../common/viewLayout/viewLinesViewportData.js';\nimport { IViewModel } from '../common/viewModel.js';\nimport { ViewContext } from '../common/viewModel/viewContext.js';\nimport { IInstantiationService } from '../../platform/instantiation/common/instantiation.js';\nimport { IColorTheme, getThemeTypeSelector } from '../../platform/theme/common/themeService.js';\nimport { ViewGpuContext } from './gpu/viewGpuContext.js';\nimport { ViewLinesGpu } from './viewParts/viewLinesGpu/viewLinesGpu.js';\nimport { AbstractEditContext } from './controller/editContext/editContext.js';\nimport { IClipboardCopyEvent, IClipboardPasteEvent } from './controller/editContext/clipboardUtils.js';\nimport { IVisibleRangeProvider, TextAreaEditContext } from './controller/editContext/textArea/textAreaEditContext.js';\nimport { NativeEditContext } from './controller/editContext/native/nativeEditContext.js';\nimport { RulersGpu } from './viewParts/rulersGpu/rulersGpu.js';\nimport { GpuMarkOverlay } from './viewParts/gpuMark/gpuMark.js';\nimport { AccessibilitySupport } from '../../platform/accessibility/common/accessibility.js';\nimport { Event, Emitter } from '../../base/common/event.js';\n\n\nexport interface IContentWidgetData {\n\twidget: IContentWidget;\n\tposition: IContentWidgetPosition | null;\n}\n\nexport interface IOverlayWidgetData {\n\twidget: IOverlayWidget;\n\tposition: IOverlayWidgetPosition | null;\n}\n\nexport interface IGlyphMarginWidgetData {\n\twidget: IGlyphMarginWidget;\n\tposition: IGlyphMarginWidgetPosition;\n}\n\nexport class View extends ViewEventHandler {\n\n\tprivate _widgetFocusTracker: CodeEditorWidgetFocusTracker;\n\n\tprivate readonly _scrollbar: EditorScrollbar;\n\tprivate readonly _context: ViewContext;\n\tprivate readonly _viewGpuContext?: ViewGpuContext;\n\tprivate _selections: Selection[];\n\n\t// The view lines\n\tprivate readonly _viewLines: ViewLines;\n\tprivate readonly _viewLinesGpu?: ViewLinesGpu;\n\n\t// These are parts, but we must do some API related calls on them, so we keep a reference\n\tprivate readonly _viewZones: ViewZones;\n\tprivate readonly _contentWidgets: ViewContentWidgets;\n\tprivate readonly _overlayWidgets: ViewOverlayWidgets;\n\tprivate readonly _glyphMarginWidgets: GlyphMarginWidgets;\n\tprivate readonly _viewCursors: ViewCursors;\n\tprivate readonly _viewParts: ViewPart[];\n\tprivate readonly _viewController: ViewController;\n\n\tprivate _editContextEnabled: boolean;\n\tprivate _accessibilitySupport: AccessibilitySupport;\n\tprivate _editContext: AbstractEditContext;\n\tprivate readonly _editContextClipboardListeners = new DisposableStore();\n\tprivate readonly _pointerHandler: PointerHandler;\n\n\t// Clipboard events relayed from editContext\n\tprivate readonly _onWillCopy = this._register(new Emitter<IClipboardCopyEvent>());\n\tpublic readonly onWillCopy: Event<IClipboardCopyEvent> = this._onWillCopy.event;\n\n\tprivate readonly _onWillCut = this._register(new Emitter<IClipboardCopyEvent>());\n\tpublic readonly onWillCut: Event<IClipboardCopyEvent> = this._onWillCut.event;\n\n\tprivate readonly _onWillPaste = this._register(new Emitter<IClipboardPasteEvent>());\n\tpublic readonly onWillPaste: Event<IClipboardPasteEvent> = this._onWillPaste.event;\n\n\t// Dom nodes\n\tprivate readonly _linesContent: FastDomNode<HTMLElement>;\n\tpublic readonly domNode: FastDomNode<HTMLElement>;\n\tprivate readonly _overflowGuardContainer: FastDomNode<HTMLElement>;\n\n\t// Actual mutable state\n\tprivate _shouldRecomputeGlyphMarginLanes: boolean = false;\n\tprivate _renderAnimationFrame: IDisposable | null;\n\tprivate _ownerID: string;\n\n\tconstructor(\n\t\teditorContainer: HTMLElement,\n\t\townerID: string,\n\t\tcommandDelegate: ICommandDelegate,\n\t\tconfiguration: IEditorConfiguration,\n\t\tcolorTheme: IColorTheme,\n\t\tmodel: IViewModel,\n\t\tuserInputEvents: ViewUserInputEvents,\n\t\toverflowWidgetsDomNode: HTMLElement | undefined,\n\t\t@IInstantiationService private readonly _instantiationService: IInstantiationService\n\t) {\n\t\tsuper();\n\t\tthis._ownerID = ownerID;\n\n\t\tthis._widgetFocusTracker = this._register(\n\t\t\tnew CodeEditorWidgetFocusTracker(editorContainer, overflowWidgetsDomNode)\n\t\t);\n\t\tthis._register(this._widgetFocusTracker.onChange(() => {\n\t\t\tthis._context.viewModel.setHasWidgetFocus(this._widgetFocusTracker.hasFocus());\n\t\t}));\n\n\t\tthis._selections = [new Selection(1, 1, 1, 1)];\n\t\tthis._renderAnimationFrame = null;\n\n\t\tthis._overflowGuardContainer = createFastDomNode(document.createElement('div'));\n\t\tPartFingerprints.write(this._overflowGuardContainer, PartFingerprint.OverflowGuard);\n\t\tthis._overflowGuardContainer.setClassName('overflow-guard');\n\n\t\tthis._viewController = new ViewController(configuration, model, userInputEvents, commandDelegate);\n\n\t\t// The view context is passed on to most classes (basically to reduce param. counts in ctors)\n\t\tthis._context = new ViewContext(configuration, colorTheme, model);\n\n\t\t// Ensure the view is the first event handler in order to update the layout\n\t\tthis._context.addEventHandler(this);\n\n\t\tthis._viewParts = [];\n\n\t\t// Keyboard handler\n\t\tthis._editContextEnabled = this._context.configuration.options.get(EditorOption.effectiveEditContext);\n\t\tthis._accessibilitySupport = this._context.configuration.options.get(EditorOption.accessibilitySupport);\n\t\tthis._editContext = this._instantiateEditContext();\n\t\tthis._connectEditContextClipboardEvents();\n\n\t\tthis._viewParts.push(this._editContext);\n\n\t\t// These two dom nodes must be constructed up front, since references are needed in the layout provider (scrolling & co.)\n\t\tthis._linesContent = createFastDomNode(document.createElement('div'));\n\t\tthis._linesContent.setClassName('lines-content' + ' monaco-editor-background');\n\t\tthis._linesContent.setPosition('absolute');\n\n\t\tthis.domNode = createFastDomNode(document.createElement('div'));\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\t// Set role 'code' for better screen reader support https://github.com/microsoft/vscode/issues/93438\n\t\tthis.domNode.setAttribute('role', 'code');\n\n\t\tif (this._context.configuration.options.get(EditorOption.experimentalGpuAcceleration) === 'on') {\n\t\t\tthis._viewGpuContext = this._instantiationService.createInstance(ViewGpuContext, this._context);\n\t\t}\n\n\t\tthis._scrollbar = new EditorScrollbar(this._context, this._linesContent, this.domNode, this._overflowGuardContainer);\n\t\tthis._viewParts.push(this._scrollbar);\n\n\t\t// View Lines\n\t\tthis._viewLines = new ViewLines(this._context, this._viewGpuContext, this._linesContent);\n\t\tif (this._viewGpuContext) {\n\t\t\tthis._viewLinesGpu = this._instantiationService.createInstance(ViewLinesGpu, this._context, this._viewGpuContext);\n\t\t}\n\n\t\t// View Zones\n\t\tthis._viewZones = new ViewZones(this._context);\n\t\tthis._viewParts.push(this._viewZones);\n\n\t\t// Decorations overview ruler\n\t\tconst decorationsOverviewRuler = new DecorationsOverviewRuler(this._context);\n\t\tthis._viewParts.push(decorationsOverviewRuler);\n\n\n\t\tconst scrollDecoration = new ScrollDecorationViewPart(this._context);\n\t\tthis._viewParts.push(scrollDecoration);\n\n\t\tconst contentViewOverlays = new ContentViewOverlays(this._context);\n\t\tthis._viewParts.push(contentViewOverlays);\n\t\tcontentViewOverlays.addDynamicOverlay(new CurrentLineHighlightOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new SelectionsOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new IndentGuidesOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new DecorationsOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new WhitespaceOverlay(this._context));\n\n\t\tconst marginViewOverlays = new MarginViewOverlays(this._context);\n\t\tthis._viewParts.push(marginViewOverlays);\n\t\tmarginViewOverlays.addDynamicOverlay(new CurrentLineMarginHighlightOverlay(this._context));\n\t\tmarginViewOverlays.addDynamicOverlay(new MarginViewLineDecorationsOverlay(this._context));\n\t\tmarginViewOverlays.addDynamicOverlay(new LinesDecorationsOverlay(this._context));\n\t\tmarginViewOverlays.addDynamicOverlay(new LineNumbersOverlay(this._context));\n\t\tif (this._viewGpuContext) {\n\t\t\tmarginViewOverlays.addDynamicOverlay(new GpuMarkOverlay(this._context, this._viewGpuContext));\n\t\t}\n\n\t\t// Glyph margin widgets\n\t\tthis._glyphMarginWidgets = new GlyphMarginWidgets(this._context);\n\t\tthis._viewParts.push(this._glyphMarginWidgets);\n\n\t\tconst margin = new Margin(this._context);\n\t\tmargin.getDomNode().appendChild(this._viewZones.marginDomNode);\n\t\tmargin.getDomNode().appendChild(marginViewOverlays.getDomNode());\n\t\tmargin.getDomNode().appendChild(this._glyphMarginWidgets.domNode);\n\t\tthis._viewParts.push(margin);\n\n\t\t// Content widgets\n\t\tthis._contentWidgets = new ViewContentWidgets(this._context, this.domNode);\n\t\tthis._viewParts.push(this._contentWidgets);\n\n\t\tthis._viewCursors = new ViewCursors(this._context);\n\t\tthis._viewParts.push(this._viewCursors);\n\n\t\t// Overlay widgets\n\t\tthis._overlayWidgets = new ViewOverlayWidgets(this._context, this.domNode);\n\t\tthis._viewParts.push(this._overlayWidgets);\n\n\t\tconst rulers = this._viewGpuContext\n\t\t\t? new RulersGpu(this._context, this._viewGpuContext)\n\t\t\t: new Rulers(this._context);\n\t\tthis._viewParts.push(rulers);\n\n\t\tconst blockOutline = new BlockDecorations(this._context);\n\t\tthis._viewParts.push(blockOutline);\n\n\t\tconst minimap = new Minimap(this._context);\n\t\tthis._viewParts.push(minimap);\n\n\t\t// -------------- Wire dom nodes up\n\n\t\tif (decorationsOverviewRuler) {\n\t\t\tconst overviewRulerData = this._scrollbar.getOverviewRulerLayoutInfo();\n\t\t\toverviewRulerData.parent.insertBefore(decorationsOverviewRuler.getDomNode(), overviewRulerData.insertBefore);\n\t\t}\n\n\t\tthis._linesContent.appendChild(contentViewOverlays.getDomNode());\n\t\tif ('domNode' in rulers) {\n\t\t\tthis._linesContent.appendChild(rulers.domNode);\n\t\t}\n\t\tthis._linesContent.appendChild(this._viewZones.domNode);\n\t\tthis._linesContent.appendChild(this._viewLines.getDomNode());\n\t\tthis._linesContent.appendChild(this._contentWidgets.domNode);\n\t\tthis._linesContent.appendChild(this._viewCursors.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(margin.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(this._scrollbar.getDomNode());\n\t\tif (this._viewGpuContext) {\n\t\t\tthis._overflowGuardContainer.appendChild(this._viewGpuContext.canvas);\n\t\t}\n\t\tthis._overflowGuardContainer.appendChild(scrollDecoration.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(this._overlayWidgets.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(minimap.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(blockOutline.domNode);\n\t\tthis.domNode.appendChild(this._overflowGuardContainer);\n\n\t\tif (overflowWidgetsDomNode) {\n\t\t\toverflowWidgetsDomNode.appendChild(this._contentWidgets.overflowingContentWidgetsDomNode.domNode);\n\t\t\toverflowWidgetsDomNode.appendChild(this._overlayWidgets.overflowingOverlayWidgetsDomNode.domNode);\n\t\t} else {\n\t\t\tthis.domNode.appendChild(this._contentWidgets.overflowingContentWidgetsDomNode);\n\t\t\tthis.domNode.appendChild(this._overlayWidgets.overflowingOverlayWidgetsDomNode);\n\t\t}\n\n\t\tthis._applyLayout();\n\n\t\t// Pointer handler\n\t\tthis._pointerHandler = this._register(new PointerHandler(this._context, this._viewController, this._createPointerHandlerHelper()));\n\t}\n\n\tprivate _instantiateEditContext(): AbstractEditContext {\n\t\tconst usingExperimentalEditContext = this._context.configuration.options.get(EditorOption.effectiveEditContext);\n\t\tif (usingExperimentalEditContext) {\n\t\t\treturn this._instantiationService.createInstance(NativeEditContext, this._ownerID, this._context, this._overflowGuardContainer, this._viewController, this._createTextAreaHandlerHelper());\n\t\t} else {\n\t\t\treturn this._instantiationService.createInstance(TextAreaEditContext, this._ownerID, this._context, this._overflowGuardContainer, this._viewController, this._createTextAreaHandlerHelper());\n\t\t}\n\t}\n\n\tprivate _updateEditContext(): void {\n\t\tconst editContextEnabled = this._context.configuration.options.get(EditorOption.effectiveEditContext);\n\t\tconst accessibilitySupport = this._context.configuration.options.get(EditorOption.accessibilitySupport);\n\t\tif (this._editContextEnabled === editContextEnabled && this._accessibilitySupport === accessibilitySupport) {\n\t\t\treturn;\n\t\t}\n\t\tthis._editContextEnabled = editContextEnabled;\n\t\tthis._accessibilitySupport = accessibilitySupport;\n\t\tconst isEditContextFocused = this._editContext.isFocused();\n\t\tconst indexOfEditContext = this._viewParts.indexOf(this._editContext);\n\t\tthis._editContext.dispose();\n\t\tthis._editContext = this._instantiateEditContext();\n\t\tthis._connectEditContextClipboardEvents();\n\t\tif (isEditContextFocused) {\n\t\t\tthis._editContext.focus();\n\t\t}\n\t\tif (indexOfEditContext !== -1) {\n\t\t\tthis._viewParts.splice(indexOfEditContext, 1, this._editContext);\n\t\t}\n\t}\n\n\tprivate _connectEditContextClipboardEvents(): void {\n\t\t// Dispose old listeners\n\t\tthis._editContextClipboardListeners.clear();\n\n\t\t// Connect to current edit context's clipboard events\n\t\tthis._editContextClipboardListeners.add(this._editContext.onWillCopy(e => this._onWillCopy.fire(e)));\n\t\tthis._editContextClipboardListeners.add(this._editContext.onWillCut(e => this._onWillCut.fire(e)));\n\t\tthis._editContextClipboardListeners.add(this._editContext.onWillPaste(e => this._onWillPaste.fire(e)));\n\t}\n\n\tprivate _computeGlyphMarginLanes(): IGlyphMarginLanesModel {\n\t\tconst model = this._context.viewModel.model;\n\t\tconst laneModel = this._context.viewModel.glyphLanes;\n\t\ttype Glyph = { range: Range; lane: GlyphMarginLane; persist?: boolean };\n\t\tlet glyphs: Glyph[] = [];\n\t\tlet maxLineNumber = 0;\n\n\t\t// Add all margin decorations\n\t\tglyphs = glyphs.concat(model.getAllMarginDecorations().map((decoration) => {\n\t\t\tconst lane = decoration.options.glyphMargin?.position ?? GlyphMarginLane.Center;\n\t\t\tmaxLineNumber = Math.max(maxLineNumber, decoration.range.endLineNumber);\n\t\t\treturn { range: decoration.range, lane, persist: decoration.options.glyphMargin?.persistLane };\n\t\t}));\n\n\t\t// Add all glyph margin widgets\n\t\tglyphs = glyphs.concat(this._glyphMarginWidgets.getWidgets().map((widget) => {\n\t\t\tconst range = model.validateRange(widget.preference.range);\n\t\t\tmaxLineNumber = Math.max(maxLineNumber, range.endLineNumber);\n\t\t\treturn { range, lane: widget.preference.lane };\n\t\t}));\n\n\t\t// Sorted by their start position\n\t\tglyphs.sort((a, b) => Range.compareRangesUsingStarts(a.range, b.range));\n\n\t\tlaneModel.reset(maxLineNumber);\n\t\tfor (const glyph of glyphs) {\n\t\t\tlaneModel.push(glyph.lane, glyph.range, glyph.persist);\n\t\t}\n\n\t\treturn laneModel;\n\t}\n\n\tprivate _createPointerHandlerHelper(): IPointerHandlerHelper {\n\t\treturn {\n\t\t\tviewDomNode: this.domNode.domNode,\n\t\t\tlinesContentDomNode: this._linesContent.domNode,\n\t\t\tviewLinesDomNode: this._viewLines.getDomNode().domNode,\n\t\t\tviewLinesGpu: this._viewLinesGpu,\n\n\t\t\tfocusTextArea: () => {\n\t\t\t\tthis.focus();\n\t\t\t},\n\n\t\t\tdispatchTextAreaEvent: (event: CustomEvent) => {\n\t\t\t\tthis._editContext.domNode.domNode.dispatchEvent(event);\n\t\t\t},\n\n\t\t\tgetLastRenderData: (): PointerHandlerLastRenderData => {\n\t\t\t\tconst lastViewCursorsRenderData = this._viewCursors.getLastRenderData() || [];\n\t\t\t\tconst lastTextareaPosition = this._editContext.getLastRenderData();\n\t\t\t\treturn new PointerHandlerLastRenderData(lastViewCursorsRenderData, lastTextareaPosition);\n\t\t\t},\n\t\t\trenderNow: (): void => {\n\t\t\t\tthis.render(true, false);\n\t\t\t},\n\t\t\tshouldSuppressMouseDownOnViewZone: (viewZoneId: string) => {\n\t\t\t\treturn this._viewZones.shouldSuppressMouseDownOnViewZone(viewZoneId);\n\t\t\t},\n\t\t\tshouldSuppressMouseDownOnWidget: (widgetId: string) => {\n\t\t\t\treturn this._contentWidgets.shouldSuppressMouseDownOnWidget(widgetId);\n\t\t\t},\n\t\t\tgetPositionFromDOMInfo: (spanNode: HTMLElement, offset: number) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\treturn this._viewLines.getPositionFromDOMInfo(spanNode, offset);\n\t\t\t},\n\n\t\t\tvisibleRangeForPosition: (lineNumber: number, column: number) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\tconst position = new Position(lineNumber, column);\n\t\t\t\treturn this._viewLines.visibleRangeForPosition(position) ?? this._viewLinesGpu?.visibleRangeForPosition(position) ?? null;\n\t\t\t},\n\n\t\t\tgetLineWidth: (lineNumber: number) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\tif (this._viewLinesGpu) {\n\t\t\t\t\tconst result = this._viewLinesGpu.getLineWidth(lineNumber);\n\t\t\t\t\tif (result !== undefined) {\n\t\t\t\t\t\treturn result;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn this._viewLines.getLineWidth(lineNumber);\n\t\t\t}\n\t\t};\n\t}\n\n\tprivate _createTextAreaHandlerHelper(): IVisibleRangeProvider {\n\t\treturn {\n\t\t\tvisibleRangeForPosition: (position: Position) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\treturn this._viewLines.visibleRangeForPosition(position);\n\t\t\t},\n\t\t\tlinesVisibleRangesForRange: (range: Range, includeNewLines: boolean): LineVisibleRanges[] | null => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\treturn this._viewLines.linesVisibleRangesForRange(range, includeNewLines);\n\t\t\t}\n\t\t};\n\t}\n\n\tprivate _applyLayout(): void {\n\t\tconst options = this._context.configuration.options;\n\t\tconst layoutInfo = options.get(EditorOption.layoutInfo);\n\n\t\tthis.domNode.setWidth(layoutInfo.width);\n\t\tthis.domNode.setHeight(layoutInfo.height);\n\n\t\tthis._overflowGuardContainer.setWidth(layoutInfo.width);\n\t\tthis._overflowGuardContainer.setHeight(layoutInfo.height);\n\n\t\t// https://stackoverflow.com/questions/38905916/content-in-google-chrome-larger-than-16777216-px-not-being-rendered\n\t\tthis._linesContent.setWidth(16777216);\n\t\tthis._linesContent.setHeight(16777216);\n\t}\n\n\tprivate _getEditorClassName() {\n\t\tconst focused = this._editContext.isFocused() ? ' focused' : '';\n\t\treturn this._context.configuration.options.get(EditorOption.editorClassName) + ' ' + getThemeTypeSelector(this._context.theme.type) + focused;\n\t}\n\n\t// --- begin event handlers\n\tpublic override handleEvents(events: viewEvents.ViewEvent[]): void {\n\t\tsuper.handleEvents(events);\n\t\tthis._scheduleRender();\n\t}\n\tpublic override onConfigurationChanged(e: viewEvents.ViewConfigurationChangedEvent): boolean {\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\tthis._updateEditContext();\n\t\tthis._applyLayout();\n\t\treturn false;\n\t}\n\tpublic override onCursorStateChanged(e: viewEvents.ViewCursorStateChangedEvent): boolean {\n\t\tthis._selections = e.selections;\n\t\treturn false;\n\t}\n\tpublic override onDecorationsChanged(e: viewEvents.ViewDecorationsChangedEvent): boolean {\n\t\tif (e.affectsGlyphMargin) {\n\t\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\t}\n\t\treturn false;\n\t}\n\tpublic override onFocusChanged(e: viewEvents.ViewFocusChangedEvent): boolean {\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\treturn false;\n\t}\n\tpublic override onThemeChanged(e: viewEvents.ViewThemeChangedEvent): boolean {\n\t\tthis._context.theme.update(e.theme);\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\treturn false;\n\t}\n\n\t// --- end event handlers\n\n\tpublic override dispose(): void {\n\t\tif (this._renderAnimationFrame !== null) {\n\t\t\tthis._renderAnimationFrame.dispose();\n\t\t\tthis._renderAnimationFrame = null;\n\t\t}\n\n\t\t// Dispose clipboard event listeners\n\t\tthis._editContextClipboardListeners.dispose();\n\n\t\tthis._contentWidgets.overflowingContentWidgetsDomNode.domNode.remove();\n\t\tthis._overlayWidgets.overflowingOverlayWidgetsDomNode.domNode.remove();\n\n\t\tthis._context.removeEventHandler(this);\n\t\tthis._viewGpuContext?.dispose();\n\n\t\tthis._viewLines.dispose();\n\t\tthis._viewLinesGpu?.dispose();\n\n\t\t// Destroy view parts\n\t\tfor (const viewPart of this._viewParts) {\n\t\t\tviewPart.dispose();\n\t\t}\n\n\t\tsuper.dispose();\n\t}\n\n\tprivate _scheduleRender(): void {\n\t\tif (this._store.isDisposed) {\n\t\t\tthrow new BugIndicatingError();\n\t\t}\n\t\tif (this._renderAnimationFrame === null) {\n\t\t\t// TODO: workaround fix for https://github.com/microsoft/vscode/issues/229825\n\t\t\tif (this._editContext instanceof NativeEditContext) {\n\t\t\t\tthis._editContext.setEditContextOnDomNode();\n\t\t\t}\n\t\t\tconst rendering = this._createCoordinatedRendering();\n\t\t\tthis._renderAnimationFrame = EditorRenderingCoordinator.INSTANCE.scheduleCoordinatedRendering({\n\t\t\t\twindow: dom.getWindow(this.domNode?.domNode),\n\t\t\t\tprepareRenderText: () => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\ttry {\n\t\t\t\t\t\treturn rendering.prepareRenderText();\n\t\t\t\t\t} finally {\n\t\t\t\t\t\tthis._renderAnimationFrame = null;\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\trenderText: () => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\treturn rendering.renderText();\n\t\t\t\t},\n\t\t\t\tprepareRender: (viewParts: ViewPart[], ctx: RenderingContext) => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\treturn rendering.prepareRender(viewParts, ctx);\n\t\t\t\t},\n\t\t\t\trender: (viewParts: ViewPart[], ctx: RestrictedRenderingContext) => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\treturn rendering.render(viewParts, ctx);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n\n\tprivate _flushAccumulatedAndRenderNow(): void {\n\t\tconst rendering = this._createCoordinatedRendering();\n\t\tsafeInvokeNoArg(() => rendering.prepareRenderText());\n\t\tconst data = safeInvokeNoArg(() => rendering.renderText());\n\t\tif (data) {\n\t\t\tconst [viewParts, ctx] = data;\n\t\t\tsafeInvokeNoArg(() => rendering.prepareRender(viewParts, ctx));\n\t\t\tsafeInvokeNoArg(() => rendering.render(viewParts, ctx));\n\t\t}\n\t}\n\n\tprivate _getViewPartsToRender(): ViewPart[] {\n\t\tconst result: ViewPart[] = [];\n\t\tlet resultLen = 0;\n\t\tfor (const viewPart of this._viewParts) {\n\t\t\tif (viewPart.shouldRender()) {\n\t\t\t\tresult[resultLen++] = viewPart;\n\t\t\t}\n\t\t}\n\t\treturn result;\n\t}\n\n\tprivate _createCoordinatedRendering() {\n\t\treturn {\n\t\t\tprepareRenderText: () => {\n\t\t\t\tif (this._shouldRecomputeGlyphMarginLanes) {\n\t\t\t\t\tthis._shouldRecomputeGlyphMarginLanes = false;\n\t\t\t\t\tconst model = this._computeGlyphMarginLanes();\n\t\t\t\t\tthis._context.configuration.setGlyphMarginDecorationLaneCount(model.requiredLanes);\n\t\t\t\t}\n\t\t\t\tinputLatency.onRenderStart();\n\t\t\t},\n\t\t\trenderText: (): [ViewPart[], RenderingContext] | null => {\n\t\t\t\tif (!this.domNode.domNode.isConnected) {\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t\tlet viewPartsToRender = this._getViewPartsToRender();\n\t\t\t\tif (!this._viewLines.shouldRender() && viewPartsToRender.length === 0) {\n\t\t\t\t\t// Nothing to render\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t\tconst partialViewportData = this._context.viewLayout.getLinesViewportData();\n\t\t\t\tthis._context.viewModel.setViewport(partialViewportData.startLineNumber, partialViewportData.endLineNumber, partialViewportData.centeredLineNumber);\n\n\t\t\t\tconst viewportData = new ViewportData(\n\t\t\t\t\tthis._selections,\n\t\t\t\t\tpartialViewportData,\n\t\t\t\t\tthis._context.viewLayout.getWhitespaceViewportData(),\n\t\t\t\t\tthis._context.viewModel\n\t\t\t\t);\n\n\t\t\t\tif (this._contentWidgets.shouldRender()) {\n\t\t\t\t\t// Give the content widgets a chance to set their max width before a possible synchronous layout\n\t\t\t\t\tthis._contentWidgets.onBeforeRender(viewportData);\n\t\t\t\t}\n\n\t\t\t\tif (this._viewLines.shouldRender()) {\n\t\t\t\t\tthis._viewLines.renderText(viewportData);\n\t\t\t\t\tthis._viewLines.onDidRender();\n\n\t\t\t\t\t// Rendering of viewLines might cause scroll events to occur, so collect view parts to render again\n\t\t\t\t\tviewPartsToRender = this._getViewPartsToRender();\n\t\t\t\t}\n\n\t\t\t\tif (this._viewLinesGpu?.shouldRender()) {\n\t\t\t\t\tthis._viewLinesGpu.renderText(viewportData);\n\t\t\t\t\tthis._viewLinesGpu.onDidRender();\n\t\t\t\t}\n\n\t\t\t\treturn [viewPartsToRender, new RenderingContext(this._context.viewLayout, viewportData, this._viewLines, this._viewLinesGpu)];\n\t\t\t},\n\t\t\tprepareRender: (viewPartsToRender: ViewPart[], ctx: RenderingContext) => {\n\t\t\t\tfor (const viewPart of viewPartsToRender) {\n\t\t\t\t\tviewPart.prepareRender(ctx);\n\t\t\t\t}\n\t\t\t},\n\t\t\trender: (viewPartsToRender: ViewPart[], ctx: RestrictedRenderingContext) => {\n\t\t\t\tfor (const viewPart of viewPartsToRender) {\n\t\t\t\t\tviewPart.render(ctx);\n\t\t\t\t\tviewPart.onDidRender();\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t}\n\n\t// --- BEGIN CodeEditor helpers\n\n\tpublic delegateVerticalScrollbarPointerDown(browserEvent: PointerEvent): void {\n\t\tthis._scrollbar.delegateVerticalScrollbarPointerDown(browserEvent);\n\t}\n\n\tpublic delegateScrollFromMouseWheelEvent(browserEvent: IMouseWheelEvent) {\n\t\tthis._scrollbar.delegateScrollFromMouseWheelEvent(browserEvent);\n\t}\n\n\tpublic restoreState(scrollPosition: { scrollLeft: number; scrollTop: number }): void {\n\t\tthis._context.viewModel.viewLayout.setScrollPosition({\n\t\t\tscrollTop: scrollPosition.scrollTop,\n\t\t\tscrollLeft: scrollPosition.scrollLeft\n\t\t}, ScrollType.Immediate);\n\t\tthis._context.viewModel.visibleLinesStabilized();\n\t}\n\n\tpublic getOffsetForColumn(modelLineNumber: number, modelColumn: number): number {\n\t\tconst modelPosition = this._context.viewModel.model.validatePosition({\n\t\t\tlineNumber: modelLineNumber,\n\t\t\tcolumn: modelColumn\n\t\t});\n\t\tconst viewPosition = this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(modelPosition);\n\t\tthis._flushAccumulatedAndRenderNow();\n\t\tconst visibleRange = this._viewLines.visibleRangeForPosition(new Position(viewPosition.lineNumber, viewPosition.column));\n\t\tif (!visibleRange) {\n\t\t\treturn -1;\n\t\t}\n\t\treturn visibleRange.left;\n\t}\n\n\tpublic getLineWidth(modelLineNumber: number): number {\n\t\tconst model = this._context.viewModel.model;\n\t\tconst viewLine = this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(new Position(modelLineNumber, model.getLineMaxColumn(modelLineNumber))).lineNumber;\n\t\tthis._flushAccumulatedAndRenderNow();\n\t\tconst width = this._viewLines.getLineWidth(viewLine);\n\n\t\treturn width;\n\t}\n\n\tpublic getTargetAtClientPoint(clientX: number, clientY: number): IMouseTarget | null {\n\t\tconst mouseTarget = this._pointerHandler.getTargetAtClientPoint(clientX, clientY);\n\t\tif (!mouseTarget) {\n\t\t\treturn null;\n\t\t}\n\t\treturn ViewUserInputEvents.convertViewToModelMouseTarget(mouseTarget, this._context.viewModel.coordinatesConverter);\n\t}\n\n\tpublic createOverviewRuler(cssClassName: string): OverviewRuler {\n\t\treturn new OverviewRuler(this._context, cssClassName);\n\t}\n\n\tpublic change(callback: (changeAccessor: IViewZoneChangeAccessor) => unknown): void {\n\t\tthis._viewZones.changeViewZones(callback);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic render(now: boolean, everything: boolean): void {\n\t\tif (everything) {\n\t\t\t// Force everything to render...\n\t\t\tthis._viewLines.forceShouldRender();\n\t\t\tfor (const viewPart of this._viewParts) {\n\t\t\t\tviewPart.forceShouldRender();\n\t\t\t}\n\t\t}\n\t\tif (now) {\n\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t} else {\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic writeScreenReaderContent(reason: string): void {\n\t\tthis._editContext.writeScreenReaderContent(reason);\n\t}\n\n\tpublic focus(): void {\n\t\tthis._editContext.focus();\n\t}\n\n\tpublic isFocused(): boolean {\n\t\treturn this._editContext.isFocused();\n\t}\n\n\tpublic isWidgetFocused(): boolean {\n\t\treturn this._widgetFocusTracker.hasFocus();\n\t}\n\n\tpublic setAriaOptions(options: IEditorAriaOptions): void {\n\t\tthis._editContext.setAriaOptions(options);\n\t}\n\n\tpublic addContentWidget(widgetData: IContentWidgetData): void {\n\t\tthis._contentWidgets.addWidget(widgetData.widget);\n\t\tthis.layoutContentWidget(widgetData);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic layoutContentWidget(widgetData: IContentWidgetData): void {\n\t\tthis._contentWidgets.setWidgetPosition(\n\t\t\twidgetData.widget,\n\t\t\twidgetData.position?.position ?? null,\n\t\t\twidgetData.position?.secondaryPosition ?? null,\n\t\t\twidgetData.position?.preference ?? null,\n\t\t\twidgetData.position?.positionAffinity ?? null\n\t\t);\n\t\tif (this._contentWidgets.shouldRender()) {\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic removeContentWidget(widgetData: IContentWidgetData): void {\n\t\tthis._contentWidgets.removeWidget(widgetData.widget);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic addOverlayWidget(widgetData: IOverlayWidgetData): void {\n\t\tthis._overlayWidgets.addWidget(widgetData.widget);\n\t\tthis.layoutOverlayWidget(widgetData);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic layoutOverlayWidget(widgetData: IOverlayWidgetData): void {\n\t\tconst shouldRender = this._overlayWidgets.setWidgetPosition(widgetData.widget, widgetData.position);\n\t\tif (shouldRender) {\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic removeOverlayWidget(widgetData: IOverlayWidgetData): void {\n\t\tthis._overlayWidgets.removeWidget(widgetData.widget);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic addGlyphMarginWidget(widgetData: IGlyphMarginWidgetData): void {\n\t\tthis._glyphMarginWidgets.addWidget(widgetData.widget);\n\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic layoutGlyphMarginWidget(widgetData: IGlyphMarginWidgetData): void {\n\t\tconst newPreference = widgetData.position;\n\t\tconst shouldRender = this._glyphMarginWidgets.setWidgetPosition(widgetData.widget, newPreference);\n\t\tif (shouldRender) {\n\t\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic removeGlyphMarginWidget(widgetData: IGlyphMarginWidgetData): void {\n\t\tthis._glyphMarginWidgets.removeWidget(widgetData.widget);\n\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\tthis._scheduleRender();\n\t}\n\n\t// --- END CodeEditor helpers\n\n}\n\nfunction safeInvokeNoArg<T>(func: () => T): T | null {\n\ttry {\n\t\treturn func();\n\t} catch (e) {\n\t\tonUnexpectedError(e);\n\t\treturn null;\n\t}\n}\n\ninterface ICoordinatedRendering {\n\treadonly window: CodeWindow;\n\tprepareRenderText(): void;\n\trenderText(): [ViewPart[], RenderingContext] | null;\n\tprepareRender(viewParts: ViewPart[], ctx: RenderingContext): void;\n\trender(viewParts: ViewPart[], ctx: RestrictedRenderingContext): void;\n}\n\nclass EditorRenderingCoordinator {\n\n\tpublic static INSTANCE = new EditorRenderingCoordinator();\n\n\tprivate _coordinatedRenderings: ICoordinatedRendering[] = [];\n\tprivate _animationFrameRunners = new Map<CodeWindow, IDisposable>();\n\n\tprivate constructor() { }\n\n\tscheduleCoordinatedRendering(rendering: ICoordinatedRendering): IDisposable {\n\t\tthis._coordinatedRenderings.push(rendering);\n\t\tthis._scheduleRender(rendering.window);\n\t\treturn {\n\t\t\tdispose: () => {\n\t\t\t\tconst renderingIndex = this._coordinatedRenderings.indexOf(rendering);\n\t\t\t\tif (renderingIndex === -1) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tthis._coordinatedRenderings.splice(renderingIndex, 1);\n\n\t\t\t\tif (this._coordinatedRenderings.length === 0) {\n\t\t\t\t\t// There are no more renderings to coordinate => cancel animation frames\n\t\t\t\t\tfor (const [_, disposable] of this._animationFrameRunners) {\n\t\t\t\t\t\tdisposable.dispose();\n\t\t\t\t\t}\n\t\t\t\t\tthis._animationFrameRunners.clear();\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t}\n\n\tprivate _scheduleRender(window: CodeWindow): void {\n\t\tif (!this._animationFrameRunners.has(window)) {\n\t\t\tconst runner = () => {\n\t\t\t\tthis._animationFrameRunners.delete(window);\n\t\t\t\tthis._onRenderScheduled();\n\t\t\t};\n\t\t\tthis._animationFrameRunners.set(window, dom.runAtThisOrScheduleAtNextAnimationFrame(window, runner, 100));\n\t\t}\n\t}\n\n\tprivate _onRenderScheduled(): void {\n\t\tconst coordinatedRenderings = this._coordinatedRenderings.slice(0);\n\t\tthis._coordinatedRenderings = [];\n\n\t\tfor (const rendering of coordinatedRenderings) {\n\t\t\tsafeInvokeNoArg(() => rendering.prepareRenderText());\n\t\t}\n\n\t\tconst datas: ([ViewPart[], RenderingContext] | null)[] = [];\n\t\tfor (let i = 0, len = coordinatedRenderings.length; i < len; i++) {\n\t\t\tconst rendering = coordinatedRenderings[i];\n\t\t\tdatas[i] = safeInvokeNoArg(() => rendering.renderText());\n\t\t}\n\n\t\tfor (let i = 0, len = coordinatedRenderings.length; i < len; i++) {\n\t\t\tconst rendering = coordinatedRenderings[i];\n\t\t\tconst data = datas[i];\n\t\t\tif (!data) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst [viewParts, ctx] = data;\n\t\t\tsafeInvokeNoArg(() => rendering.prepareRender(viewParts, ctx));\n\t\t}\n\n\t\tfor (let i = 0, len = coordinatedRenderings.length; i < len; i++) {\n\t\t\tconst rendering = coordinatedRenderings[i];\n\t\t\tconst data = datas[i];\n\t\t\tif (!data) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst [viewParts, ctx] = data;\n\t\t\tsafeInvokeNoArg(() => rendering.render(viewParts, ctx));\n\t\t}\n\t}\n}\n\nclass CodeEditorWidgetFocusTracker extends Disposable {\n\n\tprivate _hasDomElementFocus: boolean;\n\tprivate readonly _domFocusTracker: dom.IFocusTracker;\n\tprivate readonly _overflowWidgetsDomNode: dom.IFocusTracker | undefined;\n\n\tprivate readonly _onChange: Emitter<void> = this._register(new Emitter<void>());\n\tpublic readonly onChange: Event<void> = this._onChange.event;\n\n\tprivate _overflowWidgetsDomNodeHasFocus: boolean;\n\n\tprivate _hadFocus: boolean | undefined = undefined;\n\n\tconstructor(domElement: HTMLElement, overflowWidgetsDomNode: HTMLElement | undefined) {\n\t\tsuper();\n\n\t\tthis._hasDomElementFocus = false;\n\t\tthis._domFocusTracker = this._register(dom.trackFocus(domElement));\n\n\t\tthis._overflowWidgetsDomNodeHasFocus = false;\n\n\t\tthis._register(this._domFocusTracker.onDidFocus(() => {\n\t\t\tthis._hasDomElementFocus = true;\n\t\t\tthis._update();\n\t\t}));\n\t\tthis._register(this._domFocusTracker.onDidBlur(() => {\n\t\t\tthis._hasDomElementFocus = false;\n\t\t\tthis._update();\n\t\t}));\n\n\t\tif (overflowWidgetsDomNode) {\n\t\t\tthis._overflowWidgetsDomNode = this._register(dom.trackFocus(overflowWidgetsDomNode));\n\t\t\tthis._register(this._overflowWidgetsDomNode.onDidFocus(() => {\n\t\t\t\tthis._overflowWidgetsDomNodeHasFocus = true;\n\t\t\t\tthis._update();\n\t\t\t}));\n\t\t\tthis._register(this._overflowWidgetsDomNode.onDidBlur(() => {\n\t\t\t\tthis._overflowWidgetsDomNodeHasFocus = false;\n\t\t\t\tthis._update();\n\t\t\t}));\n\t\t}\n\t}\n\n\tprivate _update() {\n\t\tconst focused = this._hasDomElementFocus || this._overflowWidgetsDomNodeHasFocus;\n\t\tif (this._hadFocus !== focused) {\n\t\t\tthis._hadFocus = focused;\n\t\t\tthis._onChange.fire(undefined);\n\t\t}\n\t}\n\n\tpublic hasFocus(): boolean {\n\t\treturn this._hadFocus ?? false;\n\t}\n}\n","/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nimport * as dom from '../../base/browser/dom.js';\nimport { FastDomNode, createFastDomNode } from '../../base/browser/fastDomNode.js';\nimport { IMouseWheelEvent } from '../../base/browser/mouseEvent.js';\nimport { inputLatency } from '../../base/browser/performance.js';\nimport { CodeWindow } from '../../base/browser/window.js';\nimport { BugIndicatingError, onUnexpectedError } from '../../base/common/errors.js';\nimport { Disposable, DisposableStore, IDisposable } from '../../base/common/lifecycle.js';\nimport { IPointerHandlerHelper } from './controller/mouseHandler.js';\nimport { PointerHandlerLastRenderData } from './controller/mouseTarget.js';\nimport { PointerHandler } from './controller/pointerHandler.js';\nimport { IContentWidget, IContentWidgetPosition, IEditorAriaOptions, IGlyphMarginWidget, IGlyphMarginWidgetPosition, IMouseTarget, IOverlayWidget, IOverlayWidgetPosition, IViewZoneChangeAccessor } from './editorBrowser.js';\nimport { LineVisibleRanges, RenderingContext, RestrictedRenderingContext } from './view/renderingContext.js';\nimport { ICommandDelegate, ViewController } from './view/viewController.js';\nimport { ContentViewOverlays, MarginViewOverlays } from './view/viewOverlays.js';\nimport { PartFingerprint, PartFingerprints, ViewPart } from './view/viewPart.js';\nimport { ViewUserInputEvents } from './view/viewUserInputEvents.js';\nimport { BlockDecorations } from './viewParts/blockDecorations/blockDecorations.js';\nimport { ViewContentWidgets } from './viewParts/contentWidgets/contentWidgets.js';\nimport { CurrentLineHighlightOverlay, CurrentLineMarginHighlightOverlay } from './viewParts/currentLineHighlight/currentLineHighlight.js';\nimport { DecorationsOverlay } from './viewParts/decorations/decorations.js';\nimport { EditorScrollbar } from './viewParts/editorScrollbar/editorScrollbar.js';\nimport { GlyphMarginWidgets } from './viewParts/glyphMargin/glyphMargin.js';\nimport { IndentGuidesOverlay } from './viewParts/indentGuides/indentGuides.js';\nimport { LineNumbersOverlay } from './viewParts/lineNumbers/lineNumbers.js';\nimport { ViewLines } from './viewParts/viewLines/viewLines.js';\nimport { LinesDecorationsOverlay } from './viewParts/linesDecorations/linesDecorations.js';\nimport { Margin } from './viewParts/margin/margin.js';\nimport { MarginViewLineDecorationsOverlay } from './viewParts/marginDecorations/marginDecorations.js';\nimport { Minimap } from './viewParts/minimap/minimap.js';\nimport { ViewOverlayWidgets } from './viewParts/overlayWidgets/overlayWidgets.js';\nimport { DecorationsOverviewRuler } from './viewParts/overviewRuler/decorationsOverviewRuler.js';\nimport { OverviewRuler } from './viewParts/overviewRuler/overviewRuler.js';\nimport { Rulers } from './viewParts/rulers/rulers.js';\nimport { ScrollDecorationViewPart } from './viewParts/scrollDecoration/scrollDecoration.js';\nimport { SelectionsOverlay } from './viewParts/selections/selections.js';\nimport { ViewCursors } from './viewParts/viewCursors/viewCursors.js';\nimport { ViewZones } from './viewParts/viewZones/viewZones.js';\nimport { WhitespaceOverlay } from './viewParts/whitespace/whitespace.js';\nimport { IEditorConfiguration } from '../common/config/editorConfiguration.js';\nimport { EditorOption } from '../common/config/editorOptions.js';\nimport { Position } from '../common/core/position.js';\nimport { Range } from '../common/core/range.js';\nimport { Selection } from '../common/core/selection.js';\nimport { ScrollType } from '../common/editorCommon.js';\nimport { GlyphMarginLane, IGlyphMarginLanesModel } from '../common/model.js';\nimport { ViewEventHandler } from '../common/viewEventHandler.js';\nimport * as viewEvents from '../common/viewEvents.js';\nimport { ViewportData } from '../common/viewLayout/viewLinesViewportData.js';\nimport { IViewModel } from '../common/viewModel.js';\nimport { ViewContext } from '../common/viewModel/viewContext.js';\nimport { IInstantiationService } from '../../platform/instantiation/common/instantiation.js';\nimport { IColorTheme, getThemeTypeSelector } from '../../platform/theme/common/themeService.js';\nimport { ViewGpuContext } from './gpu/viewGpuContext.js';\nimport { ViewLinesGpu } from './viewParts/viewLinesGpu/viewLinesGpu.js';\nimport { AbstractEditContext } from './controller/editContext/editContext.js';\nimport { IClipboardCopyEvent, IClipboardPasteEvent } from './controller/editContext/clipboardUtils.js';\nimport { IVisibleRangeProvider, TextAreaEditContext } from './controller/editContext/textArea/textAreaEditContext.js';\nimport { NativeEditContext } from './controller/editContext/native/nativeEditContext.js';\nimport { RulersGpu } from './viewParts/rulersGpu/rulersGpu.js';\nimport { GpuMarkOverlay } from './viewParts/gpuMark/gpuMark.js';\nimport { AccessibilitySupport } from '../../platform/accessibility/common/accessibility.js';\nimport { Event, Emitter } from '../../base/common/event.js';\n\n\nexport interface IContentWidgetData {\n\twidget: IContentWidget;\n\tposition: IContentWidgetPosition | null;\n}\n\nexport interface IOverlayWidgetData {\n\twidget: IOverlayWidget;\n\tposition: IOverlayWidgetPosition | null;\n}\n\nexport interface IGlyphMarginWidgetData {\n\twidget: IGlyphMarginWidget;\n\tposition: IGlyphMarginWidgetPosition;\n}\n\nexport class View extends ViewEventHandler {\n\n\tprivate _widgetFocusTracker: CodeEditorWidgetFocusTracker;\n\n\tprivate readonly _scrollbar: EditorScrollbar;\n\tprivate readonly _context: ViewContext;\n\tprivate readonly _viewGpuContext?: ViewGpuContext;\n\tprivate _selections: Selection[];\n\n\t// The view lines\n\tprivate readonly _viewLines: ViewLines;\n\tprivate readonly _viewLinesGpu?: ViewLinesGpu;\n\n\t// These are parts, but we must do some API related calls on them, so we keep a reference\n\tprivate readonly _viewZones: ViewZones;\n\tprivate readonly _contentWidgets: ViewContentWidgets;\n\tprivate readonly _overlayWidgets: ViewOverlayWidgets;\n\tprivate readonly _glyphMarginWidgets: GlyphMarginWidgets;\n\tprivate readonly _viewCursors: ViewCursors;\n\tprivate readonly _viewParts: ViewPart[];\n\tprivate readonly _viewController: ViewController;\n\n\tprivate _editContextEnabled: boolean;\n\tprivate _accessibilitySupport: AccessibilitySupport;\n\tprivate _editContext: AbstractEditContext;\n\tprivate readonly _editContextClipboardListeners = new DisposableStore();\n\tprivate readonly _pointerHandler: PointerHandler;\n\n\t// Clipboard events relayed from editContext\n\tprivate readonly _onWillCopy = this._register(new Emitter<IClipboardCopyEvent>());\n\tpublic readonly onWillCopy: Event<IClipboardCopyEvent> = this._onWillCopy.event;\n\n\tprivate readonly _onWillCut = this._register(new Emitter<IClipboardCopyEvent>());\n\tpublic readonly onWillCut: Event<IClipboardCopyEvent> = this._onWillCut.event;\n\n\tprivate readonly _onWillPaste = this._register(new Emitter<IClipboardPasteEvent>());\n\tpublic readonly onWillPaste: Event<IClipboardPasteEvent> = this._onWillPaste.event;\n\n\t// Dom nodes\n\tprivate readonly _linesContent: FastDomNode<HTMLElement>;\n\tpublic readonly domNode: FastDomNode<HTMLElement>;\n\tprivate readonly _overflowGuardContainer: FastDomNode<HTMLElement>;\n\n\t// Actual mutable state\n\tprivate _shouldRecomputeGlyphMarginLanes: boolean = false;\n\tprivate _renderAnimationFrame: IDisposable | null;\n\tprivate _ownerID: string;\n\n\tconstructor(\n\t\teditorContainer: HTMLElement,\n\t\townerID: string,\n\t\tcommandDelegate: ICommandDelegate,\n\t\tconfiguration: IEditorConfiguration,\n\t\tcolorTheme: IColorTheme,\n\t\tmodel: IViewModel,\n\t\tuserInputEvents: ViewUserInputEvents,\n\t\toverflowWidgetsDomNode: HTMLElement | undefined,\n\t\t@IInstantiationService private readonly _instantiationService: IInstantiationService\n\t) {\n\t\tsuper();\n\t\tthis._ownerID = ownerID;\n\n\t\tthis._widgetFocusTracker = this._register(\n\t\t\tnew CodeEditorWidgetFocusTracker(editorContainer, overflowWidgetsDomNode)\n\t\t);\n\t\tthis._register(this._widgetFocusTracker.onChange(() => {\n\t\t\tthis._context.viewModel.setHasWidgetFocus(this._widgetFocusTracker.hasFocus());\n\t\t}));\n\n\t\tthis._selections = [new Selection(1, 1, 1, 1)];\n\t\tthis._renderAnimationFrame = null;\n\n\t\tthis._overflowGuardContainer = createFastDomNode(document.createElement('div'));\n\t\tPartFingerprints.write(this._overflowGuardContainer, PartFingerprint.OverflowGuard);\n\t\tthis._overflowGuardContainer.setClassName('overflow-guard');\n\n\t\tthis._viewController = new ViewController(configuration, model, userInputEvents, commandDelegate);\n\n\t\t// The view context is passed on to most classes (basically to reduce param. counts in ctors)\n\t\tthis._context = new ViewContext(configuration, colorTheme, model);\n\n\t\t// Ensure the view is the first event handler in order to update the layout\n\t\tthis._context.addEventHandler(this);\n\n\t\tthis._viewParts = [];\n\n\t\t// Keyboard handler\n\t\tthis._editContextEnabled = this._context.configuration.options.get(EditorOption.effectiveEditContext);\n\t\tthis._accessibilitySupport = this._context.configuration.options.get(EditorOption.accessibilitySupport);\n\t\tthis._editContext = this._instantiateEditContext();\n\t\tthis._connectEditContextClipboardEvents();\n\n\t\tthis._viewParts.push(this._editContext);\n\n\t\t// These two dom nodes must be constructed up front, since references are needed in the layout provider (scrolling & co.)\n\t\tthis._linesContent = createFastDomNode(document.createElement('div'));\n\t\tthis._linesContent.setClassName('lines-content' + ' monaco-editor-background');\n\t\tthis._linesContent.setPosition('absolute');\n\n\t\tthis.domNode = createFastDomNode(document.createElement('div'));\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\t// Set role 'code' for better screen reader support https://github.com/microsoft/vscode/issues/93438\n\t\tthis.domNode.setAttribute('role', 'code');\n\n\t\tif (this._context.configuration.options.get(EditorOption.experimentalGpuAcceleration) === 'on') {\n\t\t\tthis._viewGpuContext = this._instantiationService.createInstance(ViewGpuContext, this._context);\n\t\t}\n\n\t\tthis._scrollbar = new EditorScrollbar(this._context, this._linesContent, this.domNode, this._overflowGuardContainer);\n\t\tthis._viewParts.push(this._scrollbar);\n\n\t\t// View Lines\n\t\tthis._viewLines = new ViewLines(this._context, this._viewGpuContext, this._linesContent);\n\t\tif (this._viewGpuContext) {\n\t\t\tthis._viewLinesGpu = this._instantiationService.createInstance(ViewLinesGpu, this._context, this._viewGpuContext);\n\t\t}\n\n\t\t// View Zones\n\t\tthis._viewZones = new ViewZones(this._context);\n\t\tthis._viewParts.push(this._viewZones);\n\n\t\t// Decorations overview ruler\n\t\tconst decorationsOverviewRuler = new DecorationsOverviewRuler(this._context);\n\t\tthis._viewParts.push(decorationsOverviewRuler);\n\n\n\t\tconst scrollDecoration = new ScrollDecorationViewPart(this._context);\n\t\tthis._viewParts.push(scrollDecoration);\n\n\t\tconst contentViewOverlays = new ContentViewOverlays(this._context);\n\t\tthis._viewParts.push(contentViewOverlays);\n\t\tcontentViewOverlays.addDynamicOverlay(new CurrentLineHighlightOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new SelectionsOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new IndentGuidesOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new DecorationsOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new WhitespaceOverlay(this._context));\n\n\t\tconst marginViewOverlays = new MarginViewOverlays(this._context);\n\t\tthis._viewParts.push(marginViewOverlays);\n\t\tmarginViewOverlays.addDynamicOverlay(new CurrentLineMarginHighlightOverlay(this._context));\n\t\tmarginViewOverlays.addDynamicOverlay(new MarginViewLineDecorationsOverlay(this._context));\n\t\tmarginViewOverlays.addDynamicOverlay(new LinesDecorationsOverlay(this._context));\n\t\tmarginViewOverlays.addDynamicOverlay(new LineNumbersOverlay(this._context));\n\t\tif (this._viewGpuContext) {\n\t\t\tmarginViewOverlays.addDynamicOverlay(new GpuMarkOverlay(this._context, this._viewGpuContext));\n\t\t}\n\n\t\t// Glyph margin widgets\n\t\tthis._glyphMarginWidgets = new GlyphMarginWidgets(this._context);\n\t\tthis._viewParts.push(this._glyphMarginWidgets);\n\n\t\tconst margin = new Margin(this._context);\n\t\tmargin.getDomNode().appendChild(this._viewZones.marginDomNode);\n\t\tmargin.getDomNode().appendChild(marginViewOverlays.getDomNode());\n\t\tmargin.getDomNode().appendChild(this._glyphMarginWidgets.domNode);\n\t\tthis._viewParts.push(margin);\n\n\t\t// Content widgets\n\t\tthis._contentWidgets = new ViewContentWidgets(this._context, this.domNode);\n\t\tthis._viewParts.push(this._contentWidgets);\n\n\t\tthis._viewCursors = new ViewCursors(this._context);\n\t\tthis._viewParts.push(this._viewCursors);\n\n\t\t// Overlay widgets\n\t\tthis._overlayWidgets = new ViewOverlayWidgets(this._context, this.domNode);\n\t\tthis._viewParts.push(this._overlayWidgets);\n\n\t\tconst rulers = this._viewGpuContext\n\t\t\t? new RulersGpu(this._context, this._viewGpuContext)\n\t\t\t: new Rulers(this._context);\n\t\tthis._viewParts.push(rulers);\n\n\t\tconst blockOutline = new BlockDecorations(this._context);\n\t\tthis._viewParts.push(blockOutline);\n\n\t\tconst minimap = new Minimap(this._context);\n\t\tthis._viewParts.push(minimap);\n\n\t\t// -------------- Wire dom nodes up\n\n\t\tif (decorationsOverviewRuler) {\n\t\t\tconst overviewRulerData = this._scrollbar.getOverviewRulerLayoutInfo();\n\t\t\toverviewRulerData.parent.insertBefore(decorationsOverviewRuler.getDomNode(), overviewRulerData.insertBefore);\n\t\t}\n\n\t\tthis._linesContent.appendChild(contentViewOverlays.getDomNode());\n\t\tif ('domNode' in rulers) {\n\t\t\tthis._linesContent.appendChild(rulers.domNode);\n\t\t}\n\t\tthis._linesContent.appendChild(this._viewZones.domNode);\n\t\tthis._linesContent.appendChild(this._viewLines.getDomNode());\n\t\tthis._linesContent.appendChild(this._contentWidgets.domNode);\n\t\tthis._linesContent.appendChild(this._viewCursors.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(margin.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(this._scrollbar.getDomNode());\n\t\tif (this._viewGpuContext) {\n\t\t\tthis._overflowGuardContainer.appendChild(this._viewGpuContext.canvas);\n\t\t}\n\t\tthis._overflowGuardContainer.appendChild(scrollDecoration.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(this._overlayWidgets.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(minimap.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(blockOutline.domNode);\n\t\tthis.domNode.appendChild(this._overflowGuardContainer);\n\n\t\tif (overflowWidgetsDomNode) {\n\t\t\toverflowWidgetsDomNode.appendChild(this._contentWidgets.overflowingContentWidgetsDomNode.domNode);\n\t\t\toverflowWidgetsDomNode.appendChild(this._overlayWidgets.overflowingOverlayWidgetsDomNode.domNode);\n\t\t} else {\n\t\t\tthis.domNode.appendChild(this._contentWidgets.overflowingContentWidgetsDomNode);\n\t\t\tthis.domNode.appendChild(this._overlayWidgets.overflowingOverlayWidgetsDomNode);\n\t\t}\n\n\t\tthis._applyLayout();\n\n\t\t// Pointer handler\n\t\tthis._pointerHandler = this._register(new PointerHandler(this._context, this._viewController, this._createPointerHandlerHelper()));\n\t}\n\n\tprivate _instantiateEditContext(): AbstractEditContext {\n\t\tconst usingExperimentalEditContext = this._context.configuration.options.get(EditorOption.effectiveEditContext);\n\t\tif (usingExperimentalEditContext) {\n\t\t\treturn this._instantiationService.createInstance(NativeEditContext, this._ownerID, this._context, this._overflowGuardContainer, this._viewController, this._createTextAreaHandlerHelper());\n\t\t} else {\n\t\t\treturn this._instantiationService.createInstance(TextAreaEditContext, this._ownerID, this._context, this._overflowGuardContainer, this._viewController, this._createTextAreaHandlerHelper());\n\t\t}\n\t}\n\n\tprivate _updateEditContext(): void {\n\t\tconst editContextEnabled = this._context.configuration.options.get(EditorOption.effectiveEditContext);\n\t\tconst accessibilitySupport = this._context.configuration.options.get(EditorOption.accessibilitySupport);\n\t\tif (this._editContextEnabled === editContextEnabled && this._accessibilitySupport === accessibilitySupport) {\n\t\t\treturn;\n\t\t}\n\t\tthis._editContextEnabled = editContextEnabled;\n\t\tthis._accessibilitySupport = accessibilitySupport;\n\t\tconst isEditContextFocused = this._editContext.isFocused();\n\t\tconst indexOfEditContext = this._viewParts.indexOf(this._editContext);\n\t\tthis._editContext.dispose();\n\t\tthis._editContext = this._instantiateEditContext();\n\t\tthis._connectEditContextClipboardEvents();\n\t\tif (isEditContextFocused) {\n\t\t\tthis._editContext.focus();\n\t\t}\n\t\tif (indexOfEditContext !== -1) {\n\t\t\tthis._viewParts.splice(indexOfEditContext, 1, this._editContext);\n\t\t}\n\t}\n\n\tprivate _connectEditContextClipboardEvents(): void {\n\t\t// Dispose old listeners\n\t\tthis._editContextClipboardListeners.clear();\n\n\t\t// Connect to current edit context's clipboard events\n\t\tthis._editContextClipboardListeners.add(this._editContext.onWillCopy(e => this._onWillCopy.fire(e)));\n\t\tthis._editContextClipboardListeners.add(this._editContext.onWillCut(e => this._onWillCut.fire(e)));\n\t\tthis._editContextClipboardListeners.add(this._editContext.onWillPaste(e => this._onWillPaste.fire(e)));\n\t}\n\n\tprivate _computeGlyphMarginLanes(): IGlyphMarginLanesModel {\n\t\tconst model = this._context.viewModel.model;\n\t\tconst laneModel = this._context.viewModel.glyphLanes;\n\t\ttype Glyph = { range: Range; lane: GlyphMarginLane; persist?: boolean };\n\t\tlet glyphs: Glyph[] = [];\n\t\tlet maxLineNumber = 0;\n\n\t\t// Add all margin decorations\n\t\tglyphs = glyphs.concat(model.getAllMarginDecorations().map((decoration) => {\n\t\t\tconst lane = decoration.options.glyphMargin?.position ?? GlyphMarginLane.Center;\n\t\t\tmaxLineNumber = Math.max(maxLineNumber, decoration.range.endLineNumber);\n\t\t\treturn { range: decoration.range, lane, persist: decoration.options.glyphMargin?.persistLane };\n\t\t}));\n\n\t\t// Add all glyph margin widgets\n\t\tglyphs = glyphs.concat(this._glyphMarginWidgets.getWidgets().map((widget) => {\n\t\t\tconst range = model.validateRange(widget.preference.range);\n\t\t\tmaxLineNumber = Math.max(maxLineNumber, range.endLineNumber);\n\t\t\treturn { range, lane: widget.preference.lane };\n\t\t}));\n\n\t\t// Sorted by their start position\n\t\tglyphs.sort((a, b) => Range.compareRangesUsingStarts(a.range, b.range));\n\n\t\tlaneModel.reset(maxLineNumber);\n\t\tfor (const glyph of glyphs) {\n\t\t\tlaneModel.push(glyph.lane, glyph.range, glyph.persist);\n\t\t}\n\n\t\treturn laneModel;\n\t}\n\n\tprivate _createPointerHandlerHelper(): IPointerHandlerHelper {\n\t\treturn {\n\t\t\tviewDomNode: this.domNode.domNode,\n\t\t\tlinesContentDomNode: this._linesContent.domNode,\n\t\t\tviewLinesDomNode: this._viewLines.getDomNode().domNode,\n\t\t\tviewLinesGpu: this._viewLinesGpu,\n\n\t\t\tfocusTextArea: () => {\n\t\t\t\tthis.focus();\n\t\t\t},\n\n\t\t\tdispatchTextAreaEvent: (event: CustomEvent) => {\n\t\t\t\tthis._editContext.domNode.domNode.dispatchEvent(event);\n\t\t\t},\n\n\t\t\tgetLastRenderData: (): PointerHandlerLastRenderData => {\n\t\t\t\tconst lastViewCursorsRenderData = this._viewCursors.getLastRenderData() || [];\n\t\t\t\tconst lastTextareaPosition = this._editContext.getLastRenderData();\n\t\t\t\treturn new PointerHandlerLastRenderData(lastViewCursorsRenderData, lastTextareaPosition);\n\t\t\t},\n\t\t\trenderNow: (): void => {\n\t\t\t\tthis.render(true, false);\n\t\t\t},\n\t\t\tshouldSuppressMouseDownOnViewZone: (viewZoneId: string) => {\n\t\t\t\treturn this._viewZones.shouldSuppressMouseDownOnViewZone(viewZoneId);\n\t\t\t},\n\t\t\tshouldSuppressMouseDownOnWidget: (widgetId: string) => {\n\t\t\t\treturn this._contentWidgets.shouldSuppressMouseDownOnWidget(widgetId);\n\t\t\t},\n\t\t\tgetPositionFromDOMInfo: (spanNode: HTMLElement, offset: number) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\treturn this._viewLines.getPositionFromDOMInfo(spanNode, offset);\n\t\t\t},\n\n\t\t\tvisibleRangeForPosition: (lineNumber: number, column: number) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\tconst position = new Position(lineNumber, column);\n\t\t\t\treturn this._viewLines.visibleRangeForPosition(position) ?? this._viewLinesGpu?.visibleRangeForPosition(position) ?? null;\n\t\t\t},\n\n\t\t\tgetLineWidth: (lineNumber: number) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\tif (this._viewLinesGpu) {\n\t\t\t\t\tconst result = this._viewLinesGpu.getLineWidth(lineNumber);\n\t\t\t\t\tif (result !== undefined) {\n\t\t\t\t\t\treturn result;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn this._viewLines.getLineWidth(lineNumber);\n\t\t\t}\n\t\t};\n\t}\n\n\tprivate _createTextAreaHandlerHelper(): IVisibleRangeProvider {\n\t\treturn {\n\t\t\tvisibleRangeForPosition: (position: Position) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\treturn this._viewLines.visibleRangeForPosition(position);\n\t\t\t},\n\t\t\tlinesVisibleRangesForRange: (range: Range, includeNewLines: boolean): LineVisibleRanges[] | null => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\treturn this._viewLines.linesVisibleRangesForRange(range, includeNewLines);\n\t\t\t}\n\t\t};\n\t}\n\n\tprivate _applyLayout(): void {\n\t\tconst options = this._context.configuration.options;\n\t\tconst layoutInfo = options.get(EditorOption.layoutInfo);\n\n\t\tthis.domNode.setWidth(layoutInfo.width);\n\t\tthis.domNode.setHeight(layoutInfo.height);\n\n\t\tthis._overflowGuardContainer.setWidth(layoutInfo.width);\n\t\tthis._overflowGuardContainer.setHeight(layoutInfo.height);\n\n\t\t// https://stackoverflow.com/questions/38905916/content-in-google-chrome-larger-than-16777216-px-not-being-rendered\n\t\tthis._linesContent.setWidth(16777216);\n\t\tthis._linesContent.setHeight(16777216);\n\t}\n\n\tprivate _getEditorClassName() {\n\t\tconst focused = this._editContext.isFocused() ? ' focused' : '';\n\t\treturn this._context.configuration.options.get(EditorOption.editorClassName) + ' ' + getThemeTypeSelector(this._context.theme.type) + focused;\n\t}\n\n\t// --- begin event handlers\n\tpublic override handleEvents(events: viewEvents.ViewEvent[]): void {\n\t\tsuper.handleEvents(events);\n\t\tthis._scheduleRender();\n\t}\n\tpublic override onConfigurationChanged(e: viewEvents.ViewConfigurationChangedEvent): boolean {\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\tthis._updateEditContext();\n\t\tthis._applyLayout();\n\t\treturn false;\n\t}\n\tpublic override onCursorStateChanged(e: viewEvents.ViewCursorStateChangedEvent): boolean {\n\t\tthis._selections = e.selections;\n\t\treturn false;\n\t}\n\tpublic override onDecorationsChanged(e: viewEvents.ViewDecorationsChangedEvent): boolean {\n\t\tif (e.affectsGlyphMargin) {\n\t\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\t}\n\t\treturn false;\n\t}\n\tpublic override onFocusChanged(e: viewEvents.ViewFocusChangedEvent): boolean {\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\treturn false;\n\t}\n\tpublic override onThemeChanged(e: viewEvents.ViewThemeChangedEvent): boolean {\n\t\tthis._context.theme.update(e.theme);\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\treturn false;\n\t}\n\n\t// --- end event handlers\n\n\tpublic override dispose(): void {\n\t\tif (this._renderAnimationFrame !== null) {\n\t\t\tthis._renderAnimationFrame.dispose();\n\t\t\tthis._renderAnimationFrame = null;\n\t\t}\n\n\t\t// Dispose clipboard event listeners\n\t\tthis._editContextClipboardListeners.dispose();\n\n\t\tthis._contentWidgets.overflowingContentWidgetsDomNode.domNode.remove();\n\t\tthis._overlayWidgets.overflowingOverlayWidgetsDomNode.domNode.remove();\n\n\t\tthis._context.removeEventHandler(this);\n\t\tthis._viewGpuContext?.dispose();\n\n\t\tthis._viewLines.dispose();\n\t\tthis._viewLinesGpu?.dispose();\n\n\t\t// Destroy view parts\n\t\tfor (const viewPart of this._viewParts) {\n\t\t\tviewPart.dispose();\n\t\t}\n\n\t\tsuper.dispose();\n\t}\n\n\tprivate _scheduleRender(): void {\n\t\tif (this._store.isDisposed) {\n\t\t\tthrow new BugIndicatingError();\n\t\t}\n\t\tif (this._renderAnimationFrame === null) {\n\t\t\t// TODO: workaround fix for https://github.com/microsoft/vscode/issues/229825\n\t\t\tif (this._editContext instanceof NativeEditContext) {\n\t\t\t\tthis._editContext.setEditContextOnDomNode();\n\t\t\t}\n\t\t\tconst rendering = this._createCoordinatedRendering();\n\t\t\tthis._renderAnimationFrame = EditorRenderingCoordinator.INSTANCE.scheduleCoordinatedRendering({\n\t\t\t\twindow: dom.getWindow(this.domNode?.domNode),\n\t\t\t\tprepareRenderText: () => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\ttry {\n\t\t\t\t\t\treturn rendering.prepareRenderText();\n\t\t\t\t\t} finally {\n\t\t\t\t\t\tthis._renderAnimationFrame = null;\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\trenderText: () => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\treturn rendering.renderText();\n\t\t\t\t},\n\t\t\t\tprepareRender: (viewParts: ViewPart[], ctx: RenderingContext) => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\treturn rendering.prepareRender(viewParts, ctx);\n\t\t\t\t},\n\t\t\t\trender: (viewParts: ViewPart[], ctx: RestrictedRenderingContext) => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\treturn rendering.render(viewParts, ctx);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n\n\tprivate _flushAccumulatedAndRenderNow(): void {\n\t\tconst rendering = this._createCoordinatedRendering();\n\t\tsafeInvokeNoArg(() => rendering.prepareRenderText());\n\t\tconst data = safeInvokeNoArg(() => rendering.renderText());\n\t\tif (data) {\n\t\t\tconst [viewParts, ctx] = data;\n\t\t\tsafeInvokeNoArg(() => rendering.prepareRender(viewParts, ctx));\n\t\t\tsafeInvokeNoArg(() => rendering.render(viewParts, ctx));\n\t\t}\n\t}\n\n\tprivate _getViewPartsToRender(): ViewPart[] {\n\t\tconst result: ViewPart[] = [];\n\t\tlet resultLen = 0;\n\t\tfor (const viewPart of this._viewParts) {\n\t\t\tif (viewPart.shouldRender()) {\n\t\t\t\tresult[resultLen++] = viewPart;\n\t\t\t}\n\t\t}\n\t\treturn result;\n\t}\n\n\tprivate _createCoordinatedRendering() {\n\t\treturn {\n\t\t\tprepareRenderText: () => {\n\t\t\t\tif (this._shouldRecomputeGlyphMarginLanes) {\n\t\t\t\t\tthis._shouldRecomputeGlyphMarginLanes = false;\n\t\t\t\t\tconst model = this._computeGlyphMarginLanes();\n\t\t\t\t\tthis._context.configuration.setGlyphMarginDecorationLaneCount(model.requiredLanes);\n\t\t\t\t}\n\t\t\t\tinputLatency.onRenderStart();\n\t\t\t},\n\t\t\trenderText: (): [ViewPart[], RenderingContext] | null => {\n\t\t\t\tif (!this.domNode.domNode.isConnected) {\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t\tlet viewPartsToRender = this._getViewPartsToRender();\n\t\t\t\tif (!this._viewLines.shouldRender() && viewPartsToRender.length === 0) {\n\t\t\t\t\t// Nothing to render\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t\tconst partialViewportData = this._context.viewLayout.getLinesViewportData();\n\t\t\t\tthis._context.viewModel.setViewport(partialViewportData.startLineNumber, partialViewportData.endLineNumber, partialViewportData.centeredLineNumber);\n\n\t\t\t\tconst viewportData = new ViewportData(\n\t\t\t\t\tthis._selections,\n\t\t\t\t\tpartialViewportData,\n\t\t\t\t\tthis._context.viewLayout.getWhitespaceViewportData(),\n\t\t\t\t\tthis._context.viewModel\n\t\t\t\t);\n\n\t\t\t\tif (this._contentWidgets.shouldRender()) {\n\t\t\t\t\t// Give the content widgets a chance to set their max width before a possible synchronous layout\n\t\t\t\t\tthis._contentWidgets.onBeforeRender(viewportData);\n\t\t\t\t}\n\n\t\t\t\tif (this._viewLines.shouldRender()) {\n\t\t\t\t\tthis._viewLines.renderText(viewportData);\n\t\t\t\t\tthis._viewLines.onDidRender();\n\n\t\t\t\t\t// Rendering of viewLines might cause scroll events to occur, so collect view parts to render again\n\t\t\t\t\tviewPartsToRender = this._getViewPartsToRender();\n\t\t\t\t}\n\n\t\t\t\tif (this._viewLinesGpu?.shouldRender()) {\n\t\t\t\t\tthis._viewLinesGpu.renderText(viewportData);\n\t\t\t\t\tthis._viewLinesGpu.onDidRender();\n\t\t\t\t}\n\n\t\t\t\treturn [viewPartsToRender, new RenderingContext(this._context.viewLayout, viewportData, this._viewLines, this._viewLinesGpu)];\n\t\t\t},\n\t\t\tprepareRender: (viewPartsToRender: ViewPart[], ctx: RenderingContext) => {\n\t\t\t\tfor (const viewPart of viewPartsToRender) {\n\t\t\t\t\tviewPart.prepareRender(ctx);\n\t\t\t\t}\n\t\t\t},\n\t\t\trender: (viewPartsToRender: ViewPart[], ctx: RestrictedRenderingContext) => {\n\t\t\t\tfor (const viewPart of viewPartsToRender) {\n\t\t\t\t\tviewPart.render(ctx);\n\t\t\t\t\tviewPart.onDidRender();\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t}\n\n\t// --- BEGIN CodeEditor helpers\n\n\tpublic delegateVerticalScrollbarPointerDown(browserEvent: PointerEvent): void {\n\t\tthis._scrollbar.delegateVerticalScrollbarPointerDown(browserEvent);\n\t}\n\n\tpublic delegateScrollFromMouseWheelEvent(browserEvent: IMouseWheelEvent) {\n\t\tthis._scrollbar.delegateScrollFromMouseWheelEvent(browserEvent);\n\t}\n\n\tpublic restoreState(scrollPosition: { scrollLeft: number; scrollTop: number }): void {\n\t\tthis._context.viewModel.viewLayout.setScrollPosition({\n\t\t\tscrollTop: scrollPosition.scrollTop,\n\t\t\tscrollLeft: scrollPosition.scrollLeft\n\t\t}, ScrollType.Immediate);\n\t\tthis._context.viewModel.visibleLinesStabilized();\n\t}\n\n\tpublic getOffsetForColumn(modelLineNumber: number, modelColumn: number): number {\n\t\tconst modelPosition = this._context.viewModel.model.validatePosition({\n\t\t\tlineNumber: modelLineNumber,\n\t\t\tcolumn: modelColumn\n\t\t});\n\t\tconst viewPosition = this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(modelPosition);\n\t\tthis._flushAccumulatedAndRenderNow();\n\t\tconst visibleRange = this._viewLines.visibleRangeForPosition(new Position(viewPosition.lineNumber, viewPosition.column));\n\t\tif (!visibleRange) {\n\t\t\treturn -1;\n\t\t}\n\t\treturn visibleRange.left;\n\t}\n\n\tpublic getLineWidth(modelLineNumber: number): number {\n\t\tconst model = this._context.viewModel.model;\n\t\tconst viewLine = this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(new Position(modelLineNumber, model.getLineMaxColumn(modelLineNumber))).lineNumber;\n\t\tthis._flushAccumulatedAndRenderNow();\n\t\tconst width = this._viewLines.getLineWidth(viewLine);\n\n\t\treturn width;\n\t}\n\n\tpublic getTargetAtClientPoint(clientX: number, clientY: number): IMouseTarget | null {\n\t\tconst mouseTarget = this._pointerHandler.getTargetAtClientPoint(clientX, clientY);\n\t\tif (!mouseTarget) {\n\t\t\treturn null;\n\t\t}\n\t\treturn ViewUserInputEvents.convertViewToModelMouseTarget(mouseTarget, this._context.viewModel.coordinatesConverter);\n\t}\n\n\tpublic createOverviewRuler(cssClassName: string): OverviewRuler {\n\t\treturn new OverviewRuler(this._context, cssClassName);\n\t}\n\n\tpublic change(callback: (changeAccessor: IViewZoneChangeAccessor) => unknown): void {\n\t\tthis._viewZones.changeViewZones(callback);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic render(now: boolean, everything: boolean): void {\n\t\tif (everything) {\n\t\t\t// Force everything to render...\n\t\t\tthis._viewLines.forceShouldRender();\n\t\t\tfor (const viewPart of this._viewParts) {\n\t\t\t\tviewPart.forceShouldRender();\n\t\t\t}\n\t\t}\n\t\tif (now) {\n\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t} else {\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic writeScreenReaderContent(reason: string): void {\n\t\tthis._editContext.writeScreenReaderContent(reason);\n\t}\n\n\tpublic focus(): void {\n\t\tthis._editContext.focus();\n\t}\n\n\tpublic isFocused(): boolean {\n\t\treturn this._editContext.isFocused();\n\t}\n\n\tpublic isWidgetFocused(): boolean {\n\t\treturn this._widgetFocusTracker.hasFocus();\n\t}\n\n\tpublic setAriaOptions(options: IEditorAriaOptions): void {\n\t\tthis._editContext.setAriaOptions(options);\n\t}\n\n\tpublic addContentWidget(widgetData: IContentWidgetData): void {\n\t\tthis._contentWidgets.addWidget(widgetData.widget);\n\t\tthis.layoutContentWidget(widgetData);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic layoutContentWidget(widgetData: IContentWidgetData): void {\n\t\tthis._contentWidgets.setWidgetPosition(\n\t\t\twidgetData.widget,\n\t\t\twidgetData.position?.position ?? null,\n\t\t\twidgetData.position?.secondaryPosition ?? null,\n\t\t\twidgetData.position?.preference ?? null,\n\t\t\twidgetData.position?.positionAffinity ?? null\n\t\t);\n\t\tif (this._contentWidgets.shouldRender()) {\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic removeContentWidget(widgetData: IContentWidgetData): void {\n\t\tthis._contentWidgets.removeWidget(widgetData.widget);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic addOverlayWidget(widgetData: IOverlayWidgetData): void {\n\t\tthis._overlayWidgets.addWidget(widgetData.widget);\n\t\tthis.layoutOverlayWidget(widgetData);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic layoutOverlayWidget(widgetData: IOverlayWidgetData): void {\n\t\tconst shouldRender = this._overlayWidgets.setWidgetPosition(widgetData.widget, widgetData.position);\n\t\tif (shouldRender) {\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic removeOverlayWidget(widgetData: IOverlayWidgetData): void {\n\t\tthis._overlayWidgets.removeWidget(widgetData.widget);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic addGlyphMarginWidget(widgetData: IGlyphMarginWidgetData): void {\n\t\tthis._glyphMarginWidgets.addWidget(widgetData.widget);\n\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic layoutGlyphMarginWidget(widgetData: IGlyphMarginWidgetData): void {\n\t\tconst newPreference = widgetData.position;\n\t\tconst shouldRender = this._glyphMarginWidgets.setWidgetPosition(widgetData.widget, newPreference);\n\t\tif (shouldRender) {\n\t\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic removeGlyphMarginWidget(widgetData: IGlyphMarginWidgetData): void {\n\t\tthis._glyphMarginWidgets.removeWidget(widgetData.widget);\n\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\tthis._scheduleRender();\n\t}\n\n\t// --- END CodeEditor helpers\n\n}\n\nfunction safeInvokeNoArg<T>(func: () => T): T | null {\n\ttry {\n\t\treturn func();\n\t} catch (e) {\n\t\tonUnexpectedError(e);\n\t\treturn null;\n\t}\n}\n\ninterface ICoordinatedRendering {\n\treadonly window: CodeWindow;\n\tprepareRenderText(): void;\n\trenderText(): [ViewPart[], RenderingContext] | null;\n\tprepareRender(viewParts: ViewPart[], ctx: RenderingContext): void;\n\trender(viewParts: ViewPart[], ctx: RestrictedRenderingContext): void;\n}\n\nclass EditorRenderingCoordinator {\n\n\tpublic static INSTANCE = new EditorRenderingCoordinator();\n\n\tprivate _coordinatedRenderings: ICoordinatedRendering[] = [];\n\tprivate _animationFrameRunners = new Map<CodeWindow, IDisposable>();\n\n\tprivate constructor() { }\n\n\tscheduleCoordinatedRendering(rendering: ICoordinatedRendering): IDisposable {\n\t\tthis._coordinatedRenderings.push(rendering);\n\t\tthis._scheduleRender(rendering.window);\n\t\treturn {\n\t\t\tdispose: () => {\n\t\t\t\tconst renderingIndex = this._coordinatedRenderings.indexOf(rendering);\n\t\t\t\tif (renderingIndex === -1) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tthis._coordinatedRenderings.splice(renderingIndex, 1);\n\n\t\t\t\tif (this._coordinatedRenderings.length === 0) {\n\t\t\t\t\t// There are no more renderings to coordinate => cancel animation frames\n\t\t\t\t\tfor (const [_, disposable] of this._animationFrameRunners) {\n\t\t\t\t\t\tdisposable.dispose();\n\t\t\t\t\t}\n\t\t\t\t\tthis._animationFrameRunners.clear();\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t}\n\n\tprivate _scheduleRender(window: CodeWindow): void {\n\t\tif (!this._animationFrameRunners.has(window)) {\n\t\t\tconst runner = () => {\n\t\t\t\tthis._animationFrameRunners.delete(window);\n\t\t\t\tthis._onRenderScheduled();\n\t\t\t};\n\t\t\tthis._animationFrameRunners.set(window, dom.runAtThisOrScheduleAtNextAnimationFrame(window, runner, 100));\n\t\t}\n\t}\n\n\tprivate _onRenderScheduled(): void {\n\t\tconst coordinatedRenderings = this._coordinatedRenderings.slice(0);\n\t\tthis._coordinatedRenderings = [];\n\n\t\tfor (const rendering of coordinatedRenderings) {\n\t\t\tsafeInvokeNoArg(() => rendering.prepareRenderText());\n\t\t}\n\n\t\tconst datas: ([ViewPart[], RenderingContext] | null)[] = [];\n\t\tfor (let i = 0, len = coordinatedRenderings.length; i < len; i++) {\n\t\t\tconst rendering = coordinatedRenderings[i];\n\t\t\tdatas[i] = safeInvokeNoArg(() => rendering.renderText());\n\t\t}\n\n\t\tfor (let i = 0, len = coordinatedRenderings.length; i < len; i++) {\n\t\t\tconst rendering = coordinatedRenderings[i];\n\t\t\tconst data = datas[i];\n\t\t\tif (!data) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst [viewParts, ctx] = data;\n\t\t\tsafeInvokeNoArg(() => rendering.prepareRender(viewParts, ctx));\n\t\t}\n\n\t\tfor (let i = 0, len = coordinatedRenderings.length; i < len; i++) {\n\t\t\tconst rendering = coordinatedRenderings[i];\n\t\t\tconst data = datas[i];\n\t\t\tif (!data) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst [viewParts, ctx] = data;\n\t\t\tsafeInvokeNoArg(() => rendering.render(viewParts, ctx));\n\t\t}\n\t}\n}\n\nclass CodeEditorWidgetFocusTracker extends Disposable {\n\n\tprivate _hasDomElementFocus: boolean;\n\tprivate readonly _domFocusTracker: dom.IFocusTracker;\n\tprivate readonly _overflowWidgetsDomNode: dom.IFocusTracker | undefined;\n\n\tprivate readonly _onChange: Emitter<void> = this._register(new Emitter<void>());\n\tpublic readonly onChange: Event<void> = this._onChange.event;\n\n\tprivate _overflowWidgetsDomNodeHasFocus: boolean;\n\n\tprivate _hadFocus: boolean | undefined = undefined;\n\n\tconstructor(domElement: HTMLElement, overflowWidgetsDomNode: HTMLElement | undefined) {\n\t\tsuper();\n\n\t\tthis._hasDomElementFocus = false;\n\t\tthis._domFocusTracker = this._register(dom.trackFocus(domElement));\n\n\t\tthis._overflowWidgetsDomNodeHasFocus = false;\n\n\t\tthis._register(this._domFocusTracker.onDidFocus(() => {\n\t\t\tthis._hasDomElementFocus = true;\n\t\t\tthis._update();\n\t\t}));\n\t\tthis._register(this._domFocusTracker.onDidBlur(() => {\n\t\t\tthis._hasDomElementFocus = false;\n\t\t\tthis._update();\n\t\t}));\n\n\t\tif (overflowWidgetsDomNode) {\n\t\t\tthis._overflowWidgetsDomNode = this._register(dom.trackFocus(overflowWidgetsDomNode));\n\t\t\tthis._register(this._overflowWidgetsDomNode.onDidFocus(() => {\n\t\t\t\tthis._overflowWidgetsDomNodeHasFocus = true;\n\t\t\t\tthis._update();\n\t\t\t}));\n\t\t\tthis._register(this._overflowWidgetsDomNode.onDidBlur(() => {\n\t\t\t\tthis._overflowWidgetsDomNodeHasFocus = false;\n\t\t\t\tthis._update();\n\t\t\t}));\n\t\t}\n\t}\n\n\tprivate _update() {\n\t\tconst focused = this._hasDomElementFocus || this._overflowWidgetsDomNodeHasFocus;\n\t\tif (this._hadFocus !== focused) {\n\t\t\tthis._hadFocus = focused;\n\t\t\tthis._onChange.fire(undefined);\n\t\t}\n\t}\n\n\tpublic hasFocus(): boolean {\n\t\treturn this._hadFocus ?? false;\n\t}\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src/vs/editor/browser/view.ts","vs/editor/browser/view.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;;;;;;;;;;AAEhG,OAAO,KAAK,GAAG,MAAM,2BAA2B,CAAC;AACjD,OAAO,EAAe,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AAEnF,OAAO,EAAE,YAAY,EAAE,MAAM,mCAAmC,CAAC;AAEjE,OAAO,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AACpF,OAAO,EAAE,UAAU,EAAE,eAAe,EAAe,MAAM,gCAAgC,CAAC;AAE1F,OAAO,EAAE,4BAA4B,EAAE,MAAM,6BAA6B,CAAC;AAC3E,OAAO,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AAEhE,OAAO,EAAqB,gBAAgB,EAA8B,MAAM,4BAA4B,CAAC;AAC7G,OAAO,EAAoB,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC5E,OAAO,EAAE,mBAAmB,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AACjF,OAAO,EAAmB,gBAAgB,EAAY,MAAM,oBAAoB,CAAC;AACjF,OAAO,EAAE,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AACpE,OAAO,EAAE,gBAAgB,EAAE,MAAM,kDAAkD,CAAC;AACpF,OAAO,EAAE,kBAAkB,EAAE,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AAK,OAAO,EAAE,CAAC;YAChC,IAAI,CAAC,SAAS,GAAG,OAAO,CAAC;YACzB,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;QAChC,CAAC;IACF,CAAC;IAEM,QAAQ;QACd,OAAO,IAAI,CAAC,SAAS,IAAI,KAAK,CAAC;IAChC,CAAC;CACD","file":"view.js","sourceRoot":"file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nimport * as dom from '../../base/browser/dom.js';\nimport { FastDomNode, createFastDomNode } from '../../base/browser/fastDomNode.js';\nimport { IMouseWheelEvent } from '../../base/browser/mouseEvent.js';\nimport { inputLatency } from '../../base/browser/performance.js';\nimport { CodeWindow } from '../../base/browser/window.js';\nimport { BugIndicatingError, onUnexpectedError } from '../../base/common/errors.js';\nimport { Disposable, DisposableStore, IDisposable } from '../../base/common/lifecycle.js';\nimport { IPointerHandlerHelper } from './controller/mouseHandler.js';\nimport { PointerHandlerLastRenderData } from './controller/mouseTarget.js';\nimport { PointerHandler } from './controller/pointerHandler.js';\nimport { IContentWidget, IContentWidgetPosition, IEditorAriaOptions, IGlyphMarginWidget, IGlyphMarginWidgetPosition, IMouseTarget, IOverlayWidget, IOverlayWidgetPosition, IViewZoneChangeAccessor } from './editorBrowser.js';\nimport { LineVisibleRanges, RenderingContext, RestrictedRenderingContext } from './view/renderingContext.js';\nimport { ICommandDelegate, ViewController } from './view/viewController.js';\nimport { ContentViewOverlays, MarginViewOverlays } from './view/viewOverlays.js';\nimport { PartFingerprint, PartFingerprints, ViewPart } from './view/viewPart.js';\nimport { ViewUserInputEvents } from './view/viewUserInputEvents.js';\nimport { BlockDecorations } from './viewParts/blockDecorations/blockDecorations.js';\nimport { ViewContentWidgets } from './viewParts/contentWidgets/contentWidgets.js';\nimport { CurrentLineHighlightOverlay, CurrentLineMarginHighlightOverlay } from './viewParts/currentLineHighlight/currentLineHighlight.js';\nimport { DecorationsOverlay } from './viewParts/decorations/decorations.js';\nimport { EditorScrollbar } from './viewParts/editorScrollbar/editorScrollbar.js';\nimport { GlyphMarginWidgets } from './viewParts/glyphMargin/glyphMargin.js';\nimport { IndentGuidesOverlay } from './viewParts/indentGuides/indentGuides.js';\nimport { LineNumbersOverlay } from './viewParts/lineNumbers/lineNumbers.js';\nimport { ViewLines } from './viewParts/viewLines/viewLines.js';\nimport { LinesDecorationsOverlay } from './viewParts/linesDecorations/linesDecorations.js';\nimport { Margin } from './viewParts/margin/margin.js';\nimport { MarginViewLineDecorationsOverlay } from './viewParts/marginDecorations/marginDecorations.js';\nimport { Minimap } from './viewParts/minimap/minimap.js';\nimport { ViewOverlayWidgets } from './viewParts/overlayWidgets/overlayWidgets.js';\nimport { DecorationsOverviewRuler } from './viewParts/overviewRuler/decorationsOverviewRuler.js';\nimport { OverviewRuler } from './viewParts/overviewRuler/overviewRuler.js';\nimport { Rulers } from './viewParts/rulers/rulers.js';\nimport { ScrollDecorationViewPart } from './viewParts/scrollDecoration/scrollDecoration.js';\nimport { SelectionsOverlay } from './viewParts/selections/selections.js';\nimport { ViewCursors } from './viewParts/viewCursors/viewCursors.js';\nimport { ViewZones } from './viewParts/viewZones/viewZones.js';\nimport { WhitespaceOverlay } from './viewParts/whitespace/whitespace.js';\nimport { IEditorConfiguration } from '../common/config/editorConfiguration.js';\nimport { EditorOption } from '../common/config/editorOptions.js';\nimport { Position } from '../common/core/position.js';\nimport { Range } from '../common/core/range.js';\nimport { Selection } from '../common/core/selection.js';\nimport { ScrollType } from '../common/editorCommon.js';\nimport { GlyphMarginLane, IGlyphMarginLanesModel } from '../common/model.js';\nimport { ViewEventHandler } from '../common/viewEventHandler.js';\nimport * as viewEvents from '../common/viewEvents.js';\nimport { ViewportData } from '../common/viewLayout/viewLinesViewportData.js';\nimport { IViewModel } from '../common/viewModel.js';\nimport { ViewContext } from '../common/viewModel/viewContext.js';\nimport { IInstantiationService } from '../../platform/instantiation/common/instantiation.js';\nimport { IColorTheme, getThemeTypeSelector } from '../../platform/theme/common/themeService.js';\nimport { ViewGpuContext } from './gpu/viewGpuContext.js';\nimport { ViewLinesGpu } from './viewParts/viewLinesGpu/viewLinesGpu.js';\nimport { AbstractEditContext } from './controller/editContext/editContext.js';\nimport { IClipboardCopyEvent, IClipboardPasteEvent } from './controller/editContext/clipboardUtils.js';\nimport { IVisibleRangeProvider, TextAreaEditContext } from './controller/editContext/textArea/textAreaEditContext.js';\nimport { NativeEditContext } from './controller/editContext/native/nativeEditContext.js';\nimport { RulersGpu } from './viewParts/rulersGpu/rulersGpu.js';\nimport { GpuMarkOverlay } from './viewParts/gpuMark/gpuMark.js';\nimport { AccessibilitySupport } from '../../platform/accessibility/common/accessibility.js';\nimport { Event, Emitter } from '../../base/common/event.js';\n\n\nexport interface IContentWidgetData {\n\twidget: IContentWidget;\n\tposition: IContentWidgetPosition | null;\n}\n\nexport interface IOverlayWidgetData {\n\twidget: IOverlayWidget;\n\tposition: IOverlayWidgetPosition | null;\n}\n\nexport interface IGlyphMarginWidgetData {\n\twidget: IGlyphMarginWidget;\n\tposition: IGlyphMarginWidgetPosition;\n}\n\nexport class View extends ViewEventHandler {\n\n\tprivate _widgetFocusTracker: CodeEditorWidgetFocusTracker;\n\n\tprivate readonly _scrollbar: EditorScrollbar;\n\tprivate readonly _context: ViewContext;\n\tprivate readonly _viewGpuContext?: ViewGpuContext;\n\tprivate _selections: Selection[];\n\n\t// The view lines\n\tprivate readonly _viewLines: ViewLines;\n\tprivate readonly _viewLinesGpu?: ViewLinesGpu;\n\n\t// These are parts, but we must do some API related calls on them, so we keep a reference\n\tprivate readonly _viewZones: ViewZones;\n\tprivate readonly _contentWidgets: ViewContentWidgets;\n\tprivate readonly _overlayWidgets: ViewOverlayWidgets;\n\tprivate readonly _glyphMarginWidgets: GlyphMarginWidgets;\n\tprivate readonly _viewCursors: ViewCursors;\n\tprivate readonly _viewParts: ViewPart[];\n\tprivate readonly _viewController: ViewController;\n\n\tprivate _editContextEnabled: boolean;\n\tprivate _accessibilitySupport: AccessibilitySupport;\n\tprivate _editContext: AbstractEditContext;\n\tprivate readonly _editContextClipboardListeners = new DisposableStore();\n\tprivate readonly _pointerHandler: PointerHandler;\n\n\t// Clipboard events relayed from editContext\n\tprivate readonly _onWillCopy = this._register(new Emitter<IClipboardCopyEvent>());\n\tpublic readonly onWillCopy: Event<IClipboardCopyEvent> = this._onWillCopy.event;\n\n\tprivate readonly _onWillCut = this._register(new Emitter<IClipboardCopyEvent>());\n\tpublic readonly onWillCut: Event<IClipboardCopyEvent> = this._onWillCut.event;\n\n\tprivate readonly _onWillPaste = this._register(new Emitter<IClipboardPasteEvent>());\n\tpublic readonly onWillPaste: Event<IClipboardPasteEvent> = this._onWillPaste.event;\n\n\t// Dom nodes\n\tprivate readonly _linesContent: FastDomNode<HTMLElement>;\n\tpublic readonly domNode: FastDomNode<HTMLElement>;\n\tprivate readonly _overflowGuardContainer: FastDomNode<HTMLElement>;\n\n\t// Actual mutable state\n\tprivate _shouldRecomputeGlyphMarginLanes: boolean = false;\n\tprivate _renderAnimationFrame: IDisposable | null;\n\tprivate _ownerID: string;\n\n\tconstructor(\n\t\teditorContainer: HTMLElement,\n\t\townerID: string,\n\t\tcommandDelegate: ICommandDelegate,\n\t\tconfiguration: IEditorConfiguration,\n\t\tcolorTheme: IColorTheme,\n\t\tmodel: IViewModel,\n\t\tuserInputEvents: ViewUserInputEvents,\n\t\toverflowWidgetsDomNode: HTMLElement | undefined,\n\t\t@IInstantiationService private readonly _instantiationService: IInstantiationService\n\t) {\n\t\tsuper();\n\t\tthis._ownerID = ownerID;\n\n\t\tthis._widgetFocusTracker = this._register(\n\t\t\tnew CodeEditorWidgetFocusTracker(editorContainer, overflowWidgetsDomNode)\n\t\t);\n\t\tthis._register(this._widgetFocusTracker.onChange(() => {\n\t\t\tthis._context.viewModel.setHasWidgetFocus(this._widgetFocusTracker.hasFocus());\n\t\t}));\n\n\t\tthis._selections = [new Selection(1, 1, 1, 1)];\n\t\tthis._renderAnimationFrame = null;\n\n\t\tthis._overflowGuardContainer = createFastDomNode(document.createElement('div'));\n\t\tPartFingerprints.write(this._overflowGuardContainer, PartFingerprint.OverflowGuard);\n\t\tthis._overflowGuardContainer.setClassName('overflow-guard');\n\n\t\tthis._viewController = new ViewController(configuration, model, userInputEvents, commandDelegate);\n\n\t\t// The view context is passed on to most classes (basically to reduce param. counts in ctors)\n\t\tthis._context = new ViewContext(configuration, colorTheme, model);\n\n\t\t// Ensure the view is the first event handler in order to update the layout\n\t\tthis._context.addEventHandler(this);\n\n\t\tthis._viewParts = [];\n\n\t\t// Keyboard handler\n\t\tthis._editContextEnabled = this._context.configuration.options.get(EditorOption.effectiveEditContext);\n\t\tthis._accessibilitySupport = this._context.configuration.options.get(EditorOption.accessibilitySupport);\n\t\tthis._editContext = this._instantiateEditContext();\n\t\tthis._connectEditContextClipboardEvents();\n\n\t\tthis._viewParts.push(this._editContext);\n\n\t\t// These two dom nodes must be constructed up front, since references are needed in the layout provider (scrolling & co.)\n\t\tthis._linesContent = createFastDomNode(document.createElement('div'));\n\t\tthis._linesContent.setClassName('lines-content' + ' monaco-editor-background');\n\t\tthis._linesContent.setPosition('absolute');\n\n\t\tthis.domNode = createFastDomNode(document.createElement('div'));\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\t// Set role 'code' for better screen reader support https://github.com/microsoft/vscode/issues/93438\n\t\tthis.domNode.setAttribute('role', 'code');\n\n\t\tif (this._context.configuration.options.get(EditorOption.experimentalGpuAcceleration) === 'on') {\n\t\t\tthis._viewGpuContext = this._instantiationService.createInstance(ViewGpuContext, this._context);\n\t\t}\n\n\t\tthis._scrollbar = new EditorScrollbar(this._context, this._linesContent, this.domNode, this._overflowGuardContainer);\n\t\tthis._viewParts.push(this._scrollbar);\n\n\t\t// View Lines\n\t\tthis._viewLines = new ViewLines(this._context, this._viewGpuContext, this._linesContent);\n\t\tif (this._viewGpuContext) {\n\t\t\tthis._viewLinesGpu = this._instantiationService.createInstance(ViewLinesGpu, this._context, this._viewGpuContext);\n\t\t}\n\n\t\t// View Zones\n\t\tthis._viewZones = new ViewZones(this._context);\n\t\tthis._viewParts.push(this._viewZones);\n\n\t\t// Decorations overview ruler\n\t\tconst decorationsOverviewRuler = new DecorationsOverviewRuler(this._context);\n\t\tthis._viewParts.push(decorationsOverviewRuler);\n\n\n\t\tconst scrollDecoration = new ScrollDecorationViewPart(this._context);\n\t\tthis._viewParts.push(scrollDecoration);\n\n\t\tconst contentViewOverlays = new ContentViewOverlays(this._context);\n\t\tthis._viewParts.push(contentViewOverlays);\n\t\tcontentViewOverlays.addDynamicOverlay(new CurrentLineHighlightOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new SelectionsOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new IndentGuidesOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new DecorationsOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new WhitespaceOverlay(this._context));\n\n\t\tconst marginViewOverlays = new MarginViewOverlays(this._context);\n\t\tthis._viewParts.push(marginViewOverlays);\n\t\tmarginViewOverlays.addDynamicOverlay(new CurrentLineMarginHighlightOverlay(this._context));\n\t\tmarginViewOverlays.addDynamicOverlay(new MarginViewLineDecorationsOverlay(this._context));\n\t\tmarginViewOverlays.addDynamicOverlay(new LinesDecorationsOverlay(this._context));\n\t\tmarginViewOverlays.addDynamicOverlay(new LineNumbersOverlay(this._context));\n\t\tif (this._viewGpuContext) {\n\t\t\tmarginViewOverlays.addDynamicOverlay(new GpuMarkOverlay(this._context, this._viewGpuContext));\n\t\t}\n\n\t\t// Glyph margin widgets\n\t\tthis._glyphMarginWidgets = new GlyphMarginWidgets(this._context);\n\t\tthis._viewParts.push(this._glyphMarginWidgets);\n\n\t\tconst margin = new Margin(this._context);\n\t\tmargin.getDomNode().appendChild(this._viewZones.marginDomNode);\n\t\tmargin.getDomNode().appendChild(marginViewOverlays.getDomNode());\n\t\tmargin.getDomNode().appendChild(this._glyphMarginWidgets.domNode);\n\t\tthis._viewParts.push(margin);\n\n\t\t// Content widgets\n\t\tthis._contentWidgets = new ViewContentWidgets(this._context, this.domNode);\n\t\tthis._viewParts.push(this._contentWidgets);\n\n\t\tthis._viewCursors = new ViewCursors(this._context);\n\t\tthis._viewParts.push(this._viewCursors);\n\n\t\t// Overlay widgets\n\t\tthis._overlayWidgets = new ViewOverlayWidgets(this._context, this.domNode);\n\t\tthis._viewParts.push(this._overlayWidgets);\n\n\t\tconst rulers = this._viewGpuContext\n\t\t\t? new RulersGpu(this._context, this._viewGpuContext)\n\t\t\t: new Rulers(this._context);\n\t\tthis._viewParts.push(rulers);\n\n\t\tconst blockOutline = new BlockDecorations(this._context);\n\t\tthis._viewParts.push(blockOutline);\n\n\t\tconst minimap = new Minimap(this._context);\n\t\tthis._viewParts.push(minimap);\n\n\t\t// -------------- Wire dom nodes up\n\n\t\tif (decorationsOverviewRuler) {\n\t\t\tconst overviewRulerData = this._scrollbar.getOverviewRulerLayoutInfo();\n\t\t\toverviewRulerData.parent.insertBefore(decorationsOverviewRuler.getDomNode(), overviewRulerData.insertBefore);\n\t\t}\n\n\t\tthis._linesContent.appendChild(contentViewOverlays.getDomNode());\n\t\tif ('domNode' in rulers) {\n\t\t\tthis._linesContent.appendChild(rulers.domNode);\n\t\t}\n\t\tthis._linesContent.appendChild(this._viewZones.domNode);\n\t\tthis._linesContent.appendChild(this._viewLines.getDomNode());\n\t\tthis._linesContent.appendChild(this._contentWidgets.domNode);\n\t\tthis._linesContent.appendChild(this._viewCursors.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(margin.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(this._scrollbar.getDomNode());\n\t\tif (this._viewGpuContext) {\n\t\t\tthis._overflowGuardContainer.appendChild(this._viewGpuContext.canvas);\n\t\t}\n\t\tthis._overflowGuardContainer.appendChild(scrollDecoration.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(this._overlayWidgets.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(minimap.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(blockOutline.domNode);\n\t\tthis.domNode.appendChild(this._overflowGuardContainer);\n\n\t\tif (overflowWidgetsDomNode) {\n\t\t\toverflowWidgetsDomNode.appendChild(this._contentWidgets.overflowingContentWidgetsDomNode.domNode);\n\t\t\toverflowWidgetsDomNode.appendChild(this._overlayWidgets.overflowingOverlayWidgetsDomNode.domNode);\n\t\t} else {\n\t\t\tthis.domNode.appendChild(this._contentWidgets.overflowingContentWidgetsDomNode);\n\t\t\tthis.domNode.appendChild(this._overlayWidgets.overflowingOverlayWidgetsDomNode);\n\t\t}\n\n\t\tthis._applyLayout();\n\n\t\t// Pointer handler\n\t\tthis._pointerHandler = this._register(new PointerHandler(this._context, this._viewController, this._createPointerHandlerHelper()));\n\t}\n\n\tprivate _instantiateEditContext(): AbstractEditContext {\n\t\tconst usingExperimentalEditContext = this._context.configuration.options.get(EditorOption.effectiveEditContext);\n\t\tif (usingExperimentalEditContext) {\n\t\t\treturn this._instantiationService.createInstance(NativeEditContext, this._ownerID, this._context, this._overflowGuardContainer, this._viewController, this._createTextAreaHandlerHelper());\n\t\t} else {\n\t\t\treturn this._instantiationService.createInstance(TextAreaEditContext, this._ownerID, this._context, this._overflowGuardContainer, this._viewController, this._createTextAreaHandlerHelper());\n\t\t}\n\t}\n\n\tprivate _updateEditContext(): void {\n\t\tconst editContextEnabled = this._context.configuration.options.get(EditorOption.effectiveEditContext);\n\t\tconst accessibilitySupport = this._context.configuration.options.get(EditorOption.accessibilitySupport);\n\t\tif (this._editContextEnabled === editContextEnabled && this._accessibilitySupport === accessibilitySupport) {\n\t\t\treturn;\n\t\t}\n\t\tthis._editContextEnabled = editContextEnabled;\n\t\tthis._accessibilitySupport = accessibilitySupport;\n\t\tconst isEditContextFocused = this._editContext.isFocused();\n\t\tconst indexOfEditContext = this._viewParts.indexOf(this._editContext);\n\t\tthis._editContext.dispose();\n\t\tthis._editContext = this._instantiateEditContext();\n\t\tthis._connectEditContextClipboardEvents();\n\t\tif (isEditContextFocused) {\n\t\t\tthis._editContext.focus();\n\t\t}\n\t\tif (indexOfEditContext !== -1) {\n\t\t\tthis._viewParts.splice(indexOfEditContext, 1, this._editContext);\n\t\t}\n\t}\n\n\tprivate _connectEditContextClipboardEvents(): void {\n\t\t// Dispose old listeners\n\t\tthis._editContextClipboardListeners.clear();\n\n\t\t// Connect to current edit context's clipboard events\n\t\tthis._editContextClipboardListeners.add(this._editContext.onWillCopy(e => this._onWillCopy.fire(e)));\n\t\tthis._editContextClipboardListeners.add(this._editContext.onWillCut(e => this._onWillCut.fire(e)));\n\t\tthis._editContextClipboardListeners.add(this._editContext.onWillPaste(e => this._onWillPaste.fire(e)));\n\t}\n\n\tprivate _computeGlyphMarginLanes(): IGlyphMarginLanesModel {\n\t\tconst model = this._context.viewModel.model;\n\t\tconst laneModel = this._context.viewModel.glyphLanes;\n\t\ttype Glyph = { range: Range; lane: GlyphMarginLane; persist?: boolean };\n\t\tlet glyphs: Glyph[] = [];\n\t\tlet maxLineNumber = 0;\n\n\t\t// Add all margin decorations\n\t\tglyphs = glyphs.concat(model.getAllMarginDecorations().map((decoration) => {\n\t\t\tconst lane = decoration.options.glyphMargin?.position ?? GlyphMarginLane.Center;\n\t\t\tmaxLineNumber = Math.max(maxLineNumber, decoration.range.endLineNumber);\n\t\t\treturn { range: decoration.range, lane, persist: decoration.options.glyphMargin?.persistLane };\n\t\t}));\n\n\t\t// Add all glyph margin widgets\n\t\tglyphs = glyphs.concat(this._glyphMarginWidgets.getWidgets().map((widget) => {\n\t\t\tconst range = model.validateRange(widget.preference.range);\n\t\t\tmaxLineNumber = Math.max(maxLineNumber, range.endLineNumber);\n\t\t\treturn { range, lane: widget.preference.lane };\n\t\t}));\n\n\t\t// Sorted by their start position\n\t\tglyphs.sort((a, b) => Range.compareRangesUsingStarts(a.range, b.range));\n\n\t\tlaneModel.reset(maxLineNumber);\n\t\tfor (const glyph of glyphs) {\n\t\t\tlaneModel.push(glyph.lane, glyph.range, glyph.persist);\n\t\t}\n\n\t\treturn laneModel;\n\t}\n\n\tprivate _createPointerHandlerHelper(): IPointerHandlerHelper {\n\t\treturn {\n\t\t\tviewDomNode: this.domNode.domNode,\n\t\t\tlinesContentDomNode: this._linesContent.domNode,\n\t\t\tviewLinesDomNode: this._viewLines.getDomNode().domNode,\n\t\t\tviewLinesGpu: this._viewLinesGpu,\n\n\t\t\tfocusTextArea: () => {\n\t\t\t\tthis.focus();\n\t\t\t},\n\n\t\t\tdispatchTextAreaEvent: (event: CustomEvent) => {\n\t\t\t\tthis._editContext.domNode.domNode.dispatchEvent(event);\n\t\t\t},\n\n\t\t\tgetLastRenderData: (): PointerHandlerLastRenderData => {\n\t\t\t\tconst lastViewCursorsRenderData = this._viewCursors.getLastRenderData() || [];\n\t\t\t\tconst lastTextareaPosition = this._editContext.getLastRenderData();\n\t\t\t\treturn new PointerHandlerLastRenderData(lastViewCursorsRenderData, lastTextareaPosition);\n\t\t\t},\n\t\t\trenderNow: (): void => {\n\t\t\t\tthis.render(true, false);\n\t\t\t},\n\t\t\tshouldSuppressMouseDownOnViewZone: (viewZoneId: string) => {\n\t\t\t\treturn this._viewZones.shouldSuppressMouseDownOnViewZone(viewZoneId);\n\t\t\t},\n\t\t\tshouldSuppressMouseDownOnWidget: (widgetId: string) => {\n\t\t\t\treturn this._contentWidgets.shouldSuppressMouseDownOnWidget(widgetId);\n\t\t\t},\n\t\t\tgetPositionFromDOMInfo: (spanNode: HTMLElement, offset: number) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\treturn this._viewLines.getPositionFromDOMInfo(spanNode, offset);\n\t\t\t},\n\n\t\t\tvisibleRangeForPosition: (lineNumber: number, column: number) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\tconst position = new Position(lineNumber, column);\n\t\t\t\treturn this._viewLines.visibleRangeForPosition(position) ?? this._viewLinesGpu?.visibleRangeForPosition(position) ?? null;\n\t\t\t},\n\n\t\t\tgetLineWidth: (lineNumber: number) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\tif (this._viewLinesGpu) {\n\t\t\t\t\tconst result = this._viewLinesGpu.getLineWidth(lineNumber);\n\t\t\t\t\tif (result !== undefined) {\n\t\t\t\t\t\treturn result;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn this._viewLines.getLineWidth(lineNumber);\n\t\t\t}\n\t\t};\n\t}\n\n\tprivate _createTextAreaHandlerHelper(): IVisibleRangeProvider {\n\t\treturn {\n\t\t\tvisibleRangeForPosition: (position: Position) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\treturn this._viewLines.visibleRangeForPosition(position);\n\t\t\t},\n\t\t\tlinesVisibleRangesForRange: (range: Range, includeNewLines: boolean): LineVisibleRanges[] | null => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\treturn this._viewLines.linesVisibleRangesForRange(range, includeNewLines);\n\t\t\t}\n\t\t};\n\t}\n\n\tprivate _applyLayout(): void {\n\t\tconst options = this._context.configuration.options;\n\t\tconst layoutInfo = options.get(EditorOption.layoutInfo);\n\n\t\tthis.domNode.setWidth(layoutInfo.width);\n\t\tthis.domNode.setHeight(layoutInfo.height);\n\n\t\tthis._overflowGuardContainer.setWidth(layoutInfo.width);\n\t\tthis._overflowGuardContainer.setHeight(layoutInfo.height);\n\n\t\t// https://stackoverflow.com/questions/38905916/content-in-google-chrome-larger-than-16777216-px-not-being-rendered\n\t\tthis._linesContent.setWidth(16777216);\n\t\tthis._linesContent.setHeight(16777216);\n\t}\n\n\tprivate _getEditorClassName() {\n\t\tconst focused = this._editContext.isFocused() ? ' focused' : '';\n\t\treturn this._context.configuration.options.get(EditorOption.editorClassName) + ' ' + getThemeTypeSelector(this._context.theme.type) + focused;\n\t}\n\n\t// --- begin event handlers\n\tpublic override handleEvents(events: viewEvents.ViewEvent[]): void {\n\t\tsuper.handleEvents(events);\n\t\tthis._scheduleRender();\n\t}\n\tpublic override onConfigurationChanged(e: viewEvents.ViewConfigurationChangedEvent): boolean {\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\tthis._updateEditContext();\n\t\tthis._applyLayout();\n\t\treturn false;\n\t}\n\tpublic override onCursorStateChanged(e: viewEvents.ViewCursorStateChangedEvent): boolean {\n\t\tthis._selections = e.selections;\n\t\treturn false;\n\t}\n\tpublic override onDecorationsChanged(e: viewEvents.ViewDecorationsChangedEvent): boolean {\n\t\tif (e.affectsGlyphMargin) {\n\t\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\t}\n\t\treturn false;\n\t}\n\tpublic override onFocusChanged(e: viewEvents.ViewFocusChangedEvent): boolean {\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\treturn false;\n\t}\n\tpublic override onThemeChanged(e: viewEvents.ViewThemeChangedEvent): boolean {\n\t\tthis._context.theme.update(e.theme);\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\treturn false;\n\t}\n\n\t// --- end event handlers\n\n\tpublic override dispose(): void {\n\t\tif (this._renderAnimationFrame !== null) {\n\t\t\tthis._renderAnimationFrame.dispose();\n\t\t\tthis._renderAnimationFrame = null;\n\t\t}\n\n\t\t// Dispose clipboard event listeners\n\t\tthis._editContextClipboardListeners.dispose();\n\n\t\tthis._contentWidgets.overflowingContentWidgetsDomNode.domNode.remove();\n\t\tthis._overlayWidgets.overflowingOverlayWidgetsDomNode.domNode.remove();\n\n\t\tthis._context.removeEventHandler(this);\n\t\tthis._viewGpuContext?.dispose();\n\n\t\tthis._viewLines.dispose();\n\t\tthis._viewLinesGpu?.dispose();\n\n\t\t// Destroy view parts\n\t\tfor (const viewPart of this._viewParts) {\n\t\t\tviewPart.dispose();\n\t\t}\n\n\t\tsuper.dispose();\n\t}\n\n\tprivate _scheduleRender(): void {\n\t\tif (this._store.isDisposed) {\n\t\t\tthrow new BugIndicatingError();\n\t\t}\n\t\tif (this._renderAnimationFrame === null) {\n\t\t\t// TODO: workaround fix for https://github.com/microsoft/vscode/issues/229825\n\t\t\tif (this._editContext instanceof NativeEditContext) {\n\t\t\t\tthis._editContext.setEditContextOnDomNode();\n\t\t\t}\n\t\t\tconst rendering = this._createCoordinatedRendering();\n\t\t\tthis._renderAnimationFrame = EditorRenderingCoordinator.INSTANCE.scheduleCoordinatedRendering({\n\t\t\t\twindow: dom.getWindow(this.domNode?.domNode),\n\t\t\t\tprepareRenderText: () => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\ttry {\n\t\t\t\t\t\treturn rendering.prepareRenderText();\n\t\t\t\t\t} finally {\n\t\t\t\t\t\tthis._renderAnimationFrame = null;\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\trenderText: () => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\treturn rendering.renderText();\n\t\t\t\t},\n\t\t\t\tprepareRender: (viewParts: ViewPart[], ctx: RenderingContext) => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\treturn rendering.prepareRender(viewParts, ctx);\n\t\t\t\t},\n\t\t\t\trender: (viewParts: ViewPart[], ctx: RestrictedRenderingContext) => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\treturn rendering.render(viewParts, ctx);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n\n\tprivate _flushAccumulatedAndRenderNow(): void {\n\t\tconst rendering = this._createCoordinatedRendering();\n\t\tsafeInvokeNoArg(() => rendering.prepareRenderText());\n\t\tconst data = safeInvokeNoArg(() => rendering.renderText());\n\t\tif (data) {\n\t\t\tconst [viewParts, ctx] = data;\n\t\t\tsafeInvokeNoArg(() => rendering.prepareRender(viewParts, ctx));\n\t\t\tsafeInvokeNoArg(() => rendering.render(viewParts, ctx));\n\t\t}\n\t}\n\n\tprivate _getViewPartsToRender(): ViewPart[] {\n\t\tconst result: ViewPart[] = [];\n\t\tlet resultLen = 0;\n\t\tfor (const viewPart of this._viewParts) {\n\t\t\tif (viewPart.shouldRender()) {\n\t\t\t\tresult[resultLen++] = viewPart;\n\t\t\t}\n\t\t}\n\t\treturn result;\n\t}\n\n\tprivate _createCoordinatedRendering() {\n\t\treturn {\n\t\t\tprepareRenderText: () => {\n\t\t\t\tif (this._shouldRecomputeGlyphMarginLanes) {\n\t\t\t\t\tthis._shouldRecomputeGlyphMarginLanes = false;\n\t\t\t\t\tconst model = this._computeGlyphMarginLanes();\n\t\t\t\t\tthis._context.configuration.setGlyphMarginDecorationLaneCount(model.requiredLanes);\n\t\t\t\t}\n\t\t\t\tinputLatency.onRenderStart();\n\t\t\t},\n\t\t\trenderText: (): [ViewPart[], RenderingContext] | null => {\n\t\t\t\tif (!this.domNode.domNode.isConnected) {\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t\tlet viewPartsToRender = this._getViewPartsToRender();\n\t\t\t\tif (!this._viewLines.shouldRender() && viewPartsToRender.length === 0) {\n\t\t\t\t\t// Nothing to render\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t\tconst partialViewportData = this._context.viewLayout.getLinesViewportData();\n\t\t\t\tthis._context.viewModel.setViewport(partialViewportData.startLineNumber, partialViewportData.endLineNumber, partialViewportData.centeredLineNumber);\n\n\t\t\t\tconst viewportData = new ViewportData(\n\t\t\t\t\tthis._selections,\n\t\t\t\t\tpartialViewportData,\n\t\t\t\t\tthis._context.viewLayout.getWhitespaceViewportData(),\n\t\t\t\t\tthis._context.viewModel\n\t\t\t\t);\n\n\t\t\t\tif (this._contentWidgets.shouldRender()) {\n\t\t\t\t\t// Give the content widgets a chance to set their max width before a possible synchronous layout\n\t\t\t\t\tthis._contentWidgets.onBeforeRender(viewportData);\n\t\t\t\t}\n\n\t\t\t\tif (this._viewLines.shouldRender()) {\n\t\t\t\t\tthis._viewLines.renderText(viewportData);\n\t\t\t\t\tthis._viewLines.onDidRender();\n\n\t\t\t\t\t// Rendering of viewLines might cause scroll events to occur, so collect view parts to render again\n\t\t\t\t\tviewPartsToRender = this._getViewPartsToRender();\n\t\t\t\t}\n\n\t\t\t\tif (this._viewLinesGpu?.shouldRender()) {\n\t\t\t\t\tthis._viewLinesGpu.renderText(viewportData);\n\t\t\t\t\tthis._viewLinesGpu.onDidRender();\n\t\t\t\t}\n\n\t\t\t\treturn [viewPartsToRender, new RenderingContext(this._context.viewLayout, viewportData, this._viewLines, this._viewLinesGpu)];\n\t\t\t},\n\t\t\tprepareRender: (viewPartsToRender: ViewPart[], ctx: RenderingContext) => {\n\t\t\t\tfor (const viewPart of viewPartsToRender) {\n\t\t\t\t\tviewPart.prepareRender(ctx);\n\t\t\t\t}\n\t\t\t},\n\t\t\trender: (viewPartsToRender: ViewPart[], ctx: RestrictedRenderingContext) => {\n\t\t\t\tfor (const viewPart of viewPartsToRender) {\n\t\t\t\t\tviewPart.render(ctx);\n\t\t\t\t\tviewPart.onDidRender();\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t}\n\n\t// --- BEGIN CodeEditor helpers\n\n\tpublic delegateVerticalScrollbarPointerDown(browserEvent: PointerEvent): void {\n\t\tthis._scrollbar.delegateVerticalScrollbarPointerDown(browserEvent);\n\t}\n\n\tpublic delegateScrollFromMouseWheelEvent(browserEvent: IMouseWheelEvent) {\n\t\tthis._scrollbar.delegateScrollFromMouseWheelEvent(browserEvent);\n\t}\n\n\tpublic restoreState(scrollPosition: { scrollLeft: number; scrollTop: number }): void {\n\t\tthis._context.viewModel.viewLayout.setScrollPosition({\n\t\t\tscrollTop: scrollPosition.scrollTop,\n\t\t\tscrollLeft: scrollPosition.scrollLeft\n\t\t}, ScrollType.Immediate);\n\t\tthis._context.viewModel.visibleLinesStabilized();\n\t}\n\n\tpublic getOffsetForColumn(modelLineNumber: number, modelColumn: number): number {\n\t\tconst modelPosition = this._context.viewModel.model.validatePosition({\n\t\t\tlineNumber: modelLineNumber,\n\t\t\tcolumn: modelColumn\n\t\t});\n\t\tconst viewPosition = this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(modelPosition);\n\t\tthis._flushAccumulatedAndRenderNow();\n\t\tconst visibleRange = this._viewLines.visibleRangeForPosition(new Position(viewPosition.lineNumber, viewPosition.column));\n\t\tif (!visibleRange) {\n\t\t\treturn -1;\n\t\t}\n\t\treturn visibleRange.left;\n\t}\n\n\tpublic getLineWidth(modelLineNumber: number): number {\n\t\tconst model = this._context.viewModel.model;\n\t\tconst viewLine = this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(new Position(modelLineNumber, model.getLineMaxColumn(modelLineNumber))).lineNumber;\n\t\tthis._flushAccumulatedAndRenderNow();\n\t\tconst width = this._viewLines.getLineWidth(viewLine);\n\n\t\treturn width;\n\t}\n\n\tpublic resetLineWidthCaches(): void {\n\t\tthis._viewLines.resetLineWidthCaches();\n\t}\n\n\tpublic getTargetAtClientPoint(clientX: number, clientY: number): IMouseTarget | null {\n\t\tconst mouseTarget = this._pointerHandler.getTargetAtClientPoint(clientX, clientY);\n\t\tif (!mouseTarget) {\n\t\t\treturn null;\n\t\t}\n\t\treturn ViewUserInputEvents.convertViewToModelMouseTarget(mouseTarget, this._context.viewModel.coordinatesConverter);\n\t}\n\n\tpublic createOverviewRuler(cssClassName: string): OverviewRuler {\n\t\treturn new OverviewRuler(this._context, cssClassName);\n\t}\n\n\tpublic change(callback: (changeAccessor: IViewZoneChangeAccessor) => unknown): void {\n\t\tthis._viewZones.changeViewZones(callback);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic render(now: boolean, everything: boolean): void {\n\t\tif (everything) {\n\t\t\t// Force everything to render...\n\t\t\tthis._viewLines.forceShouldRender();\n\t\t\tfor (const viewPart of this._viewParts) {\n\t\t\t\tviewPart.forceShouldRender();\n\t\t\t}\n\t\t}\n\t\tif (now) {\n\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t} else {\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic writeScreenReaderContent(reason: string): void {\n\t\tthis._editContext.writeScreenReaderContent(reason);\n\t}\n\n\tpublic focus(): void {\n\t\tthis._editContext.focus();\n\t}\n\n\tpublic isFocused(): boolean {\n\t\treturn this._editContext.isFocused();\n\t}\n\n\tpublic isWidgetFocused(): boolean {\n\t\treturn this._widgetFocusTracker.hasFocus();\n\t}\n\n\tpublic setAriaOptions(options: IEditorAriaOptions): void {\n\t\tthis._editContext.setAriaOptions(options);\n\t}\n\n\tpublic addContentWidget(widgetData: IContentWidgetData): void {\n\t\tthis._contentWidgets.addWidget(widgetData.widget);\n\t\tthis.layoutContentWidget(widgetData);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic layoutContentWidget(widgetData: IContentWidgetData): void {\n\t\tthis._contentWidgets.setWidgetPosition(\n\t\t\twidgetData.widget,\n\t\t\twidgetData.position?.position ?? null,\n\t\t\twidgetData.position?.secondaryPosition ?? null,\n\t\t\twidgetData.position?.preference ?? null,\n\t\t\twidgetData.position?.positionAffinity ?? null\n\t\t);\n\t\tif (this._contentWidgets.shouldRender()) {\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic removeContentWidget(widgetData: IContentWidgetData): void {\n\t\tthis._contentWidgets.removeWidget(widgetData.widget);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic addOverlayWidget(widgetData: IOverlayWidgetData): void {\n\t\tthis._overlayWidgets.addWidget(widgetData.widget);\n\t\tthis.layoutOverlayWidget(widgetData);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic layoutOverlayWidget(widgetData: IOverlayWidgetData): void {\n\t\tconst shouldRender = this._overlayWidgets.setWidgetPosition(widgetData.widget, widgetData.position);\n\t\tif (shouldRender) {\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic removeOverlayWidget(widgetData: IOverlayWidgetData): void {\n\t\tthis._overlayWidgets.removeWidget(widgetData.widget);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic addGlyphMarginWidget(widgetData: IGlyphMarginWidgetData): void {\n\t\tthis._glyphMarginWidgets.addWidget(widgetData.widget);\n\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic layoutGlyphMarginWidget(widgetData: IGlyphMarginWidgetData): void {\n\t\tconst newPreference = widgetData.position;\n\t\tconst shouldRender = this._glyphMarginWidgets.setWidgetPosition(widgetData.widget, newPreference);\n\t\tif (shouldRender) {\n\t\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic removeGlyphMarginWidget(widgetData: IGlyphMarginWidgetData): void {\n\t\tthis._glyphMarginWidgets.removeWidget(widgetData.widget);\n\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\tthis._scheduleRender();\n\t}\n\n\t// --- END CodeEditor helpers\n\n}\n\nfunction safeInvokeNoArg<T>(func: () => T): T | null {\n\ttry {\n\t\treturn func();\n\t} catch (e) {\n\t\tonUnexpectedError(e);\n\t\treturn null;\n\t}\n}\n\ninterface ICoordinatedRendering {\n\treadonly window: CodeWindow;\n\tprepareRenderText(): void;\n\trenderText(): [ViewPart[], RenderingContext] | null;\n\tprepareRender(viewParts: ViewPart[], ctx: RenderingContext): void;\n\trender(viewParts: ViewPart[], ctx: RestrictedRenderingContext): void;\n}\n\nclass EditorRenderingCoordinator {\n\n\tpublic static INSTANCE = new EditorRenderingCoordinator();\n\n\tprivate _coordinatedRenderings: ICoordinatedRendering[] = [];\n\tprivate _animationFrameRunners = new Map<CodeWindow, IDisposable>();\n\n\tprivate constructor() { }\n\n\tscheduleCoordinatedRendering(rendering: ICoordinatedRendering): IDisposable {\n\t\tthis._coordinatedRenderings.push(rendering);\n\t\tthis._scheduleRender(rendering.window);\n\t\treturn {\n\t\t\tdispose: () => {\n\t\t\t\tconst renderingIndex = this._coordinatedRenderings.indexOf(rendering);\n\t\t\t\tif (renderingIndex === -1) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tthis._coordinatedRenderings.splice(renderingIndex, 1);\n\n\t\t\t\tif (this._coordinatedRenderings.length === 0) {\n\t\t\t\t\t// There are no more renderings to coordinate => cancel animation frames\n\t\t\t\t\tfor (const [_, disposable] of this._animationFrameRunners) {\n\t\t\t\t\t\tdisposable.dispose();\n\t\t\t\t\t}\n\t\t\t\t\tthis._animationFrameRunners.clear();\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t}\n\n\tprivate _scheduleRender(window: CodeWindow): void {\n\t\tif (!this._animationFrameRunners.has(window)) {\n\t\t\tconst runner = () => {\n\t\t\t\tthis._animationFrameRunners.delete(window);\n\t\t\t\tthis._onRenderScheduled();\n\t\t\t};\n\t\t\tthis._animationFrameRunners.set(window, dom.runAtThisOrScheduleAtNextAnimationFrame(window, runner, 100));\n\t\t}\n\t}\n\n\tprivate _onRenderScheduled(): void {\n\t\tconst coordinatedRenderings = this._coordinatedRenderings.slice(0);\n\t\tthis._coordinatedRenderings = [];\n\n\t\tfor (const rendering of coordinatedRenderings) {\n\t\t\tsafeInvokeNoArg(() => rendering.prepareRenderText());\n\t\t}\n\n\t\tconst datas: ([ViewPart[], RenderingContext] | null)[] = [];\n\t\tfor (let i = 0, len = coordinatedRenderings.length; i < len; i++) {\n\t\t\tconst rendering = coordinatedRenderings[i];\n\t\t\tdatas[i] = safeInvokeNoArg(() => rendering.renderText());\n\t\t}\n\n\t\tfor (let i = 0, len = coordinatedRenderings.length; i < len; i++) {\n\t\t\tconst rendering = coordinatedRenderings[i];\n\t\t\tconst data = datas[i];\n\t\t\tif (!data) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst [viewParts, ctx] = data;\n\t\t\tsafeInvokeNoArg(() => rendering.prepareRender(viewParts, ctx));\n\t\t}\n\n\t\tfor (let i = 0, len = coordinatedRenderings.length; i < len; i++) {\n\t\t\tconst rendering = coordinatedRenderings[i];\n\t\t\tconst data = datas[i];\n\t\t\tif (!data) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst [viewParts, ctx] = data;\n\t\t\tsafeInvokeNoArg(() => rendering.render(viewParts, ctx));\n\t\t}\n\t}\n}\n\nclass CodeEditorWidgetFocusTracker extends Disposable {\n\n\tprivate _hasDomElementFocus: boolean;\n\tprivate readonly _domFocusTracker: dom.IFocusTracker;\n\tprivate readonly _overflowWidgetsDomNode: dom.IFocusTracker | undefined;\n\n\tprivate readonly _onChange: Emitter<void> = this._register(new Emitter<void>());\n\tpublic readonly onChange: Event<void> = this._onChange.event;\n\n\tprivate _overflowWidgetsDomNodeHasFocus: boolean;\n\n\tprivate _hadFocus: boolean | undefined = undefined;\n\n\tconstructor(domElement: HTMLElement, overflowWidgetsDomNode: HTMLElement | undefined) {\n\t\tsuper();\n\n\t\tthis._hasDomElementFocus = false;\n\t\tthis._domFocusTracker = this._register(dom.trackFocus(domElement));\n\n\t\tthis._overflowWidgetsDomNodeHasFocus = false;\n\n\t\tthis._register(this._domFocusTracker.onDidFocus(() => {\n\t\t\tthis._hasDomElementFocus = true;\n\t\t\tthis._update();\n\t\t}));\n\t\tthis._register(this._domFocusTracker.onDidBlur(() => {\n\t\t\tthis._hasDomElementFocus = false;\n\t\t\tthis._update();\n\t\t}));\n\n\t\tif (overflowWidgetsDomNode) {\n\t\t\tthis._overflowWidgetsDomNode = this._register(dom.trackFocus(overflowWidgetsDomNode));\n\t\t\tthis._register(this._overflowWidgetsDomNode.onDidFocus(() => {\n\t\t\t\tthis._overflowWidgetsDomNodeHasFocus = true;\n\t\t\t\tthis._update();\n\t\t\t}));\n\t\t\tthis._register(this._overflowWidgetsDomNode.onDidBlur(() => {\n\t\t\t\tthis._overflowWidgetsDomNodeHasFocus = false;\n\t\t\t\tthis._update();\n\t\t\t}));\n\t\t}\n\t}\n\n\tprivate _update() {\n\t\tconst focused = this._hasDomElementFocus || this._overflowWidgetsDomNodeHasFocus;\n\t\tif (this._hadFocus !== focused) {\n\t\t\tthis._hadFocus = focused;\n\t\t\tthis._onChange.fire(undefined);\n\t\t}\n\t}\n\n\tpublic hasFocus(): boolean {\n\t\treturn this._hadFocus ?? false;\n\t}\n}\n","/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nimport * as dom from '../../base/browser/dom.js';\nimport { FastDomNode, createFastDomNode } from '../../base/browser/fastDomNode.js';\nimport { IMouseWheelEvent } from '../../base/browser/mouseEvent.js';\nimport { inputLatency } from '../../base/browser/performance.js';\nimport { CodeWindow } from '../../base/browser/window.js';\nimport { BugIndicatingError, onUnexpectedError } from '../../base/common/errors.js';\nimport { Disposable, DisposableStore, IDisposable } from '../../base/common/lifecycle.js';\nimport { IPointerHandlerHelper } from './controller/mouseHandler.js';\nimport { PointerHandlerLastRenderData } from './controller/mouseTarget.js';\nimport { PointerHandler } from './controller/pointerHandler.js';\nimport { IContentWidget, IContentWidgetPosition, IEditorAriaOptions, IGlyphMarginWidget, IGlyphMarginWidgetPosition, IMouseTarget, IOverlayWidget, IOverlayWidgetPosition, IViewZoneChangeAccessor } from './editorBrowser.js';\nimport { LineVisibleRanges, RenderingContext, RestrictedRenderingContext } from './view/renderingContext.js';\nimport { ICommandDelegate, ViewController } from './view/viewController.js';\nimport { ContentViewOverlays, MarginViewOverlays } from './view/viewOverlays.js';\nimport { PartFingerprint, PartFingerprints, ViewPart } from './view/viewPart.js';\nimport { ViewUserInputEvents } from './view/viewUserInputEvents.js';\nimport { BlockDecorations } from './viewParts/blockDecorations/blockDecorations.js';\nimport { ViewContentWidgets } from './viewParts/contentWidgets/contentWidgets.js';\nimport { CurrentLineHighlightOverlay, CurrentLineMarginHighlightOverlay } from './viewParts/currentLineHighlight/currentLineHighlight.js';\nimport { DecorationsOverlay } from './viewParts/decorations/decorations.js';\nimport { EditorScrollbar } from './viewParts/editorScrollbar/editorScrollbar.js';\nimport { GlyphMarginWidgets } from './viewParts/glyphMargin/glyphMargin.js';\nimport { IndentGuidesOverlay } from './viewParts/indentGuides/indentGuides.js';\nimport { LineNumbersOverlay } from './viewParts/lineNumbers/lineNumbers.js';\nimport { ViewLines } from './viewParts/viewLines/viewLines.js';\nimport { LinesDecorationsOverlay } from './viewParts/linesDecorations/linesDecorations.js';\nimport { Margin } from './viewParts/margin/margin.js';\nimport { MarginViewLineDecorationsOverlay } from './viewParts/marginDecorations/marginDecorations.js';\nimport { Minimap } from './viewParts/minimap/minimap.js';\nimport { ViewOverlayWidgets } from './viewParts/overlayWidgets/overlayWidgets.js';\nimport { DecorationsOverviewRuler } from './viewParts/overviewRuler/decorationsOverviewRuler.js';\nimport { OverviewRuler } from './viewParts/overviewRuler/overviewRuler.js';\nimport { Rulers } from './viewParts/rulers/rulers.js';\nimport { ScrollDecorationViewPart } from './viewParts/scrollDecoration/scrollDecoration.js';\nimport { SelectionsOverlay } from './viewParts/selections/selections.js';\nimport { ViewCursors } from './viewParts/viewCursors/viewCursors.js';\nimport { ViewZones } from './viewParts/viewZones/viewZones.js';\nimport { WhitespaceOverlay } from './viewParts/whitespace/whitespace.js';\nimport { IEditorConfiguration } from '../common/config/editorConfiguration.js';\nimport { EditorOption } from '../common/config/editorOptions.js';\nimport { Position } from '../common/core/position.js';\nimport { Range } from '../common/core/range.js';\nimport { Selection } from '../common/core/selection.js';\nimport { ScrollType } from '../common/editorCommon.js';\nimport { GlyphMarginLane, IGlyphMarginLanesModel } from '../common/model.js';\nimport { ViewEventHandler } from '../common/viewEventHandler.js';\nimport * as viewEvents from '../common/viewEvents.js';\nimport { ViewportData } from '../common/viewLayout/viewLinesViewportData.js';\nimport { IViewModel } from '../common/viewModel.js';\nimport { ViewContext } from '../common/viewModel/viewContext.js';\nimport { IInstantiationService } from '../../platform/instantiation/common/instantiation.js';\nimport { IColorTheme, getThemeTypeSelector } from '../../platform/theme/common/themeService.js';\nimport { ViewGpuContext } from './gpu/viewGpuContext.js';\nimport { ViewLinesGpu } from './viewParts/viewLinesGpu/viewLinesGpu.js';\nimport { AbstractEditContext } from './controller/editContext/editContext.js';\nimport { IClipboardCopyEvent, IClipboardPasteEvent } from './controller/editContext/clipboardUtils.js';\nimport { IVisibleRangeProvider, TextAreaEditContext } from './controller/editContext/textArea/textAreaEditContext.js';\nimport { NativeEditContext } from './controller/editContext/native/nativeEditContext.js';\nimport { RulersGpu } from './viewParts/rulersGpu/rulersGpu.js';\nimport { GpuMarkOverlay } from './viewParts/gpuMark/gpuMark.js';\nimport { AccessibilitySupport } from '../../platform/accessibility/common/accessibility.js';\nimport { Event, Emitter } from '../../base/common/event.js';\n\n\nexport interface IContentWidgetData {\n\twidget: IContentWidget;\n\tposition: IContentWidgetPosition | null;\n}\n\nexport interface IOverlayWidgetData {\n\twidget: IOverlayWidget;\n\tposition: IOverlayWidgetPosition | null;\n}\n\nexport interface IGlyphMarginWidgetData {\n\twidget: IGlyphMarginWidget;\n\tposition: IGlyphMarginWidgetPosition;\n}\n\nexport class View extends ViewEventHandler {\n\n\tprivate _widgetFocusTracker: CodeEditorWidgetFocusTracker;\n\n\tprivate readonly _scrollbar: EditorScrollbar;\n\tprivate readonly _context: ViewContext;\n\tprivate readonly _viewGpuContext?: ViewGpuContext;\n\tprivate _selections: Selection[];\n\n\t// The view lines\n\tprivate readonly _viewLines: ViewLines;\n\tprivate readonly _viewLinesGpu?: ViewLinesGpu;\n\n\t// These are parts, but we must do some API related calls on them, so we keep a reference\n\tprivate readonly _viewZones: ViewZones;\n\tprivate readonly _contentWidgets: ViewContentWidgets;\n\tprivate readonly _overlayWidgets: ViewOverlayWidgets;\n\tprivate readonly _glyphMarginWidgets: GlyphMarginWidgets;\n\tprivate readonly _viewCursors: ViewCursors;\n\tprivate readonly _viewParts: ViewPart[];\n\tprivate readonly _viewController: ViewController;\n\n\tprivate _editContextEnabled: boolean;\n\tprivate _accessibilitySupport: AccessibilitySupport;\n\tprivate _editContext: AbstractEditContext;\n\tprivate readonly _editContextClipboardListeners = new DisposableStore();\n\tprivate readonly _pointerHandler: PointerHandler;\n\n\t// Clipboard events relayed from editContext\n\tprivate readonly _onWillCopy = this._register(new Emitter<IClipboardCopyEvent>());\n\tpublic readonly onWillCopy: Event<IClipboardCopyEvent> = this._onWillCopy.event;\n\n\tprivate readonly _onWillCut = this._register(new Emitter<IClipboardCopyEvent>());\n\tpublic readonly onWillCut: Event<IClipboardCopyEvent> = this._onWillCut.event;\n\n\tprivate readonly _onWillPaste = this._register(new Emitter<IClipboardPasteEvent>());\n\tpublic readonly onWillPaste: Event<IClipboardPasteEvent> = this._onWillPaste.event;\n\n\t// Dom nodes\n\tprivate readonly _linesContent: FastDomNode<HTMLElement>;\n\tpublic readonly domNode: FastDomNode<HTMLElement>;\n\tprivate readonly _overflowGuardContainer: FastDomNode<HTMLElement>;\n\n\t// Actual mutable state\n\tprivate _shouldRecomputeGlyphMarginLanes: boolean = false;\n\tprivate _renderAnimationFrame: IDisposable | null;\n\tprivate _ownerID: string;\n\n\tconstructor(\n\t\teditorContainer: HTMLElement,\n\t\townerID: string,\n\t\tcommandDelegate: ICommandDelegate,\n\t\tconfiguration: IEditorConfiguration,\n\t\tcolorTheme: IColorTheme,\n\t\tmodel: IViewModel,\n\t\tuserInputEvents: ViewUserInputEvents,\n\t\toverflowWidgetsDomNode: HTMLElement | undefined,\n\t\t@IInstantiationService private readonly _instantiationService: IInstantiationService\n\t) {\n\t\tsuper();\n\t\tthis._ownerID = ownerID;\n\n\t\tthis._widgetFocusTracker = this._register(\n\t\t\tnew CodeEditorWidgetFocusTracker(editorContainer, overflowWidgetsDomNode)\n\t\t);\n\t\tthis._register(this._widgetFocusTracker.onChange(() => {\n\t\t\tthis._context.viewModel.setHasWidgetFocus(this._widgetFocusTracker.hasFocus());\n\t\t}));\n\n\t\tthis._selections = [new Selection(1, 1, 1, 1)];\n\t\tthis._renderAnimationFrame = null;\n\n\t\tthis._overflowGuardContainer = createFastDomNode(document.createElement('div'));\n\t\tPartFingerprints.write(this._overflowGuardContainer, PartFingerprint.OverflowGuard);\n\t\tthis._overflowGuardContainer.setClassName('overflow-guard');\n\n\t\tthis._viewController = new ViewController(configuration, model, userInputEvents, commandDelegate);\n\n\t\t// The view context is passed on to most classes (basically to reduce param. counts in ctors)\n\t\tthis._context = new ViewContext(configuration, colorTheme, model);\n\n\t\t// Ensure the view is the first event handler in order to update the layout\n\t\tthis._context.addEventHandler(this);\n\n\t\tthis._viewParts = [];\n\n\t\t// Keyboard handler\n\t\tthis._editContextEnabled = this._context.configuration.options.get(EditorOption.effectiveEditContext);\n\t\tthis._accessibilitySupport = this._context.configuration.options.get(EditorOption.accessibilitySupport);\n\t\tthis._editContext = this._instantiateEditContext();\n\t\tthis._connectEditContextClipboardEvents();\n\n\t\tthis._viewParts.push(this._editContext);\n\n\t\t// These two dom nodes must be constructed up front, since references are needed in the layout provider (scrolling & co.)\n\t\tthis._linesContent = createFastDomNode(document.createElement('div'));\n\t\tthis._linesContent.setClassName('lines-content' + ' monaco-editor-background');\n\t\tthis._linesContent.setPosition('absolute');\n\n\t\tthis.domNode = createFastDomNode(document.createElement('div'));\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\t// Set role 'code' for better screen reader support https://github.com/microsoft/vscode/issues/93438\n\t\tthis.domNode.setAttribute('role', 'code');\n\n\t\tif (this._context.configuration.options.get(EditorOption.experimentalGpuAcceleration) === 'on') {\n\t\t\tthis._viewGpuContext = this._instantiationService.createInstance(ViewGpuContext, this._context);\n\t\t}\n\n\t\tthis._scrollbar = new EditorScrollbar(this._context, this._linesContent, this.domNode, this._overflowGuardContainer);\n\t\tthis._viewParts.push(this._scrollbar);\n\n\t\t// View Lines\n\t\tthis._viewLines = new ViewLines(this._context, this._viewGpuContext, this._linesContent);\n\t\tif (this._viewGpuContext) {\n\t\t\tthis._viewLinesGpu = this._instantiationService.createInstance(ViewLinesGpu, this._context, this._viewGpuContext);\n\t\t}\n\n\t\t// View Zones\n\t\tthis._viewZones = new ViewZones(this._context);\n\t\tthis._viewParts.push(this._viewZones);\n\n\t\t// Decorations overview ruler\n\t\tconst decorationsOverviewRuler = new DecorationsOverviewRuler(this._context);\n\t\tthis._viewParts.push(decorationsOverviewRuler);\n\n\n\t\tconst scrollDecoration = new ScrollDecorationViewPart(this._context);\n\t\tthis._viewParts.push(scrollDecoration);\n\n\t\tconst contentViewOverlays = new ContentViewOverlays(this._context);\n\t\tthis._viewParts.push(contentViewOverlays);\n\t\tcontentViewOverlays.addDynamicOverlay(new CurrentLineHighlightOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new SelectionsOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new IndentGuidesOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new DecorationsOverlay(this._context));\n\t\tcontentViewOverlays.addDynamicOverlay(new WhitespaceOverlay(this._context));\n\n\t\tconst marginViewOverlays = new MarginViewOverlays(this._context);\n\t\tthis._viewParts.push(marginViewOverlays);\n\t\tmarginViewOverlays.addDynamicOverlay(new CurrentLineMarginHighlightOverlay(this._context));\n\t\tmarginViewOverlays.addDynamicOverlay(new MarginViewLineDecorationsOverlay(this._context));\n\t\tmarginViewOverlays.addDynamicOverlay(new LinesDecorationsOverlay(this._context));\n\t\tmarginViewOverlays.addDynamicOverlay(new LineNumbersOverlay(this._context));\n\t\tif (this._viewGpuContext) {\n\t\t\tmarginViewOverlays.addDynamicOverlay(new GpuMarkOverlay(this._context, this._viewGpuContext));\n\t\t}\n\n\t\t// Glyph margin widgets\n\t\tthis._glyphMarginWidgets = new GlyphMarginWidgets(this._context);\n\t\tthis._viewParts.push(this._glyphMarginWidgets);\n\n\t\tconst margin = new Margin(this._context);\n\t\tmargin.getDomNode().appendChild(this._viewZones.marginDomNode);\n\t\tmargin.getDomNode().appendChild(marginViewOverlays.getDomNode());\n\t\tmargin.getDomNode().appendChild(this._glyphMarginWidgets.domNode);\n\t\tthis._viewParts.push(margin);\n\n\t\t// Content widgets\n\t\tthis._contentWidgets = new ViewContentWidgets(this._context, this.domNode);\n\t\tthis._viewParts.push(this._contentWidgets);\n\n\t\tthis._viewCursors = new ViewCursors(this._context);\n\t\tthis._viewParts.push(this._viewCursors);\n\n\t\t// Overlay widgets\n\t\tthis._overlayWidgets = new ViewOverlayWidgets(this._context, this.domNode);\n\t\tthis._viewParts.push(this._overlayWidgets);\n\n\t\tconst rulers = this._viewGpuContext\n\t\t\t? new RulersGpu(this._context, this._viewGpuContext)\n\t\t\t: new Rulers(this._context);\n\t\tthis._viewParts.push(rulers);\n\n\t\tconst blockOutline = new BlockDecorations(this._context);\n\t\tthis._viewParts.push(blockOutline);\n\n\t\tconst minimap = new Minimap(this._context);\n\t\tthis._viewParts.push(minimap);\n\n\t\t// -------------- Wire dom nodes up\n\n\t\tif (decorationsOverviewRuler) {\n\t\t\tconst overviewRulerData = this._scrollbar.getOverviewRulerLayoutInfo();\n\t\t\toverviewRulerData.parent.insertBefore(decorationsOverviewRuler.getDomNode(), overviewRulerData.insertBefore);\n\t\t}\n\n\t\tthis._linesContent.appendChild(contentViewOverlays.getDomNode());\n\t\tif ('domNode' in rulers) {\n\t\t\tthis._linesContent.appendChild(rulers.domNode);\n\t\t}\n\t\tthis._linesContent.appendChild(this._viewZones.domNode);\n\t\tthis._linesContent.appendChild(this._viewLines.getDomNode());\n\t\tthis._linesContent.appendChild(this._contentWidgets.domNode);\n\t\tthis._linesContent.appendChild(this._viewCursors.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(margin.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(this._scrollbar.getDomNode());\n\t\tif (this._viewGpuContext) {\n\t\t\tthis._overflowGuardContainer.appendChild(this._viewGpuContext.canvas);\n\t\t}\n\t\tthis._overflowGuardContainer.appendChild(scrollDecoration.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(this._overlayWidgets.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(minimap.getDomNode());\n\t\tthis._overflowGuardContainer.appendChild(blockOutline.domNode);\n\t\tthis.domNode.appendChild(this._overflowGuardContainer);\n\n\t\tif (overflowWidgetsDomNode) {\n\t\t\toverflowWidgetsDomNode.appendChild(this._contentWidgets.overflowingContentWidgetsDomNode.domNode);\n\t\t\toverflowWidgetsDomNode.appendChild(this._overlayWidgets.overflowingOverlayWidgetsDomNode.domNode);\n\t\t} else {\n\t\t\tthis.domNode.appendChild(this._contentWidgets.overflowingContentWidgetsDomNode);\n\t\t\tthis.domNode.appendChild(this._overlayWidgets.overflowingOverlayWidgetsDomNode);\n\t\t}\n\n\t\tthis._applyLayout();\n\n\t\t// Pointer handler\n\t\tthis._pointerHandler = this._register(new PointerHandler(this._context, this._viewController, this._createPointerHandlerHelper()));\n\t}\n\n\tprivate _instantiateEditContext(): AbstractEditContext {\n\t\tconst usingExperimentalEditContext = this._context.configuration.options.get(EditorOption.effectiveEditContext);\n\t\tif (usingExperimentalEditContext) {\n\t\t\treturn this._instantiationService.createInstance(NativeEditContext, this._ownerID, this._context, this._overflowGuardContainer, this._viewController, this._createTextAreaHandlerHelper());\n\t\t} else {\n\t\t\treturn this._instantiationService.createInstance(TextAreaEditContext, this._ownerID, this._context, this._overflowGuardContainer, this._viewController, this._createTextAreaHandlerHelper());\n\t\t}\n\t}\n\n\tprivate _updateEditContext(): void {\n\t\tconst editContextEnabled = this._context.configuration.options.get(EditorOption.effectiveEditContext);\n\t\tconst accessibilitySupport = this._context.configuration.options.get(EditorOption.accessibilitySupport);\n\t\tif (this._editContextEnabled === editContextEnabled && this._accessibilitySupport === accessibilitySupport) {\n\t\t\treturn;\n\t\t}\n\t\tthis._editContextEnabled = editContextEnabled;\n\t\tthis._accessibilitySupport = accessibilitySupport;\n\t\tconst isEditContextFocused = this._editContext.isFocused();\n\t\tconst indexOfEditContext = this._viewParts.indexOf(this._editContext);\n\t\tthis._editContext.dispose();\n\t\tthis._editContext = this._instantiateEditContext();\n\t\tthis._connectEditContextClipboardEvents();\n\t\tif (isEditContextFocused) {\n\t\t\tthis._editContext.focus();\n\t\t}\n\t\tif (indexOfEditContext !== -1) {\n\t\t\tthis._viewParts.splice(indexOfEditContext, 1, this._editContext);\n\t\t}\n\t}\n\n\tprivate _connectEditContextClipboardEvents(): void {\n\t\t// Dispose old listeners\n\t\tthis._editContextClipboardListeners.clear();\n\n\t\t// Connect to current edit context's clipboard events\n\t\tthis._editContextClipboardListeners.add(this._editContext.onWillCopy(e => this._onWillCopy.fire(e)));\n\t\tthis._editContextClipboardListeners.add(this._editContext.onWillCut(e => this._onWillCut.fire(e)));\n\t\tthis._editContextClipboardListeners.add(this._editContext.onWillPaste(e => this._onWillPaste.fire(e)));\n\t}\n\n\tprivate _computeGlyphMarginLanes(): IGlyphMarginLanesModel {\n\t\tconst model = this._context.viewModel.model;\n\t\tconst laneModel = this._context.viewModel.glyphLanes;\n\t\ttype Glyph = { range: Range; lane: GlyphMarginLane; persist?: boolean };\n\t\tlet glyphs: Glyph[] = [];\n\t\tlet maxLineNumber = 0;\n\n\t\t// Add all margin decorations\n\t\tglyphs = glyphs.concat(model.getAllMarginDecorations().map((decoration) => {\n\t\t\tconst lane = decoration.options.glyphMargin?.position ?? GlyphMarginLane.Center;\n\t\t\tmaxLineNumber = Math.max(maxLineNumber, decoration.range.endLineNumber);\n\t\t\treturn { range: decoration.range, lane, persist: decoration.options.glyphMargin?.persistLane };\n\t\t}));\n\n\t\t// Add all glyph margin widgets\n\t\tglyphs = glyphs.concat(this._glyphMarginWidgets.getWidgets().map((widget) => {\n\t\t\tconst range = model.validateRange(widget.preference.range);\n\t\t\tmaxLineNumber = Math.max(maxLineNumber, range.endLineNumber);\n\t\t\treturn { range, lane: widget.preference.lane };\n\t\t}));\n\n\t\t// Sorted by their start position\n\t\tglyphs.sort((a, b) => Range.compareRangesUsingStarts(a.range, b.range));\n\n\t\tlaneModel.reset(maxLineNumber);\n\t\tfor (const glyph of glyphs) {\n\t\t\tlaneModel.push(glyph.lane, glyph.range, glyph.persist);\n\t\t}\n\n\t\treturn laneModel;\n\t}\n\n\tprivate _createPointerHandlerHelper(): IPointerHandlerHelper {\n\t\treturn {\n\t\t\tviewDomNode: this.domNode.domNode,\n\t\t\tlinesContentDomNode: this._linesContent.domNode,\n\t\t\tviewLinesDomNode: this._viewLines.getDomNode().domNode,\n\t\t\tviewLinesGpu: this._viewLinesGpu,\n\n\t\t\tfocusTextArea: () => {\n\t\t\t\tthis.focus();\n\t\t\t},\n\n\t\t\tdispatchTextAreaEvent: (event: CustomEvent) => {\n\t\t\t\tthis._editContext.domNode.domNode.dispatchEvent(event);\n\t\t\t},\n\n\t\t\tgetLastRenderData: (): PointerHandlerLastRenderData => {\n\t\t\t\tconst lastViewCursorsRenderData = this._viewCursors.getLastRenderData() || [];\n\t\t\t\tconst lastTextareaPosition = this._editContext.getLastRenderData();\n\t\t\t\treturn new PointerHandlerLastRenderData(lastViewCursorsRenderData, lastTextareaPosition);\n\t\t\t},\n\t\t\trenderNow: (): void => {\n\t\t\t\tthis.render(true, false);\n\t\t\t},\n\t\t\tshouldSuppressMouseDownOnViewZone: (viewZoneId: string) => {\n\t\t\t\treturn this._viewZones.shouldSuppressMouseDownOnViewZone(viewZoneId);\n\t\t\t},\n\t\t\tshouldSuppressMouseDownOnWidget: (widgetId: string) => {\n\t\t\t\treturn this._contentWidgets.shouldSuppressMouseDownOnWidget(widgetId);\n\t\t\t},\n\t\t\tgetPositionFromDOMInfo: (spanNode: HTMLElement, offset: number) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\treturn this._viewLines.getPositionFromDOMInfo(spanNode, offset);\n\t\t\t},\n\n\t\t\tvisibleRangeForPosition: (lineNumber: number, column: number) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\tconst position = new Position(lineNumber, column);\n\t\t\t\treturn this._viewLines.visibleRangeForPosition(position) ?? this._viewLinesGpu?.visibleRangeForPosition(position) ?? null;\n\t\t\t},\n\n\t\t\tgetLineWidth: (lineNumber: number) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\tif (this._viewLinesGpu) {\n\t\t\t\t\tconst result = this._viewLinesGpu.getLineWidth(lineNumber);\n\t\t\t\t\tif (result !== undefined) {\n\t\t\t\t\t\treturn result;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn this._viewLines.getLineWidth(lineNumber);\n\t\t\t}\n\t\t};\n\t}\n\n\tprivate _createTextAreaHandlerHelper(): IVisibleRangeProvider {\n\t\treturn {\n\t\t\tvisibleRangeForPosition: (position: Position) => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\treturn this._viewLines.visibleRangeForPosition(position);\n\t\t\t},\n\t\t\tlinesVisibleRangesForRange: (range: Range, includeNewLines: boolean): LineVisibleRanges[] | null => {\n\t\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t\t\treturn this._viewLines.linesVisibleRangesForRange(range, includeNewLines);\n\t\t\t}\n\t\t};\n\t}\n\n\tprivate _applyLayout(): void {\n\t\tconst options = this._context.configuration.options;\n\t\tconst layoutInfo = options.get(EditorOption.layoutInfo);\n\n\t\tthis.domNode.setWidth(layoutInfo.width);\n\t\tthis.domNode.setHeight(layoutInfo.height);\n\n\t\tthis._overflowGuardContainer.setWidth(layoutInfo.width);\n\t\tthis._overflowGuardContainer.setHeight(layoutInfo.height);\n\n\t\t// https://stackoverflow.com/questions/38905916/content-in-google-chrome-larger-than-16777216-px-not-being-rendered\n\t\tthis._linesContent.setWidth(16777216);\n\t\tthis._linesContent.setHeight(16777216);\n\t}\n\n\tprivate _getEditorClassName() {\n\t\tconst focused = this._editContext.isFocused() ? ' focused' : '';\n\t\treturn this._context.configuration.options.get(EditorOption.editorClassName) + ' ' + getThemeTypeSelector(this._context.theme.type) + focused;\n\t}\n\n\t// --- begin event handlers\n\tpublic override handleEvents(events: viewEvents.ViewEvent[]): void {\n\t\tsuper.handleEvents(events);\n\t\tthis._scheduleRender();\n\t}\n\tpublic override onConfigurationChanged(e: viewEvents.ViewConfigurationChangedEvent): boolean {\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\tthis._updateEditContext();\n\t\tthis._applyLayout();\n\t\treturn false;\n\t}\n\tpublic override onCursorStateChanged(e: viewEvents.ViewCursorStateChangedEvent): boolean {\n\t\tthis._selections = e.selections;\n\t\treturn false;\n\t}\n\tpublic override onDecorationsChanged(e: viewEvents.ViewDecorationsChangedEvent): boolean {\n\t\tif (e.affectsGlyphMargin) {\n\t\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\t}\n\t\treturn false;\n\t}\n\tpublic override onFocusChanged(e: viewEvents.ViewFocusChangedEvent): boolean {\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\treturn false;\n\t}\n\tpublic override onThemeChanged(e: viewEvents.ViewThemeChangedEvent): boolean {\n\t\tthis._context.theme.update(e.theme);\n\t\tthis.domNode.setClassName(this._getEditorClassName());\n\t\treturn false;\n\t}\n\n\t// --- end event handlers\n\n\tpublic override dispose(): void {\n\t\tif (this._renderAnimationFrame !== null) {\n\t\t\tthis._renderAnimationFrame.dispose();\n\t\t\tthis._renderAnimationFrame = null;\n\t\t}\n\n\t\t// Dispose clipboard event listeners\n\t\tthis._editContextClipboardListeners.dispose();\n\n\t\tthis._contentWidgets.overflowingContentWidgetsDomNode.domNode.remove();\n\t\tthis._overlayWidgets.overflowingOverlayWidgetsDomNode.domNode.remove();\n\n\t\tthis._context.removeEventHandler(this);\n\t\tthis._viewGpuContext?.dispose();\n\n\t\tthis._viewLines.dispose();\n\t\tthis._viewLinesGpu?.dispose();\n\n\t\t// Destroy view parts\n\t\tfor (const viewPart of this._viewParts) {\n\t\t\tviewPart.dispose();\n\t\t}\n\n\t\tsuper.dispose();\n\t}\n\n\tprivate _scheduleRender(): void {\n\t\tif (this._store.isDisposed) {\n\t\t\tthrow new BugIndicatingError();\n\t\t}\n\t\tif (this._renderAnimationFrame === null) {\n\t\t\t// TODO: workaround fix for https://github.com/microsoft/vscode/issues/229825\n\t\t\tif (this._editContext instanceof NativeEditContext) {\n\t\t\t\tthis._editContext.setEditContextOnDomNode();\n\t\t\t}\n\t\t\tconst rendering = this._createCoordinatedRendering();\n\t\t\tthis._renderAnimationFrame = EditorRenderingCoordinator.INSTANCE.scheduleCoordinatedRendering({\n\t\t\t\twindow: dom.getWindow(this.domNode?.domNode),\n\t\t\t\tprepareRenderText: () => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\ttry {\n\t\t\t\t\t\treturn rendering.prepareRenderText();\n\t\t\t\t\t} finally {\n\t\t\t\t\t\tthis._renderAnimationFrame = null;\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\trenderText: () => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\treturn rendering.renderText();\n\t\t\t\t},\n\t\t\t\tprepareRender: (viewParts: ViewPart[], ctx: RenderingContext) => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\treturn rendering.prepareRender(viewParts, ctx);\n\t\t\t\t},\n\t\t\t\trender: (viewParts: ViewPart[], ctx: RestrictedRenderingContext) => {\n\t\t\t\t\tif (this._store.isDisposed) {\n\t\t\t\t\t\tthrow new BugIndicatingError();\n\t\t\t\t\t}\n\t\t\t\t\treturn rendering.render(viewParts, ctx);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n\n\tprivate _flushAccumulatedAndRenderNow(): void {\n\t\tconst rendering = this._createCoordinatedRendering();\n\t\tsafeInvokeNoArg(() => rendering.prepareRenderText());\n\t\tconst data = safeInvokeNoArg(() => rendering.renderText());\n\t\tif (data) {\n\t\t\tconst [viewParts, ctx] = data;\n\t\t\tsafeInvokeNoArg(() => rendering.prepareRender(viewParts, ctx));\n\t\t\tsafeInvokeNoArg(() => rendering.render(viewParts, ctx));\n\t\t}\n\t}\n\n\tprivate _getViewPartsToRender(): ViewPart[] {\n\t\tconst result: ViewPart[] = [];\n\t\tlet resultLen = 0;\n\t\tfor (const viewPart of this._viewParts) {\n\t\t\tif (viewPart.shouldRender()) {\n\t\t\t\tresult[resultLen++] = viewPart;\n\t\t\t}\n\t\t}\n\t\treturn result;\n\t}\n\n\tprivate _createCoordinatedRendering() {\n\t\treturn {\n\t\t\tprepareRenderText: () => {\n\t\t\t\tif (this._shouldRecomputeGlyphMarginLanes) {\n\t\t\t\t\tthis._shouldRecomputeGlyphMarginLanes = false;\n\t\t\t\t\tconst model = this._computeGlyphMarginLanes();\n\t\t\t\t\tthis._context.configuration.setGlyphMarginDecorationLaneCount(model.requiredLanes);\n\t\t\t\t}\n\t\t\t\tinputLatency.onRenderStart();\n\t\t\t},\n\t\t\trenderText: (): [ViewPart[], RenderingContext] | null => {\n\t\t\t\tif (!this.domNode.domNode.isConnected) {\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t\tlet viewPartsToRender = this._getViewPartsToRender();\n\t\t\t\tif (!this._viewLines.shouldRender() && viewPartsToRender.length === 0) {\n\t\t\t\t\t// Nothing to render\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t\tconst partialViewportData = this._context.viewLayout.getLinesViewportData();\n\t\t\t\tthis._context.viewModel.setViewport(partialViewportData.startLineNumber, partialViewportData.endLineNumber, partialViewportData.centeredLineNumber);\n\n\t\t\t\tconst viewportData = new ViewportData(\n\t\t\t\t\tthis._selections,\n\t\t\t\t\tpartialViewportData,\n\t\t\t\t\tthis._context.viewLayout.getWhitespaceViewportData(),\n\t\t\t\t\tthis._context.viewModel\n\t\t\t\t);\n\n\t\t\t\tif (this._contentWidgets.shouldRender()) {\n\t\t\t\t\t// Give the content widgets a chance to set their max width before a possible synchronous layout\n\t\t\t\t\tthis._contentWidgets.onBeforeRender(viewportData);\n\t\t\t\t}\n\n\t\t\t\tif (this._viewLines.shouldRender()) {\n\t\t\t\t\tthis._viewLines.renderText(viewportData);\n\t\t\t\t\tthis._viewLines.onDidRender();\n\n\t\t\t\t\t// Rendering of viewLines might cause scroll events to occur, so collect view parts to render again\n\t\t\t\t\tviewPartsToRender = this._getViewPartsToRender();\n\t\t\t\t}\n\n\t\t\t\tif (this._viewLinesGpu?.shouldRender()) {\n\t\t\t\t\tthis._viewLinesGpu.renderText(viewportData);\n\t\t\t\t\tthis._viewLinesGpu.onDidRender();\n\t\t\t\t}\n\n\t\t\t\treturn [viewPartsToRender, new RenderingContext(this._context.viewLayout, viewportData, this._viewLines, this._viewLinesGpu)];\n\t\t\t},\n\t\t\tprepareRender: (viewPartsToRender: ViewPart[], ctx: RenderingContext) => {\n\t\t\t\tfor (const viewPart of viewPartsToRender) {\n\t\t\t\t\tviewPart.prepareRender(ctx);\n\t\t\t\t}\n\t\t\t},\n\t\t\trender: (viewPartsToRender: ViewPart[], ctx: RestrictedRenderingContext) => {\n\t\t\t\tfor (const viewPart of viewPartsToRender) {\n\t\t\t\t\tviewPart.render(ctx);\n\t\t\t\t\tviewPart.onDidRender();\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t}\n\n\t// --- BEGIN CodeEditor helpers\n\n\tpublic delegateVerticalScrollbarPointerDown(browserEvent: PointerEvent): void {\n\t\tthis._scrollbar.delegateVerticalScrollbarPointerDown(browserEvent);\n\t}\n\n\tpublic delegateScrollFromMouseWheelEvent(browserEvent: IMouseWheelEvent) {\n\t\tthis._scrollbar.delegateScrollFromMouseWheelEvent(browserEvent);\n\t}\n\n\tpublic restoreState(scrollPosition: { scrollLeft: number; scrollTop: number }): void {\n\t\tthis._context.viewModel.viewLayout.setScrollPosition({\n\t\t\tscrollTop: scrollPosition.scrollTop,\n\t\t\tscrollLeft: scrollPosition.scrollLeft\n\t\t}, ScrollType.Immediate);\n\t\tthis._context.viewModel.visibleLinesStabilized();\n\t}\n\n\tpublic getOffsetForColumn(modelLineNumber: number, modelColumn: number): number {\n\t\tconst modelPosition = this._context.viewModel.model.validatePosition({\n\t\t\tlineNumber: modelLineNumber,\n\t\t\tcolumn: modelColumn\n\t\t});\n\t\tconst viewPosition = this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(modelPosition);\n\t\tthis._flushAccumulatedAndRenderNow();\n\t\tconst visibleRange = this._viewLines.visibleRangeForPosition(new Position(viewPosition.lineNumber, viewPosition.column));\n\t\tif (!visibleRange) {\n\t\t\treturn -1;\n\t\t}\n\t\treturn visibleRange.left;\n\t}\n\n\tpublic getLineWidth(modelLineNumber: number): number {\n\t\tconst model = this._context.viewModel.model;\n\t\tconst viewLine = this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(new Position(modelLineNumber, model.getLineMaxColumn(modelLineNumber))).lineNumber;\n\t\tthis._flushAccumulatedAndRenderNow();\n\t\tconst width = this._viewLines.getLineWidth(viewLine);\n\n\t\treturn width;\n\t}\n\n\tpublic resetLineWidthCaches(): void {\n\t\tthis._viewLines.resetLineWidthCaches();\n\t}\n\n\tpublic getTargetAtClientPoint(clientX: number, clientY: number): IMouseTarget | null {\n\t\tconst mouseTarget = this._pointerHandler.getTargetAtClientPoint(clientX, clientY);\n\t\tif (!mouseTarget) {\n\t\t\treturn null;\n\t\t}\n\t\treturn ViewUserInputEvents.convertViewToModelMouseTarget(mouseTarget, this._context.viewModel.coordinatesConverter);\n\t}\n\n\tpublic createOverviewRuler(cssClassName: string): OverviewRuler {\n\t\treturn new OverviewRuler(this._context, cssClassName);\n\t}\n\n\tpublic change(callback: (changeAccessor: IViewZoneChangeAccessor) => unknown): void {\n\t\tthis._viewZones.changeViewZones(callback);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic render(now: boolean, everything: boolean): void {\n\t\tif (everything) {\n\t\t\t// Force everything to render...\n\t\t\tthis._viewLines.forceShouldRender();\n\t\t\tfor (const viewPart of this._viewParts) {\n\t\t\t\tviewPart.forceShouldRender();\n\t\t\t}\n\t\t}\n\t\tif (now) {\n\t\t\tthis._flushAccumulatedAndRenderNow();\n\t\t} else {\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic writeScreenReaderContent(reason: string): void {\n\t\tthis._editContext.writeScreenReaderContent(reason);\n\t}\n\n\tpublic focus(): void {\n\t\tthis._editContext.focus();\n\t}\n\n\tpublic isFocused(): boolean {\n\t\treturn this._editContext.isFocused();\n\t}\n\n\tpublic isWidgetFocused(): boolean {\n\t\treturn this._widgetFocusTracker.hasFocus();\n\t}\n\n\tpublic setAriaOptions(options: IEditorAriaOptions): void {\n\t\tthis._editContext.setAriaOptions(options);\n\t}\n\n\tpublic addContentWidget(widgetData: IContentWidgetData): void {\n\t\tthis._contentWidgets.addWidget(widgetData.widget);\n\t\tthis.layoutContentWidget(widgetData);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic layoutContentWidget(widgetData: IContentWidgetData): void {\n\t\tthis._contentWidgets.setWidgetPosition(\n\t\t\twidgetData.widget,\n\t\t\twidgetData.position?.position ?? null,\n\t\t\twidgetData.position?.secondaryPosition ?? null,\n\t\t\twidgetData.position?.preference ?? null,\n\t\t\twidgetData.position?.positionAffinity ?? null\n\t\t);\n\t\tif (this._contentWidgets.shouldRender()) {\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic removeContentWidget(widgetData: IContentWidgetData): void {\n\t\tthis._contentWidgets.removeWidget(widgetData.widget);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic addOverlayWidget(widgetData: IOverlayWidgetData): void {\n\t\tthis._overlayWidgets.addWidget(widgetData.widget);\n\t\tthis.layoutOverlayWidget(widgetData);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic layoutOverlayWidget(widgetData: IOverlayWidgetData): void {\n\t\tconst shouldRender = this._overlayWidgets.setWidgetPosition(widgetData.widget, widgetData.position);\n\t\tif (shouldRender) {\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic removeOverlayWidget(widgetData: IOverlayWidgetData): void {\n\t\tthis._overlayWidgets.removeWidget(widgetData.widget);\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic addGlyphMarginWidget(widgetData: IGlyphMarginWidgetData): void {\n\t\tthis._glyphMarginWidgets.addWidget(widgetData.widget);\n\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\tthis._scheduleRender();\n\t}\n\n\tpublic layoutGlyphMarginWidget(widgetData: IGlyphMarginWidgetData): void {\n\t\tconst newPreference = widgetData.position;\n\t\tconst shouldRender = this._glyphMarginWidgets.setWidgetPosition(widgetData.widget, newPreference);\n\t\tif (shouldRender) {\n\t\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\t\tthis._scheduleRender();\n\t\t}\n\t}\n\n\tpublic removeGlyphMarginWidget(widgetData: IGlyphMarginWidgetData): void {\n\t\tthis._glyphMarginWidgets.removeWidget(widgetData.widget);\n\t\tthis._shouldRecomputeGlyphMarginLanes = true;\n\t\tthis._scheduleRender();\n\t}\n\n\t// --- END CodeEditor helpers\n\n}\n\nfunction safeInvokeNoArg<T>(func: () => T): T | null {\n\ttry {\n\t\treturn func();\n\t} catch (e) {\n\t\tonUnexpectedError(e);\n\t\treturn null;\n\t}\n}\n\ninterface ICoordinatedRendering {\n\treadonly window: CodeWindow;\n\tprepareRenderText(): void;\n\trenderText(): [ViewPart[], RenderingContext] | null;\n\tprepareRender(viewParts: ViewPart[], ctx: RenderingContext): void;\n\trender(viewParts: ViewPart[], ctx: RestrictedRenderingContext): void;\n}\n\nclass EditorRenderingCoordinator {\n\n\tpublic static INSTANCE = new EditorRenderingCoordinator();\n\n\tprivate _coordinatedRenderings: ICoordinatedRendering[] = [];\n\tprivate _animationFrameRunners = new Map<CodeWindow, IDisposable>();\n\n\tprivate constructor() { }\n\n\tscheduleCoordinatedRendering(rendering: ICoordinatedRendering): IDisposable {\n\t\tthis._coordinatedRenderings.push(rendering);\n\t\tthis._scheduleRender(rendering.window);\n\t\treturn {\n\t\t\tdispose: () => {\n\t\t\t\tconst renderingIndex = this._coordinatedRenderings.indexOf(rendering);\n\t\t\t\tif (renderingIndex === -1) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tthis._coordinatedRenderings.splice(renderingIndex, 1);\n\n\t\t\t\tif (this._coordinatedRenderings.length === 0) {\n\t\t\t\t\t// There are no more renderings to coordinate => cancel animation frames\n\t\t\t\t\tfor (const [_, disposable] of this._animationFrameRunners) {\n\t\t\t\t\t\tdisposable.dispose();\n\t\t\t\t\t}\n\t\t\t\t\tthis._animationFrameRunners.clear();\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t}\n\n\tprivate _scheduleRender(window: CodeWindow): void {\n\t\tif (!this._animationFrameRunners.has(window)) {\n\t\t\tconst runner = () => {\n\t\t\t\tthis._animationFrameRunners.delete(window);\n\t\t\t\tthis._onRenderScheduled();\n\t\t\t};\n\t\t\tthis._animationFrameRunners.set(window, dom.runAtThisOrScheduleAtNextAnimationFrame(window, runner, 100));\n\t\t}\n\t}\n\n\tprivate _onRenderScheduled(): void {\n\t\tconst coordinatedRenderings = this._coordinatedRenderings.slice(0);\n\t\tthis._coordinatedRenderings = [];\n\n\t\tfor (const rendering of coordinatedRenderings) {\n\t\t\tsafeInvokeNoArg(() => rendering.prepareRenderText());\n\t\t}\n\n\t\tconst datas: ([ViewPart[], RenderingContext] | null)[] = [];\n\t\tfor (let i = 0, len = coordinatedRenderings.length; i < len; i++) {\n\t\t\tconst rendering = coordinatedRenderings[i];\n\t\t\tdatas[i] = safeInvokeNoArg(() => rendering.renderText());\n\t\t}\n\n\t\tfor (let i = 0, len = coordinatedRenderings.length; i < len; i++) {\n\t\t\tconst rendering = coordinatedRenderings[i];\n\t\t\tconst data = datas[i];\n\t\t\tif (!data) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst [viewParts, ctx] = data;\n\t\t\tsafeInvokeNoArg(() => rendering.prepareRender(viewParts, ctx));\n\t\t}\n\n\t\tfor (let i = 0, len = coordinatedRenderings.length; i < len; i++) {\n\t\t\tconst rendering = coordinatedRenderings[i];\n\t\t\tconst data = datas[i];\n\t\t\tif (!data) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst [viewParts, ctx] = data;\n\t\t\tsafeInvokeNoArg(() => rendering.render(viewParts, ctx));\n\t\t}\n\t}\n}\n\nclass CodeEditorWidgetFocusTracker extends Disposable {\n\n\tprivate _hasDomElementFocus: boolean;\n\tprivate readonly _domFocusTracker: dom.IFocusTracker;\n\tprivate readonly _overflowWidgetsDomNode: dom.IFocusTracker | undefined;\n\n\tprivate readonly _onChange: Emitter<void> = this._register(new Emitter<void>());\n\tpublic readonly onChange: Event<void> = this._onChange.event;\n\n\tprivate _overflowWidgetsDomNodeHasFocus: boolean;\n\n\tprivate _hadFocus: boolean | undefined = undefined;\n\n\tconstructor(domElement: HTMLElement, overflowWidgetsDomNode: HTMLElement | undefined) {\n\t\tsuper();\n\n\t\tthis._hasDomElementFocus = false;\n\t\tthis._domFocusTracker = this._register(dom.trackFocus(domElement));\n\n\t\tthis._overflowWidgetsDomNodeHasFocus = false;\n\n\t\tthis._register(this._domFocusTracker.onDidFocus(() => {\n\t\t\tthis._hasDomElementFocus = true;\n\t\t\tthis._update();\n\t\t}));\n\t\tthis._register(this._domFocusTracker.onDidBlur(() => {\n\t\t\tthis._hasDomElementFocus = false;\n\t\t\tthis._update();\n\t\t}));\n\n\t\tif (overflowWidgetsDomNode) {\n\t\t\tthis._overflowWidgetsDomNode = this._register(dom.trackFocus(overflowWidgetsDomNode));\n\t\t\tthis._register(this._overflowWidgetsDomNode.onDidFocus(() => {\n\t\t\t\tthis._overflowWidgetsDomNodeHasFocus = true;\n\t\t\t\tthis._update();\n\t\t\t}));\n\t\t\tthis._register(this._overflowWidgetsDomNode.onDidBlur(() => {\n\t\t\t\tthis._overflowWidgetsDomNodeHasFocus = false;\n\t\t\t\tthis._update();\n\t\t\t}));\n\t\t}\n\t}\n\n\tprivate _update() {\n\t\tconst focused = this._hasDomElementFocus || this._overflowWidgetsDomNodeHasFocus;\n\t\tif (this._hadFocus !== focused) {\n\t\t\tthis._hadFocus = focused;\n\t\t\tthis._onChange.fire(undefined);\n\t\t}\n\t}\n\n\tpublic hasFocus(): boolean {\n\t\treturn this._hadFocus ?? false;\n\t}\n}\n"]}
|
|
@@ -236,6 +236,9 @@ export class ViewLine {
|
|
|
236
236
|
}
|
|
237
237
|
return this._renderedViewLine.getColumnOfNodeOffset(spanNode, offset);
|
|
238
238
|
}
|
|
239
|
+
resetCachedWidth() {
|
|
240
|
+
this._renderedViewLine?.resetCachedWidth();
|
|
241
|
+
}
|
|
239
242
|
}
|
|
240
243
|
/**
|
|
241
244
|
* A rendered line which is guaranteed to contain only regular ASCII and is rendered with a monospace font.
|
|
@@ -272,6 +275,9 @@ class FastRenderedViewLine {
|
|
|
272
275
|
getWidthIsFast() {
|
|
273
276
|
return (this.input.lineContent.length < 300 /* Constants.MaxMonospaceDistance */) || this._cachedWidth !== -1;
|
|
274
277
|
}
|
|
278
|
+
resetCachedWidth() {
|
|
279
|
+
this._cachedWidth = -1;
|
|
280
|
+
}
|
|
275
281
|
monospaceAssumptionsAreValid() {
|
|
276
282
|
if (!this.domNode) {
|
|
277
283
|
return monospaceAssumptionsAreValid;
|
|
@@ -379,6 +385,14 @@ class RenderedViewLine {
|
|
|
379
385
|
}
|
|
380
386
|
return true;
|
|
381
387
|
}
|
|
388
|
+
resetCachedWidth() {
|
|
389
|
+
this._cachedWidth = -1;
|
|
390
|
+
if (this._pixelOffsetCache !== null) {
|
|
391
|
+
for (let column = 0, len = this._pixelOffsetCache.length; column < len; column++) {
|
|
392
|
+
this._pixelOffsetCache[column] = -1;
|
|
393
|
+
}
|
|
394
|
+
}
|
|
395
|
+
}
|
|
382
396
|
/**
|
|
383
397
|
* Visible ranges for a model range
|
|
384
398
|
*/
|