Date: Mon, 7 Apr 2003 17:03:24 -0400 From: The Anarcat <anarcat@anarcat.ath.cx> To: Dan Nelson <dnelson@allantgroup.com> Cc: freebsd-questions@freebsd.org Subject: Workaround: 6 button moused Message-ID: <20030407210324.GA24928@lenny.anarcat.ath.cx> In-Reply-To: <20030407201919.GA2729@dan.emsphone.com> References: <20030407184819.GK649@lenny.anarcat.ath.cx> <20030407194040.GA1651@lenny.anarcat.ath.cx> <20030407201919.GA2729@dan.emsphone.com>
next in thread | previous in thread | raw e-mail | index | archive | help
--IJpNTDwzlM2Ie8A6 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon Apr 07, 2003 at 03:19:19PM -0500, Dan Nelson wrote: > In the last episode (Apr 07), The Anarcat said: > > Ok, i've done a little research on my own. > >=20 > > There is a maximum of 31 buttons set in sys/mouse.h: > >=20 > > #define MOUSE_MAXBUTTON 31 > >=20 > > ..so that's probably not the issue. Thinking the problem might be more > > a matter of mapping between X and moused, I've run moused -d -f to see > > what was going on. A log is attached. It was recorded when pressing: > >=20 > > 1- left mouse button > > 2- middle mouse button > > 3- right mouse button > > 4- "sixth" mouse button (the thumb button) > > 5- wheel up > > 6- wheel down >=20 > Why do you call it the "sixth" button?=20 Because it's the sixth button of the mouse if you count the mouse wheel up and down as "buttons". > What are buttons 4 and 5 (and don't say wheel up/down, those aren't > buttons :) Hmm.. Yes, I thought wheel up/down. :) But let's say things as you want and say it's the "fourth" button we're talking about and mouse wheel/up are not buttons. =20 > I think you might need to simply change your XF86config file to read >=20 > Option "YAxisMapping" "5 6" >=20 > since on a standard 3-button/wheel mouse it's "4 5".=20 No. YAxisMapping determines which "buttons" move the *mouse cursor* on the Y-axis. I tested it. It makes my mousewheel move the cursor up and down, very cute. ;) > I know "ZAxisMApping" is what you had, but the manpage says > YAxisMapping is the one you need.=20 Where? > Docs for the mouse driver in X are unfortunately obscured by the > FreBSD mouse manpage, but you can get to them with >=20 > man -M /usr/X11R6/man mouse > or > lynx /usr/X11R6/lib/X11/doc/html/mouse.4.html=20 Reading that: Option "YAxisMapping" "N1 N2" Specifies which buttons are mapped to motion in the Y direct= ion in wheel emulation mode. Button number N1 is mapped to the n= eg- ative Y axis motion and button number N2 is mapped to the po= si- tive Y axis motion. Default: "4 5". and also: Option "ZAxisMapping" "N1 N2 N3 N4" Set the mapping for the Z axis (wheel) motion to buttons = or another axis (X or Y). Button number N1 is mapped to the ne= ga- tive Z axis motion and button number N2 is mapped to the po= si- tive Z axis motion. For mice with two wheels, four button n= um- bers can be specified, with the negative and positive motion = of the second wheel mapped respectively to buttons number N3 = and N4. Default: no mapping. But your idea made me try something new: Option "ZAxisMapping" "5 6" duh. But this gives me odd results. My "fourth button", as you call it, acts like a mouse wheel and one mouse wheel "button" doesn't work. I had to ues this to make it work properly: $ xmodmap -e 'pointer =3D 1 2 3 6 4 5' There's probably a better way to do this, but at least this way, my "fourth" button generates an event that xev(1) can see! Hourra! A. PS: I think the problem might be due to applications hardcoding "button4 and button5" as mouse wheel up/down, instead of relying on some ZAxis semantics...=20 --=20 Conformity-the natural instinct to passively yield to that vague something recognized as authority. - Mark Twain --IJpNTDwzlM2Ie8A6 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (FreeBSD) iD8DBQE+keecttcWHAnWiGcRAli4AJ4qaQ0ZmIJFocUZic81U2yqpA4DgACdHyX+ 251gCho6v7yx/VV7fIRWmpo= =2Wmz -----END PGP SIGNATURE----- --IJpNTDwzlM2Ie8A6--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030407210324.GA24928>