diff options
| author | Juanma Barranquero | 2019-10-09 12:49:39 +0200 |
|---|---|---|
| committer | Juanma Barranquero | 2019-10-09 12:49:39 +0200 |
| commit | 76a9f03ca629d3e5a596c3aa7f62a4649ac2ae8a (patch) | |
| tree | b6751a7a1b7b184e28e66f20395d65c984daaf57 /doc | |
| parent | 4b06250ef1fe98a766938862912383d2ee051dfb (diff) | |
| download | emacs-76a9f03ca629d3e5a596c3aa7f62a4649ac2ae8a.tar.gz emacs-76a9f03ca629d3e5a596c3aa7f62a4649ac2ae8a.zip | |
Implement offsets for absolute line numbers
* src/xdisp.c (syms_of_xdisp) <display-line-numbers-offset>:
New variable to add an offset to absolute line numbers.
(syms_of_xdisp) <display-line-numbers>: Mention it in docstring.
(maybe_produce_line_number): Use it.
* doc/emacs/display.texi (Display Custom): Document it.
* etc/NEWS (value): Announce it.
* lisp/frame.el: Add `display-line-numbers-offset' to list of
variables which should trigger redisplay of the current buffer.
Diffstat (limited to 'doc')
| -rw-r--r-- | doc/emacs/display.texi | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/doc/emacs/display.texi b/doc/emacs/display.texi index 406feb8c127..cb37ef448e8 100644 --- a/doc/emacs/display.texi +++ b/doc/emacs/display.texi | |||
| @@ -1855,6 +1855,13 @@ the variable @code{display-line-numbers-widen} to a non-@code{nil} | |||
| 1855 | value, line numbers will disregard any narrowing and will start at the | 1855 | value, line numbers will disregard any narrowing and will start at the |
| 1856 | first character of the buffer. | 1856 | first character of the buffer. |
| 1857 | 1857 | ||
| 1858 | @vindex display-line-numbers-offset | ||
| 1859 | If the value of @code{display-line-numbers-offset} is non-zero, it is | ||
| 1860 | added to each absolute line number, and lines are counted from the | ||
| 1861 | beginning of the buffer, as if @code{display-line-numbers-widen} were | ||
| 1862 | non-@code{nil}. It has no effect when set to zero, or when line | ||
| 1863 | numbers are not absolute. | ||
| 1864 | |||
| 1858 | @vindex display-line-numbers-width-start | 1865 | @vindex display-line-numbers-width-start |
| 1859 | @vindex display-line-numbers-grow-only | 1866 | @vindex display-line-numbers-grow-only |
| 1860 | @vindex display-line-numbers-width | 1867 | @vindex display-line-numbers-width |