summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMattias EngdegÄrd <mattiase@acm.org>2019-12-01 18:31:34 +0100
committerMattias EngdegÄrd <mattiase@acm.org>2019-12-01 18:32:43 +0100
commit9f2145f42daab13aed5cf89fdb6a7c5579819ec0 (patch)
tree420728155f06484b3092b87e21de7966da86a1c3
parent8b5c5a9a9b307a9593dbc643fd97885435191095 (diff)
downloademacs-9f2145f42daab13aed5cf89fdb6a7c5579819ec0.tar.gz
Temporary enable transient-mark-mode for rectangle selection
* lisp/mouse.el (mouse-drag-region-rectangle): Enable transient-mark-mode during selection (bug#38431).
-rw-r--r--lisp/mouse.el4
1 files changed, 4 insertions, 0 deletions
diff --git a/lisp/mouse.el b/lisp/mouse.el
index bc05a35009e..32996b2eded 100644
--- a/lisp/mouse.el
+++ b/lisp/mouse.el
@@ -2007,6 +2007,10 @@ This must be bound to a button-down mouse event."
(setq dragged t)
(mouse-minibuffer-check start-event)
(deactivate-mark)
+ (setq-local transient-mark-mode
+ (if (eq transient-mark-mode 'lambda)
+ '(only)
+ (cons 'only transient-mark-mode)))
(posn-set-point start-pos)
(rectangle-mark-mode)
;; Only tell rectangle about the exact column if we are possibly