Created
December 22, 2017 19:27
-
-
Save etherald/9fb1c1c072a2a65a9f63e904fefdf807 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; reader-mode.el | |
;; [Fri Dec 22 19:24:09 UTC 2017] | |
;; displays selected buffer continuously flowed | |
;; into reader-mode-column-count windows side by side | |
;; in read-only mode | |
(defvar reader-mode-column-count 4) | |
(defun reader-mode (buf) | |
(interactive "bRead buffer: ") | |
(unless (eq (current-buffer) buf) | |
(switch-to-buffer buf)) | |
(delete-other-windows) | |
(view-mode) | |
(dotimes (count (- reader-mode-column-count 1)) | |
(split-window-right)) | |
(balance-windows) | |
(follow-mode)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment