aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorMattias EngdegÄrd2019-10-25 11:16:39 +0200
committerMattias EngdegÄrd2019-11-27 13:40:29 +0100
commit4eb7db5d4b84708912c63a77569c8adeeff6c640 (patch)
treee4f014f3b2b2407ec74e875a8ef2ab3bc37b2225 /doc
parente7b4c248a6d2a2eca19a2a362103a7f24cfe30fc (diff)
downloademacs-4eb7db5d4b84708912c63a77569c8adeeff6c640.tar.gz
emacs-4eb7db5d4b84708912c63a77569c8adeeff6c640.zip
Mouse rectangular region selection (bug#38013)
Make it possible to select a rectangular region using the mouse. The standard binding is C-M-mouse-1. * lisp/mouse.el (mouse-scroll-subr): Add ADJUST argument. (mouse-drag-region-rectangle): New. * lisp/rect.el (rectangle--reset-point-crutches): New. (rectangle--reset-crutches): Use 'rectangle--reset-point-crutches'. * src/xdisp.c (remember_mouse_glyph, syms_of_xdisp): Add 'mouse-fine-grained-tracking'. * doc/lispref/commands.texi (Motion Events): Document 'mouse-fine-grained-tracking'. * doc/emacs/frames.texi (Mouse Commands): * doc/emacs/killing.texi (Rectangles): * etc/NEWS: Document rectangular selection with the mouse.
Diffstat (limited to 'doc')
-rw-r--r--doc/emacs/frames.texi4
-rw-r--r--doc/emacs/killing.texi3
-rw-r--r--doc/lispref/commands.texi6
3 files changed, 13 insertions, 0 deletions
diff --git a/doc/emacs/frames.texi b/doc/emacs/frames.texi
index 091c011fb96..f6c2d239132 100644
--- a/doc/emacs/frames.texi
+++ b/doc/emacs/frames.texi
@@ -91,6 +91,10 @@ If the region is active, move the nearer end of the region to the
91click position; otherwise, set mark at the current value of point and 91click position; otherwise, set mark at the current value of point and
92point at the click position. Save the resulting region in the kill 92point at the click position. Save the resulting region in the kill
93ring; on a second click, kill it (@code{mouse-save-then-kill}). 93ring; on a second click, kill it (@code{mouse-save-then-kill}).
94
95@item C-M-mouse-1
96Activate a rectangular region around the text selected by dragging.
97@xref{Rectangles}.
94@end table 98@end table
95 99
96@findex mouse-set-point 100@findex mouse-set-point
diff --git a/doc/emacs/killing.texi b/doc/emacs/killing.texi
index 80e2868908a..ce00cb38a74 100644
--- a/doc/emacs/killing.texi
+++ b/doc/emacs/killing.texi
@@ -732,6 +732,9 @@ region is controlled. But remember that a given combination of point
732and mark values can be interpreted either as a region or as a 732and mark values can be interpreted either as a region or as a
733rectangle, depending on the command that uses them. 733rectangle, depending on the command that uses them.
734 734
735 A rectangular region can also be marked using the mouse: click and drag
736@kbd{C-M-mouse-1} from one corner of the rectangle to the opposite.
737
735@table @kbd 738@table @kbd
736@item C-x r k 739@item C-x r k
737Kill the text of the region-rectangle, saving its contents as the 740Kill the text of the region-rectangle, saving its contents as the
diff --git a/doc/lispref/commands.texi b/doc/lispref/commands.texi
index 0c848a80257..032f005e9c4 100644
--- a/doc/lispref/commands.texi
+++ b/doc/lispref/commands.texi
@@ -1661,6 +1661,12 @@ events within its body. Outside of @code{track-mouse} forms, Emacs
1661does not generate events for mere motion of the mouse, and these 1661does not generate events for mere motion of the mouse, and these
1662events do not appear. @xref{Mouse Tracking}. 1662events do not appear. @xref{Mouse Tracking}.
1663 1663
1664@defvar mouse-fine-grained-tracking
1665When non-@code{nil}, mouse motion events are generated even for very
1666small movements. Otherwise, motion events are not generated as long
1667as the mouse cursor remains pointing to the same glyph in the text.
1668@end defvar
1669
1664@node Focus Events 1670@node Focus Events
1665@subsection Focus Events 1671@subsection Focus Events
1666@cindex focus event 1672@cindex focus event