[Q] binding mouse buttons in XMathematica?
- To: mathgroup@smc.vnet.net
- Subject: [mg11818] [Q] binding mouse buttons in XMathematica?
- From: jordan miles koss <jmkoss@harper.uchicago.edu>
- Date: Tue, 31 Mar 1998 02:28:36 -0500
- Organization: The University of Chicago
I am running Mathematica 3.0 on a Linux box. I have a Microsoft IntelliMouse, which Linux recognizes by binding 1) a turn of the scroll wheel away from the user as clicking mouse button 4 and 2) a turn of the scroll wheel toward the user as clicking mouse button 5. See <http://www.inria.fr/koala/colas/mouse-wheel-scroll/> for more info on this. I would like to now bind mouse button 4 (5) to a command that scrolls the Mathematica notebook up (down). From looking at /usr/local/mathematica/SystemFiles/FrontEnd/SystemResources/X/XMathematica I see that I have to modify the line: *XmNotebook.baseTranslations: \ #override \n\ <Btn1Down>,<Btn1Up>: selection-put() \n\ <Btn2Down>: selection-get() \n\ <KeyPress>osfPaste: paste-from-clipboard() \n\ <KeyPress>osfCopy: copy-to-clipboard() (or add something to override this in my .Xdefaults file). I know from other examples from the above-cited web page that the modifications would be lines like: <Btn4Down>,<Btn4Up>:scroll-back(1,halfpage)\n\ <Btn5Down>,<Btn5Up>:scroll-forw(1,halfpage) However, I don't know that name of the appropriate X action to put on the right hand side of such a statement. A found a Mathematica 2.2 notebook which contained the contents of an article from "The Mathematica Journal", Vol.4, Issue 2 (the WWW reference is <http://www.mathsource.com/cgi-bin/MathSource22/Enhancements/ FrontEnd/X/0206-053>). This article mentioned that all the default key bindings are listed in Appendix E of "The User's Guide for the X Front End", but I have been unable to locate this book. I imagine that this book lists the available X actions to which one can bind keystrokes. This is the information I need. Thanks in advance for any help. Jordan Koss -- Jordan Koss j-koss@uchicago.edu