comparison lisp/prim/mouse.el @ 120:cca96a509cfe r20-1b12

Import from CVS: tag r20-1b12
author cvs
date Mon, 13 Aug 2007 09:25:29 +0200
parents 9f59509498e1
children 25f70ba0133c
comparison
equal deleted inserted replaced
119:d101af7320b8 120:cca96a509cfe
32 (global-set-key '(control shift button1) 'mouse-track-delete-and-insert) 32 (global-set-key '(control shift button1) 'mouse-track-delete-and-insert)
33 (global-set-key '(meta button1) 'mouse-track-do-rectangle) 33 (global-set-key '(meta button1) 'mouse-track-do-rectangle)
34 34
35 (global-set-key 'button2 'mouse-yank) 35 (global-set-key 'button2 'mouse-yank)
36 36
37 (defvar mouse-track-rectangle-p nil 37 (defcustom mouse-track-rectangle-p nil
38 "*If true, then dragging out a region with the mouse selects rectangles 38 "*If true, then dragging out a region with the mouse selects rectangles
39 instead of simple start/end regions.") 39 instead of simple start/end regions."
40 40 :type 'boolean
41 (defvar mouse-yank-at-point nil 41 :group 'mouse)
42
43 (defcustom mouse-yank-at-point nil
42 "*If non-nil, the function `mouse-yank' will yank text at the cursor location. 44 "*If non-nil, the function `mouse-yank' will yank text at the cursor location.
43 Otherwise, the cursor will be moved to the location of the pointer click before 45 Otherwise, the cursor will be moved to the location of the pointer click before
44 text is inserted.") 46 text is inserted."
47 :type 'boolean
48 :group 'mouse)
45 49
46 (defvar mouse-yank-function 'yank ; x11/x-mouse changes this... 50 (defvar mouse-yank-function 'yank ; x11/x-mouse changes this...
47 "Function that is called upon by `mouse-yank' to actually insert text.") 51 "Function that is called upon by `mouse-yank' to actually insert text.")
48 52
49 53
495 Unlike all of the other mouse-track hooks, this is a \"normal\" 499 Unlike all of the other mouse-track hooks, this is a \"normal\"
496 hook: the hook functions are called with no arguments, and 500 hook: the hook functions are called with no arguments, and
497 all hook functions are called regardless of their return 501 all hook functions are called regardless of their return
498 values.") 502 values.")
499 503
500 (defvar mouse-track-multi-click-time 400 504 (defcustom mouse-track-multi-click-time 400
501 "Maximum number of milliseconds allowed between clicks for a multi-click. 505 "*Maximum number of milliseconds allowed between clicks for a multi-click.
502 See `mouse-track-click-hook'.") 506 See `mouse-track-click-hook'."
503 507 :type 'integer
504 (defvar mouse-track-scroll-delay 100 508 :group 'mouse)
509
510 (defcustom mouse-track-scroll-delay 100
505 "Maximum of milliseconds between calls to `mouse-track-drag-hook'. 511 "Maximum of milliseconds between calls to `mouse-track-drag-hook'.
506 If the user is dragging the mouse (i.e. the button is held down and 512 If the user is dragging the mouse (i.e. the button is held down and
507 a drag has been initiated) and does not move the mouse for this many 513 a drag has been initiated) and does not move the mouse for this many
508 milliseconds, the hook will be called with t as the value of the 514 milliseconds, the hook will be called with t as the value of the
509 WAS-TIMEOUT parameter. This can be used to implement scrolling 515 WAS-TIMEOUT parameter. This can be used to implement scrolling
510 in a selection when the user drags the mouse out the window it 516 in a selection when the user drags the mouse out the window it
511 was in. 517 was in.
512 518
513 A value of nil disables the timeout feature.") 519 A value of nil disables the timeout feature."
520 :type '(choice integer (const :tag "Disabled" nil))
521 :group 'mouse)
514 522
515 (defvar mouse-track-x-threshold '(face-width 'default) 523 (defvar mouse-track-x-threshold '(face-width 'default)
516 "Minimum number of pixels in the X direction for a drag to be initiated. 524 "Minimum number of pixels in the X direction for a drag to be initiated.
517 If the mouse is moved more than either the X or Y threshold while the 525 If the mouse is moved more than either the X or Y threshold while the
518 button is held down (see also `mouse-track-y-threshold'), then a drag 526 button is held down (see also `mouse-track-y-threshold'), then a drag