diff options
author | Thomas Voss <mail@thomasvoss.com> | 2023-08-17 08:19:09 +0200 |
---|---|---|
committer | Thomas Voss <mail@thomasvoss.com> | 2023-08-17 08:19:09 +0200 |
commit | 77e20ba15d0185675e2d10c7e3cb207ee76a0931 (patch) | |
tree | 7cf93be7899a0eb69ff845b160c5363f0d9160ff /.config | |
parent | be7ab7767a3674c891c4c58783d70276bd423ab7 (diff) |
emacs: Disable ‘display-line-numbers-mode’
Diffstat (limited to '.config')
-rw-r--r-- | .config/emacs/config.org | 24 |
1 files changed, 3 insertions, 21 deletions
diff --git a/.config/emacs/config.org b/.config/emacs/config.org index caa7dd2..6264d55 100644 --- a/.config/emacs/config.org +++ b/.config/emacs/config.org @@ -830,33 +830,15 @@ want this /everywhere/. *** Line- and Column Numbers -It’s a bit tricky to remember, but ~line-number-mode~ and -~display-line-numbers-mode~ are very different. The former displays the current -line number in the modeline while the latter displays line numbers on the left -of the buffer. Personally I like to always display the current line number in -the modeline along with the column number — I find that it helps me wrap text -properly when I am not using ~auto-fill-mode~ — but I would prefer to only -display line numbers in certain modes. +I like to have line- and column numbers in my modeline. I find them to be very +useful to have. I used to also like to have the current line number on the left +of the screen, but I don’t really need that information. #+BEGIN_SRC elisp (line-number-mode) (column-number-mode) - ;; Enable and disable line numbers for some modes - (defvar mango-enable-line-numbers-modes - '(text-mode prog-mode conf-mode) - "A list of modes for which line numbers should be displayed.") - - (defvar mango-disable-line-numbers-modes - '(org-mode) - "A list of modes for which line numbers shouldn’t be displayed.") - - (cl-dolist (mode mango-enable-line-numbers-modes) - (add-hook (mango-mode-to-hook mode) #'display-line-numbers-mode)) - (cl-dolist (mode mango-disable-line-numbers-modes) - (add-hook (mango-mode-to-hook mode) (λ (display-line-numbers-mode -1)))) - #+END_SRC *** Fonts |