Emacs: Novel Reading Mode 📜
Read Novel Mode
Here's a command to make current window suitable for reading long text.
put this in your Emacs Init File:
(defun xah-toggle-read-novel-mode () "Setup current frame to be suitable for reading long novel/article text. • Set frame width to 70 • Line wrap at word boundaries. • Line spacing is increased. • Proportional width font is used. Call again to toggle back. URL `http://xahlee.info/emacs/emacs/emacs_novel_reading_mode.html' Created: 2019-01-30 Version: 2021-01-16" (interactive) (if (eq (frame-parameter (selected-frame) 'width) 70) (progn (set-frame-parameter (selected-frame) 'width 106) (variable-pitch-mode 0) (setq line-spacing nil) (setq word-wrap nil)) (progn (set-frame-parameter (selected-frame) 'width 70) (variable-pitch-mode 1) (setq line-spacing 0.5) (setq word-wrap t))) (redraw-frame (selected-frame)))
Before

After

xah-toggle-margin-right
Here's a command that just toggles the margin.

xah-toggle-margin-right
(defun xah-toggle-margin-right () "Toggle the right margin between `fill-column' or window width. This command is convenient when reading novel, documentation. URL `http://xahlee.info/emacs/emacs/emacs_novel_reading_mode.html' Version 2020-04-10" (interactive) (if (cdr (window-margins)) (set-window-margins nil 0 0) (set-window-margins nil 0 (- (window-body-width) fill-column))))
Emacs Lines, Column, Cursor Position
Soft-Wrap Lines
- Emacs: Visual Line Mode
- Emacs: Toggle Word Wrap
- Emacs: Line Wrap
- Emacs: Novel Reading Mode 📜
- Emacs: Toggle Line Spacing Command 📜
Reformat Lines
- Emacs: Hard-Wrap Lines (fill-region)
- Emacs: Reformat to Long Lines (unfill-region) 📜
- Emacs: Reformat Lines for Source Code 📜