summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
authorJuri Linkov <juri@linkov.net>2022-12-12 19:37:02 +0200
committerJuri Linkov <juri@linkov.net>2022-12-12 19:37:02 +0200
commit40c23c11e884bd14c9340a4853ab5db02901fe65 (patch)
treef34d34d17706cfe5d952753af46a23b683a3b484 /lisp
parent527eb11de20ac77877e5eaf67fa145515bd9a6d4 (diff)
downloademacs-40c23c11e884bd14c9340a4853ab5db02901fe65.tar.gz
emacs-40c23c11e884bd14c9340a4853ab5db02901fe65.tar.bz2
emacs-40c23c11e884bd14c9340a4853ab5db02901fe65.zip
* lisp/outline.el: Fix the value 'insert' of outline-minor-mode-use-buttons.
(outline--insert-button): Keep text properties around point on the inserted whitespace placeholder. * lisp/apropos.el (apropos-mode): * lisp/progmodes/xref.el (xref--xref-buffer-mode): Change outline-minor-mode-use-buttons from t to 'insert'.
Diffstat (limited to 'lisp')
-rw-r--r--lisp/apropos.el2
-rw-r--r--lisp/outline.el2
-rw-r--r--lisp/progmodes/xref.el2
3 files changed, 3 insertions, 3 deletions
diff --git a/lisp/apropos.el b/lisp/apropos.el
index a731926f458..89f1f150a12 100644
--- a/lisp/apropos.el
+++ b/lisp/apropos.el
@@ -496,7 +496,7 @@ Intended as a value for `revert-buffer-function'."
outline-level (lambda () 1)
outline-minor-mode-cycle t
outline-minor-mode-highlight t
- outline-minor-mode-use-buttons t))
+ outline-minor-mode-use-buttons 'insert))
(defvar apropos-multi-type t
"If non-nil, this apropos query concerns multiple types.
diff --git a/lisp/outline.el b/lisp/outline.el
index 2c3f9798ec4..53bfc4d556f 100644
--- a/lisp/outline.el
+++ b/lisp/outline.el
@@ -1817,7 +1817,7 @@ With a prefix argument, show headings up to that LEVEL."
(unless o
(when (eq outline-minor-mode-use-buttons 'insert)
(let ((inhibit-read-only t))
- (insert " ")
+ (insert (apply #'propertize " " (text-properties-at (point))))
(beginning-of-line)))
(setq o (make-overlay (point) (1+ (point))))
(overlay-put o 'outline-button t)
diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el
index 1e4aa4eba52..0790d3a5650 100644
--- a/lisp/progmodes/xref.el
+++ b/lisp/progmodes/xref.el
@@ -994,7 +994,7 @@ point."
(setq-local add-log-current-defun-function
#'xref--add-log-current-defun)
(setq-local outline-minor-mode-cycle t
- outline-minor-mode-use-buttons t
+ outline-minor-mode-use-buttons 'insert
outline-search-function
(lambda (&optional bound move backward looking-at)
(outline-search-text-property