]> git.eshelyaron.com Git - emacs.git/commitdiff
Bind mouse-1 on left-fringe and right-fringe to mouse-set-point so
authorKim F. Storm <storm@cua.dk>
Sun, 23 Nov 2003 00:27:27 +0000 (00:27 +0000)
committerKim F. Storm <storm@cua.dk>
Sun, 23 Nov 2003 00:27:27 +0000 (00:27 +0000)
that hscroll still works now that clicks on fringes generate specific
mouse events.
(mouse-set-point): Note that it now works in fringes and margins
too due to new semantics of posn-point in fringes and margins.

lisp/mouse.el

index ecf642caeed89e4edc50649d9c01deaa098945c4..9b80ccc0cf5062b51a0e5449cb09f6d4d11b3465 100644 (file)
@@ -2204,6 +2204,10 @@ and selects that window."
 (global-set-key [double-mouse-1] 'mouse-set-point)
 (global-set-key [triple-mouse-1] 'mouse-set-point)
 
+;; Clicking on the fringes causes hscrolling:
+(global-set-key [left-fringe mouse-1]  'mouse-set-point)
+(global-set-key [right-fringe mouse-1] 'mouse-set-point)
+
 (global-set-key [mouse-2]      'mouse-yank-at-click)
 (global-set-key [mouse-3]      'mouse-save-then-kill)