diff options
author | Mountain Man <43313373+MountainMan1312@users.noreply.github.com> | 2023-04-20 12:48:45 -0400 |
---|---|---|
committer | Mountain Man <43313373+MountainMan1312@users.noreply.github.com> | 2023-04-20 12:48:45 -0400 |
commit | 634352cb6a3bbced02a6188f23b5b1da5e92b426 (patch) | |
tree | 16d65f2f28cbd4d425e9be010db821a57772f982 /init.el | |
parent | Merge `rfc/7/use-package` branch to `stable` branch (diff) | |
download | mmosmacs-634352cb6a3bbced02a6188f23b5b1da5e92b426.tar.gz mmosmacs-634352cb6a3bbced02a6188f23b5b1da5e92b426.tar.bz2 mmosmacs-634352cb6a3bbced02a6188f23b5b1da5e92b426.zip |
Improve whitespace functionality in text editor
Show trailing whitespace. End sentences with one space. End files with
one newline. Use spaces for indentation. Wrap words at buffer edge.
Diffstat (limited to 'init.el')
-rw-r--r-- | init.el | 34 |
1 files changed, 34 insertions, 0 deletions
@@ -59,6 +59,40 @@ | |||
59 | 59 | ||
60 | 60 | ||
61 | ;; --------------------------------------------------------------------- | 61 | ;; --------------------------------------------------------------------- |
62 | ;;; Text Editor | ||
63 | ;; ------------ | ||
64 | ;; These tweaks are meant to make the text editor more convenient. | ||
65 | ;; --------------------------------------------------------------------- | ||
66 | |||
67 | ;; --------------------------------- | ||
68 | ;; Whitespace | ||
69 | ;; ---------- | ||
70 | ;; Spaces, tabs, indentation, | ||
71 | ;; newlines, and text-wrapping. | ||
72 | ;; --------------------------------- | ||
73 | |||
74 | ;; Show stray whitespace | ||
75 | (setq-default show-trailing-whitespace t | ||
76 | indicate-empty-lines t | ||
77 | indicate-buffer-boundaries 'left) | ||
78 | |||
79 | ;; Make files end with newline | ||
80 | (setq-default require-final-newline t) | ||
81 | |||
82 | ;; Sentences end with ONE space | ||
83 | (setq-default sentence-end-double-space nil) | ||
84 | |||
85 | ;; Use spaces for indentation | ||
86 | (setq-default indent-tabs-mode nil | ||
87 | tab-width 2) | ||
88 | |||
89 | ;; Wrap words at buffer edge | ||
90 | (global-visual-line-mode) | ||
91 | |||
92 | |||
93 | |||
94 | |||
95 | ;; --------------------------------------------------------------------- | ||
62 | ;;; File Management | 96 | ;;; File Management |
63 | ;; ---------------- | 97 | ;; ---------------- |
64 | ;; Everything to do with file or directory management goes here. | 98 | ;; Everything to do with file or directory management goes here. |