Skip to content

[5/5] feat: expose per-tab Reading Mode controls and menu eligibility - #5793

Merged
Jocs merged 1 commit into
developfrom
feat/per-tab-reading-mode
Oct 20, 2026
Merged

Jocs merged 1 commit into
developfrom
feat/per-tab-reading-mode

Conversation

@Jocs

@Jocs Jocs commented Oct 19, 2026 •

Copy link
Copy Markdown
Member

Closes #3688
Closes #4532
Closes #3745

Expose per-tab Reading Mode through the document-statistics popover, tab context menu, View menu, command palette and keyboard shortcuts. The switch sits above File Information with separators; each locked tab displays a spaced lock icon. Preferences includes the default mode for existing documents.

Disable editing commands, Paste/Cut, all Paragraph/Format descendants, incompatible view modes and document Find/Replace while reading. Update underlying menu availability before reapplying reading restrictions so unlocking restores the current state, including when leaving source mode. Use command-based menu IDs such as undoMenuItem and pasteMenuItem.

Localize the controls in all 12 supported languages and allow long labels to wrap in the popover. Reading selection and copying retain the existing Markdown/rich-HTML clipboard behavior. Source-to-reading transitions close source mode; unlocking stays in live editing and preserves the startup source preference.

This is the final desktop UI layer. #5799, #5800, #5801 and #5802 are merged; this PR targets develop and supplies the controls and menu integration for those changes. Document search is deferred.

Validation:

  • Desktop unit suite: 107 files / 1154 tests passed.
  • Electron reading, source undo/caret/save-marker and 12-language shell regressions: 34 passed on macOS.
  • Additional regression reproduces disabled focus/typewriter menus after unlocking default reading with startup source enabled; it passes after the fix.
  • Native Electron shortcut input, native text copying and rich-HTML copying passed.
  • ESLint, typecheck and desktop build passed.

Screenshot

Reading Mode switch above File Information, separated by dividers

Requirements, technical notes and review reports remain on the Desktop. No evidence artifacts are committed.

@github-actions

github-actions Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Build artifacts for PR #5793:

Run: https://github.com/marktext/marktext/actions/runs/39448988073

Artifact Size Link
marktext-macos-x64 313.7 MB Download
marktext-linux-x64 667.8 MB Download
marktext-windows-arm64 291.1 MB Download
marktext-linux-arm64 522.6 MB Download
marktext-macos-arm64 300.4 MB Download
marktext-windows-x64 299.3 MB Download

@Jocs Jocs mentioned this pull request Oct 19, 2026
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch 2 times, most recently from fb37007 to d96f4a0 Compare October 19, 2026 23:40
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch from 1ff00bc to 8863ca5 Compare October 20, 2026 08:46
@Jocs Jocs changed the title feat: add per-tab Reading Mode (#3688, #4532, #3745) [5/5] feat: expose per-tab Reading Mode controls and menu eligibility Oct 20, 2026
@Jocs
Jocs changed the base branch from develop to split/marktext-document-mode October 20, 2026 08:46
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch from 8863ca5 to baa1de7 Compare October 20, 2026 08:54
@Jocs
Jocs force-pushed the split/marktext-document-mode branch 2 times, most recently from ddd11b5 to 7916492 Compare October 20, 2026 09:11
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch 2 times, most recently from 8043c5a to e193fc6 Compare October 20, 2026 09:23
@Jocs
Jocs force-pushed the split/marktext-document-mode branch 2 times, most recently from 1ae6697 to caec78a Compare October 20, 2026 09:25
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch from e193fc6 to 74c5fc0 Compare October 20, 2026 09:25
@Jocs
Jocs force-pushed the split/marktext-document-mode branch from caec78a to a0403d9 Compare October 20, 2026 09:37
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch from 74c5fc0 to 85b8038 Compare October 20, 2026 09:37
@Jocs
Jocs force-pushed the split/marktext-document-mode branch from a0403d9 to 74bbad0 Compare October 20, 2026 09:52
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch 2 times, most recently from 71b0b6d to e727aca Compare October 20, 2026 09:57
@Jocs
Jocs force-pushed the split/marktext-document-mode branch 2 times, most recently from 2faeaf5 to 7f6545b Compare October 20, 2026 10:11
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch 2 times, most recently from 248352d to 2323f3f Compare October 20, 2026 10:15
@Jocs
Jocs force-pushed the split/marktext-document-mode branch 2 times, most recently from 39b4068 to a48c98a Compare October 20, 2026 10:22
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch from 2323f3f to 2ed8506 Compare October 20, 2026 10:22
@Jocs
Jocs force-pushed the split/marktext-document-mode branch from a48c98a to 13022a2 Compare October 20, 2026 13:22
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch 5 times, most recently from cd7326f to 5153e09 Compare October 20, 2026 14:39
@Jocs
Jocs force-pushed the split/marktext-document-mode branch from 3d4b2b9 to 5bbbae7 Compare October 20, 2026 14:39
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch from 5153e09 to b854b55 Compare October 20, 2026 15:04
@Jocs
Jocs force-pushed the split/marktext-document-mode branch from 5bbbae7 to 663fe06 Compare October 20, 2026 15:04
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch from b854b55 to 43005b0 Compare October 20, 2026 15:13
@Jocs
Jocs force-pushed the split/marktext-document-mode branch from 663fe06 to ed6369d Compare October 20, 2026 15:13
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch from 43005b0 to caead67 Compare October 20, 2026 15:28
@Jocs
Jocs changed the base branch from split/marktext-document-mode to develop October 20, 2026 15:28
@Jocs
Jocs force-pushed the feat/per-tab-reading-mode branch from caead67 to 0501a42 Compare October 20, 2026 15:30
@Jocs
Jocs merged commit 58816c7 into develop Oct 20, 2026
13 checks passed
@Jocs
Jocs deleted the feat/per-tab-reading-mode branch October 23, 2026 08:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature] Add Reading Mode (read-only) with code block copy button readonly mode support Locked/View only mode

1 participant