Adapt Proced display to display-line-numbers

* lisp/proced.el (proced-header-line): Account for the width taken
by display-line-numbers.  (Bug#27895)
This commit is contained in:
Eli Zaretskii 2017-08-12 13:18:13 +03:00
parent a955d79516
commit e94b0d4d54

View file

@ -602,7 +602,9 @@ Important: the match ends just after the marker.")
(defun proced-header-line ()
"Return header line for Proced buffer."
(list (propertize " " 'display '(space :align-to 0))
(list (propertize " "
'display
(list 'space :align-to (+ 2 (line-number-display-width))))
(if (<= (window-hscroll) (length proced-header-line))
(replace-regexp-in-string ;; preserve text properties
"\\(%\\)" "\\1\\1"