hi, In LaTeX mode (AUCTeX), I want double-click to have the usual selection effect when the click is on a word-constituent character, but otherwise do a forward-search (i.e. invoke the dvi viewer). I wrote the following function for doing the latter:
(defun my-LaTeX-forward-search (event) "Set point to the position of the mouse pointer and then call the function TeX-view from AucTeX." (interactive "e") (if (and (numberp (posn-point (event-start event))) (looking-at "\\W")) (TeX-view))) Then I bind as follows: (define-key LaTeX-mode-map [double-down-mouse-1] 'my-LaTeX-forward-search) The problem is that on double-clicking on a word-constituent character, the double-down event runs the above function (which, as expected, does nothing) , but the subsequent double-click event doesn't have the usual effect of selecting the word. On the other hand, if I bind my function to [double-mouse-1], it doesn't even get invoked, although the binding is successful. What am I missing? Thanks, Rajneesh. P.S. I'm using GNU Emacs 22.0.50.2 (i386-mingw-nt5.1.2600) (from crasseux.com) on a WinXP Home machine (the mouse is a Synaptics touchpad.) The same problem happens with precompiled Emacs 21.3. _______________________________________________ Help-gnu-emacs mailing list Help-gnu-emacs@gnu.org http://lists.gnu.org/mailman/listinfo/help-gnu-emacs