microsoft / microsoft/vscode

Change Tab Display Size is unavailable in read-only/diff editors

Open
#332,261 0 comments 0 reactions 1 assignee Claimed by @hediet View on GitHub
Dominant language
TypeScript
Stars
193k
Forks
42.4k
PR merge metrics
PR metrics pending

Description

Type: Bug

# Steps to reproduce

1. Open a file containing tabs in a normal editor.
2. Click the indentation indicator in the status bar (e.g. `Tab Size: 4`).
3. Select Change Tab Display Size and choose another value.
4. Observe that the file contents are not modified; only the way indentation is displayed changes.
5. Open the same file as the read-only side of a Git diff.
6. Click the indentation indicator.

# Actual behavior

The indentation picker is not shown. Instead, VS Code displays:

```
The active code editor is read-only.
```

This prevents using Change Tab Display Size, even though this operation does not require writing to the document.

# Expected behavior

The indentation picker should remain accessible in read-only editors.

Actions that actually modify the document can remain disabled or hidden, while non-modifying actions such as Change Tab Display Size should still be available.

VS Code version: Code 1.134.0 (110a328ea54b42367b803ec53ee0bf52ef26b419, 2026-08-18T18:24:44Z)
OS version: Windows_NT x64 10.0.26200
Modes:

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.