mirror of
https://github.com/masscollaborationlabs/emacs.git
synced 2025-07-10 22:20:51 +00:00
Make use of rectangle-preview custom variable.
lisp/rect.el (rectangle--string-preview): Only create a preview if rectangle-preview is non-nil (Bug#23248).
This commit is contained in:
parent
aa0d83a727
commit
0f332848cd
1 changed files with 35 additions and 34 deletions
|
@ -408,6 +408,7 @@ With a prefix (or a FILL) argument, also fill too short lines."
|
|||
:type 'boolean)
|
||||
|
||||
(defun rectangle--string-preview ()
|
||||
(when rectangle-preview
|
||||
(let ((str (minibuffer-contents)))
|
||||
(when (equal str "")
|
||||
(setq str (or (car-safe minibuffer-default)
|
||||
|
@ -441,7 +442,7 @@ With a prefix (or a FILL) argument, also fill too short lines."
|
|||
(overlay-put ol 'display str)
|
||||
(if as (overlay-put ol 'after-string as))))))
|
||||
(nth 1 rectangle--string-preview-state)
|
||||
(nth 2 rectangle--string-preview-state))))))
|
||||
(nth 2 rectangle--string-preview-state)))))))
|
||||
|
||||
;; FIXME: Should this be turned into inhibit-region-highlight and made to apply
|
||||
;; to non-rectangular regions as well?
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue