On Wed, May 02, 2012 at 09:00:12PM -0500, Mark Allums wrote: > On 5/2/2012 5:05 PM, Riccardo Romoli wrote: > >Hi to all, > > > >I'm a newbie of Debian but using the Debian-Wiky I was able to install > >Debian 6 as single boot, on my MacBookPro (v.3.1). The only problem I > >notice, till now...., is about the Alt key. I bought the computer as > >used from a German guy ignoring that the keyboard has the particularity > >to has only the left Alt key instead of two. So the right Alt key is > >replaced by a second ENTER and the left Alt key is used as Meta key > >instead of Option key. > > > >I tried to configure the keyboard with the graphical interface but I > >wasn't able solve my problem. If, for example I press Alt+Tab, I was > >able to switch between the different windows, but the Alt key doesn't > >work both in the various text editors (emacs, gedit...) and in the > >terminal, to type the extra character such as tilde, square brackets... > > > >I think I should re-map my keyboard replacing the extra ENTER with the > >Alt(Option) key but I have no idea how to do this. > > > >Do you have any suggestion? > >
Install the package xev if you don't already have it, and read the man page. Xev will allow you to see which key generates what keycode. Won't help in the console, but using an xwindows environment you can remap your keys as you wish using xmodmap. (read "man xmodmap"). Sorry for the overgeneralization, but I haven't had the need to do this in a few years, so only vaguely recall what I did... > > When away from home base, remapping would be preferable, but at > home, you might get a full-sized PC keyboard that works the way you > expect. You would have to re-configure the key layout every time you > switched, but it's something to consider. > No problem, you just use shell aliases (or little scripts) and have them point to (for example) .xmodmap0 and xmodmap1, as replacements for the standard xmodmap. Create keybindings to switch from one to the other in your window manager, and at the stroke of a key you can switch from one layout to the other. I know this is all very general and probably sounds dreadfully opaque, but once you have the actual keycodes if you need more help just come back and post the details. Here's the xev output for my "Return" key, just to show you what to look for. It's different on different keyboards, so this is only an example: KeyRelease event, serial 35, synthetic NO, window 0x1800001, root 0x128, subw 0x0, time 20931520, (-6,197), root:(15,331), state 0x0, keycode 36 (keysym 0xff0d, Return), same_screen YES, " XLookupString gives 1 bytes: (0d) " XFilterEvent returns: False So when you see something similar for each key you want to redefine, you know you're on to something. :) Good luck! -- ❤ ♫ ❤ ♫ ❤ ♫ ❤ Indulekha -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20120503034212.GA6321@radhesyama