aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEli Zaretskii2017-06-30 23:19:53 +0300
committerEli Zaretskii2017-06-30 23:19:53 +0300
commit1174e53ebb9610dc352c4a5c533d24c935cc1ed9 (patch)
treec840938d3cb311daaf256dbd23921c606fd49a73
parenta9be5a768b6c06e74a386c474aba8125dfc8ed86 (diff)
downloademacs-1174e53ebb9610dc352c4a5c533d24c935cc1ed9.tar.gz
emacs-1174e53ebb9610dc352c4a5c533d24c935cc1ed9.zip
Improve documentation of faces related to display-line-numbers
* lisp/faces.el (line-number, line-number-current-line): Warn against using non-monospaced fonts.
-rw-r--r--lisp/faces.el16
1 files changed, 14 insertions, 2 deletions
diff --git a/lisp/faces.el b/lisp/faces.el
index 3a40dc90081..c3693d16631 100644
--- a/lisp/faces.el
+++ b/lisp/faces.el
@@ -2469,14 +2469,26 @@ If you set `term-file-prefix' to nil, this function does nothing."
2469(defface line-number 2469(defface line-number
2470 '((t :inherit (shadow default))) 2470 '((t :inherit (shadow default)))
2471 "Face for displaying line numbers. 2471 "Face for displaying line numbers.
2472This face is used when `display-line-numbers' is non-nil." 2472This face is used when `display-line-numbers' is non-nil.
2473
2474If you customize the font of this face, make sure it is a
2475monospaced font, otherwise line numbers will not line up,
2476and text lines might move horizontally as you move through
2477the buffer."
2473 :version "26.1" 2478 :version "26.1"
2474 :group 'basic-faces) 2479 :group 'basic-faces)
2475 2480
2476(defface line-number-current-line 2481(defface line-number-current-line
2477 '((t :inherit line-number)) 2482 '((t :inherit line-number))
2478 "Face for displaying the current line number. 2483 "Face for displaying the current line number.
2479This face is used when `display-line-numbers' is non-nil." 2484This face is used when `display-line-numbers' is non-nil.
2485
2486If you customize the font of this face, make sure it is a
2487monospaced font, otherwise line numbers will not line up,
2488and text lines might move horizontally as you move through
2489the buffer. Similarly, making this face's font different
2490from that of the `line-number' face could produce such
2491unwanted effects."
2480 :version "26.1" 2492 :version "26.1"
2481 :group 'basic-faces) 2493 :group 'basic-faces)
2482 2494