summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorEli Zaretskii <eliz@gnu.org>2015-06-30 18:59:21 +0300
committerEli Zaretskii <eliz@gnu.org>2015-06-30 18:59:21 +0300
commitedd09381c618125d8aa23c9414034fbeee176305 (patch)
tree009641f2aad95cc9852b06b036a4e6a9f143be94 /doc
parent881c4790266c42805ac1b9a5f1bbe13d3dd23478 (diff)
Don't block changes in mouse pointer inside 'track-mouse'
* etc/NEWS: * doc/lispref/frames.texi (Mouse Tracking): Document the special effect of setting 'track-mouse' to 'dragging'. * lisp/textmodes/artist.el (artist-mouse-draw-continously): * lisp/ruler-mode.el (ruler-mode-mouse-drag-any-column-iteration): * lisp/mouse-drag.el (mouse-drag-throw): * lisp/mouse.el (mouse-drag-line): Set 'track-mouse' to 'dragging' to avoid changes in the shape of the mouse pointer. * src/xdisp.c (define_frame_cursor1): Don't change the mouse pointer shape when do_mouse_tracking has the value of 'dragging', not just any non-nil value. (Bug#20934) (syms_of_xdisp): DEFSYM 'dragging'.
Diffstat (limited to 'doc')
-rw-r--r--doc/lispref/frames.texi13
1 files changed, 13 insertions, 0 deletions
diff --git a/doc/lispref/frames.texi b/doc/lispref/frames.texi
index ddf81f3e805..79b5172ae0b 100644
--- a/doc/lispref/frames.texi
+++ b/doc/lispref/frames.texi
@@ -2018,6 +2018,19 @@ The value of @code{track-mouse} is that of the last form in @var{body}.
You should design @var{body} to return when it sees the up-event that
indicates the release of the button, or whatever kind of event means
it is time to stop tracking.
+
+The @code{track-mouse} form causes Emacs to generate mouse motion
+events by binding the variable @code{mouse-tracking} to a
+non-@code{nil} value. If that variable has the special value
+@code{dragging}, it additionally instructs the display engine to
+refrain from changing the shape of the mouse pointer. This is
+desirable in Lisp programs that require mouse dragging across large
+portions of Emacs display, which might otherwise cause the mouse
+pointer to change its shape according to the display portion it hovers
+on (@pxref{Pointer Shape}). Therefore, Lisp programs that need the
+mouse pointer to retain its original shape during dragging should bind
+@code{track-mouse} to the value @code{dragging} at the beginning of
+their @var{body}.
@end defspec
The usual purpose of tracking mouse motion is to indicate on the screen