This worked just fine with my wheel mouse.

I was so thrilled, I put it in my .emacs!

On Tue, 2002-12-17 at 13:54, bringar wrote:
> i haven't yet tested this in darwin but if X is getting wheel events it
> should work, i had to do this for the latest incarnation of Mandrake
> 
> put into an .elc file and have emacs load it:
> 
> 
> 
> 
> (setq unix-mouse-wheel-scroll-amount 4)
> (defun unix-mouse-wheel-scroll-line-up (event)
> "Scroll the current buffer by `unix-mouse-wheel-scroll-amount`."
> (interactive "e")
> (condition-case nil
>     (if (< (car (cdr (cdr event))) 0)
>         (scroll-up unix-mouse-wheel-scroll-amount)
>       (scroll-down unix-mouse-wheel-scroll-amount))
>   (error nil)))
> 
> (defun unix-mouse-wheel-scroll-line-down (event)
> "Scroll the current buffer by `unix-mouse-wheel-scroll-amount`."
> (interactive "e")
> (condition-case nil
>     (if (< (car (cdr (cdr event))) 0)
>         (scroll-down unix-mouse-wheel-scroll-amount)
>       (scroll-up unix-mouse-wheel-scroll-amount))
>   (error nil)))
> 
> ;; Bind the "mouse-wheel" event:
> (global-set-key [mouse-4] `unix-mouse-wheel-scroll-line-up)
> (global-set-key [mouse-5] `unix-mouse-wheel-scroll-line-down)
> 
> 
> 
> long live the gnu!
> -s-
> 
> 
> On Tue, 17 Dec 2002, [ISO-8859-1] S�bastien Maret wrote:
> 
> __>The scrolling of some X11 windows works with a wheel mouse works well 
> __>with some apps (like xterm) but not in other (emacs...)
> __>How can I fix that ?
> __>Sebastien
> __>--
> __>S�bastien Maret
> __>[EMAIL PROTECTED]
> __>
> __>
> __>
> __>-------------------------------------------------------
> __>This sf.net email is sponsored by:
> __>With Great Power, Comes Great Responsibility 
> __>Learn to use your power at OSDN's High Performance Computing Channel
> __>http://hpc.devchannel.org/
> __>_______________________________________________
> __>Fink-users mailing list
> __>[EMAIL PROTECTED]
> __>https://lists.sourceforge.net/lists/listinfo/fink-users
> __>
> 
> 
> 
> -------------------------------------------------------
> This sf.net email is sponsored by:
> With Great Power, Comes Great Responsibility 
> Learn to use your power at OSDN's High Performance Computing Channel
> http://hpc.devchannel.org/
> _______________________________________________
> Fink-users mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/fink-users
> 
-- 
Alexander K. Hansen
Associate Research Scientist, Columbia University
visiting MIT Plasma Science and Fusion Center
Levitated Dipole Experiment
175 Albany Street, NW17-219
Cambridge, MA  02139-4213


-------------------------------------------------------
This sf.net email is sponsored by:
With Great Power, Comes Great Responsibility
Learn to use your power at OSDN's High Performance Computing Channel
http://hpc.devchannel.org/
_______________________________________________
Fink-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/fink-users

Reply via email to