From e3bcfde91b29d929667e4c436ce3fd3ae9dd5163 Mon Sep 17 00:00:00 2001 From: Thomas Seeley Date: Wed, 9 Sep 2026 11:34:24 -0400 Subject: [PATCH 1/2] Send editorTop in membrane editor metrics Gaze sizes the hole including breadcrumbs. The monaco widget top is lower. --- .../browser/membraneEditorMetrics.contribution.ts | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/vs/workbench/contrib/membrane/browser/membraneEditorMetrics.contribution.ts b/src/vs/workbench/contrib/membrane/browser/membraneEditorMetrics.contribution.ts index 4a76b5b20de88..d781b22d3c28f 100644 --- a/src/vs/workbench/contrib/membrane/browser/membraneEditorMetrics.contribution.ts +++ b/src/vs/workbench/contrib/membrane/browser/membraneEditorMetrics.contribution.ts @@ -154,11 +154,22 @@ export class MembraneEditorMetricsContribution extends Disposable implements IWo contentLeft: layoutInfo.contentLeft, contentWidth: layoutInfo.contentWidth, charWidth: fontInfo.typicalHalfwidthCharacterWidth, + editorTop: this._editorTopInWorkbench(editor), lineCount, linePositions, ...(selectionData && { selection: selectionData }), }; } + + /** Monaco widget top relative to the workbench hole Gaze sizes (tabs/breadcrumbs sit above it). */ + private _editorTopInWorkbench(editor: ICodeEditor): number { + const editorDom = editor.getDomNode(); + if (!editorDom) { + return 0; + } + const workbench = editorDom.closest('.monaco-workbench') ?? editorDom; + return editorDom.getBoundingClientRect().top - workbench.getBoundingClientRect().top; + } } registerWorkbenchContribution2( From 26f3111c44cbf6747172634f137458918c2a4665 Mon Sep 17 00:00:00 2001 From: Thomas Seeley Date: Wed, 9 Sep 2026 11:34:26 -0400 Subject: [PATCH 2/2] Default editor scrollbars to 6px --- src/vs/code/browser/workbench/workbench.ts | 2 ++ src/vs/editor/common/config/editorOptions.ts | 9 +++++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/vs/code/browser/workbench/workbench.ts b/src/vs/code/browser/workbench/workbench.ts index a6ecb2026204f..1009eaa81ca15 100644 --- a/src/vs/code/browser/workbench/workbench.ts +++ b/src/vs/code/browser/workbench/workbench.ts @@ -150,6 +150,8 @@ type Writeable = { -readonly [P in keyof T]: T[P] }; config.configurationDefaults = { ...config.configurationDefaults, 'window.commandCenter': false, // Hide command center + 'editor.scrollbar.verticalScrollbarSize': 6, + 'editor.scrollbar.horizontalScrollbarSize': 6, }; diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 9ed16c159c655..a1161a7ec14a4 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -4121,10 +4121,11 @@ class EditorScrollbar extends BaseEditorOption