From: Lars Ingebrigtsen Date: Mon, 6 Sep 2021 10:56:02 +0000 (+0200) Subject: Make calc-grab-region work with rectangular selects X-Git-Tag: emacs-28.0.90~1144 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=61e5570863aa236628a87c722912dea86d2903b0;p=emacs.git Make calc-grab-region work with rectangular selects * lisp/calc/calc.el (calc-grab-region): Heed `rectangle-mark-mode' (bug#50403). --- diff --git a/lisp/calc/calc.el b/lisp/calc/calc.el index 27a6cff627c..800ec7a6a38 100644 --- a/lisp/calc/calc.el +++ b/lisp/calc/calc.el @@ -139,6 +139,7 @@ ;;; Code: (require 'calc-macs) +(require 'rect) ;; Declare functions which are defined elsewhere. (declare-function calc-set-language "calc-lang" (lang &optional option no-refresh)) @@ -3388,7 +3389,9 @@ and all digits are kept, regardless of Calc's current precision." "Parse the region as a vector of numbers and push it on the Calculator stack." (interactive "r\nP") (require 'calc-ext) - (calc-do-grab-region top bot arg)) + (if rectangle-mark-mode + (calc-do-grab-rectangle top bot arg) + (calc-do-grab-region top bot arg))) ;;;###autoload (defun calc-grab-rectangle (top bot arg)