From owner-freebsd-questions Tue Jan 4 15:23:30 2000 Delivered-To: freebsd-questions@freebsd.org Received: from typhoon.mail.pipex.net (typhoon.mail.pipex.net [158.43.128.27]) by hub.freebsd.org (Postfix) with SMTP id 4950014D60 for ; Tue, 4 Jan 2000 15:22:37 -0800 (PST) (envelope-from mark@dogma.freebsd-uk.eu.org) Received: (qmail 4371 invoked from network); 4 Jan 2000 23:21:23 -0000 Received: from userae76.uk.uudial.com (HELO marder-1.) (62.188.131.218) by smtp.dial.pipex.com with SMTP; 4 Jan 2000 23:21:23 -0000 Received: (from mark@localhost) by marder-1. (8.9.3/8.9.3) id XAA02430; Tue, 4 Jan 2000 23:21:20 GMT (envelope-from mark) Date: Tue, 4 Jan 2000 23:21:20 +0000 From: Mark Ovens To: Vivek Khera Cc: freebsd-questions@freebsd.org Subject: Re: X keymapping Message-ID: <20000104232120.J352@marder-1> References: <14450.10100.495300.372549@onceler.kcilink.com> <20000104220745.F352@marder-1> <14450.29762.888402.877973@onceler.kcilink.com> <20000104224803.H352@marder-1> <14450.31645.168625.761260@onceler.kcilink.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0pre2i In-Reply-To: <14450.31645.168625.761260@onceler.kcilink.com> Organization: Total lack of Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Tue, Jan 04, 2000 at 06:00:45PM -0500, Vivek Khera wrote: > >>>>> "MO" == Mark Ovens writes: > > >> Is there some way to modify the microsoft keyboard geometry file under > >> X11 to swap these keys? I don't see exactly how that file works. > >> > > MO> Firstly, do you have the line > > MO> XkbModel "microsoft" > > MO> uncommented in /etc/XF86Config? > > This is my Keboard section: > > Section "Keyboard" > Protocol "Standard" > XkbRules "xfree86" > XkbModel "microsoft" > XkbLayout "us" > LeftAlt Meta > RightAlt Meta > EndSection > > as created by the XF86 configuration program during installation. > > MO> Also, are you saying that the "Windows" key is Meta_L by default? If > MO> so then does: > > Yes. And the right side "Windows" key is Meta_R. > > MO> xmodmap -e "keysym Alt_L = Meta_L Alt_L" > MO> xmodmap -e "keysym Meta_L = Alt_L Meta_L" > > MO> not swap them? > > Nope. It makes them both "Alt_L". I'll play with this... it is very > close. I think both commands need to run in one invocation of xmodmap > or it can't be done. Sounds feasible. > Kinda like swapping capslock/control. > Except that there's a builtin option for that XkbOptions "ctrl:swapcaps" Looking again at xmodmap(1) there is a section about swapping the Control and CapsLock keys using "remove", "keysym" and "add". Maybe this is the answer? Also, do you know about xev(1)? It displays X events. It may help you work this one out. Run it from an xterm and with the mouse in the pop-up window (don't move the mouse as it generates loads of events) press a key and release it. You will see, in the xterm, a KeyPress event and a KeyRelease event. Look at the 3rd line and you will see the keysym attached to the key, e.g. keycode 64 (keysym 0xffe9, Alt_L), HTH -- "there's a long-standing bug relating to the x86 architecture that allows you to install Windows too" -Matthew D. Fuller ________________________________________________________________ FreeBSD - The Power To Serve http://www.freebsd.org My Webpage http://ukug.uk.freebsd.org/~mark/ mailto:mark@ukug.uk.freebsd.org http://www.radan.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message