From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Harry Putnam Newsgroups: gmane.emacs.help Subject: Re: Strange characters produced by M-x in emacs -nw Date: Fri, 20 Sep 2013 16:21:24 -0400 Organization: Still searching... Message-ID: <87li2rmegr.fsf@newsguy.com> References: <87r4cnmlxf.fsf@newsguy.com> <5D24468E-2A38-4F4C-AD14-9A1401683124@Web.DE> <8738oz5uh4.fsf@newsguy.com> <20130920172847.GA30192@hysteria.proulx.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1379708528 12547 80.91.229.3 (20 Sep 2013 20:22:08 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 20 Sep 2013 20:22:08 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Sep 20 22:22:11 2013 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VN7DO-0004DV-Rh for geh-help-gnu-emacs@m.gmane.org; Fri, 20 Sep 2013 22:22:11 +0200 Original-Received: from localhost ([::1]:57711 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VN7DO-0004rV-Cl for geh-help-gnu-emacs@m.gmane.org; Fri, 20 Sep 2013 16:22:10 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:37029) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VN7D5-0004rI-Fu for help-gnu-emacs@gnu.org; Fri, 20 Sep 2013 16:21:57 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VN7Cu-0000GI-Lz for help-gnu-emacs@gnu.org; Fri, 20 Sep 2013 16:21:51 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:51005) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VN7Cu-0000Fs-B3 for help-gnu-emacs@gnu.org; Fri, 20 Sep 2013 16:21:40 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1VN7Cr-00034L-E5 for help-gnu-emacs@gnu.org; Fri, 20 Sep 2013 22:21:37 +0200 Original-Received: from z65-50-57-227.ips.direcpath.com ([65.50.57.227]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 20 Sep 2013 22:21:37 +0200 Original-Received: from reader by z65-50-57-227.ips.direcpath.com with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 20 Sep 2013 22:21:37 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 199 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: z65-50-57-227.ips.direcpath.com User-Agent: Gnus/5.130008 (Ma Gnus v0.8) Emacs/24.0.92 (gnu/linux) Cancel-Lock: sha1:upJtDyhTGsDKToC/UuZYcRKjRN0= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:93476 Archived-At: Bob Proulx writes: > Harry Putnam wrote: >> `M-x' produces 'ø' >> `M-Shift + !' produces '¡' >> `M-shift + : produces 'º' >> [...] >> That said, yes, I am referring to the Alt labeled on most common >> keyboards... at least in the US. >> [...] >> I'm still puzzled but the way this problem just turned up sort of >> suddenly. .. I mean I don't often use emacs -nw when in X but it can't >> have been more that 5-6 mnths since last time. >> >> So something has changed in my environment on my Debian Linux box of >> several yrs standing. Possibly an update or something. I had >> thoughts of tracking it down... but probably a loosing battle since >> I'm not sure of when the change occurred. > > Almost certainly something with your keyboard mapping has changed. I > suspect that the Alt key has been configured as an AltGr key, or a > compose key, or other such modifier. It definitely isn't normal for > Alt-x to produce the special zero character. Which Alt key is this? > The left or right Alt key? Or both? Both Perhaps the output of xmodmap will tell you something? (PS - I have not ~/.xmodmap) ,---- | xmodmap: up to 4 keys per modifier, (keycodes in parentheses): | | shift Shift_L (0x32), Shift_R (0x3e) | lock Caps_Lock (0x42) | control Control_L (0x25), Control_R (0x69) | mod1 Alt_L (0x40), Alt_R (0x6c), Meta_L (0xcd) | mod2 Num_Lock (0x4d) | mod3 | mod4 Super_L (0x85), Super_R (0x86), Super_L (0xce), Hyper_L (0xcf) | mod5 ISO_Level3_Shift (0x5c), Mode_switch (0xcb) `---- > Check the timestamp to see if the file /etc/default/keyboard has > been updated recently? It is fairly new (Aug 5), but running a diff on it going back as far as July of 2012... it hasn't changed. It does specify a 105 key keyboard and mine is 104... but it must have said 105 longer than I have had this problem. I did do a fairly hefty update fairly recently but had been noticing this problem for a while. ,---- | Content of /etc/defajult/keyboard | XKBMODEL="pc105" | XKBLAYOUT="us" | XKBVARIANT="" | XKBOPTIONS="" | | BACKSPACE="guess" `---- Here is something I just recalled; I just remembered, that I did have to buy a new keyboard recently... but its one of logitech's cheapo models.. bought at Walmart) > . . . . . . . . . . This is also managed by the > keyboard-configuration package in Debian. You can run > 'dpkg-reconfigure keyboard-configuration' if you would like to > re-run the package configuration dialogs. After reconfiguring any > custom xmodmap commands such as to remap the control key will need > to be run again. I have no custom .xmodmap to worry about, haven't every really noticed a need for it. Except when I run openindian (a solaris variant) or Oracle solaris. Those are not emacs friendly like most linux distros. Should I expect any changes brought about by running the dpkg stuff, to take effect immediately or do I need to restart X? > You should decide what keys you would like to use for AltGr and > Compose. Thinking about laptops without all of the keys means that > sometimes compromises must be made to select the best available key > and sometimes not the best key everywhere. For example on my laptop > I use the right Alt for AltGr and right Control for Compose. But > the logo key and the menu key are also possible. I'd never heard of an Altgr key. And just now googling It appears not to be something I'd get much out of... also appears to be usually on the right where my keyboard just says Alt. I'm probably not thinking clearly but why do I need to decide which keys I want to use for it? Is it now a default thing on all keyboards or something? > A typical configuration line from /etc/default/keyboard might be: > > XKBOPTIONS="lv3:ralt_switch,compose:menu,terminate:ctrl_alt_bksp" Mine, which must be default since I've not meddled with it, (unless it is meddled with during install?)) doesn't have any OPTIONS ... just "" > [Of course choice of terminate is old-school and has become > controvercial of late. I still prefer it. YMMV. I will include it > but if you think it is dangerous then by all means leave it off.] Once again, I don't know what you are talking about right above. What is 'Terminate' used in that context? > Alternatively you can twiddle the mapping directly using the setxkbmap > command. I would play with the following interactively and see if it > solves your problem. > > $ setxkbmap -model pc104 -layout us -option compose:rctrl -option > Should I see results immediately or does this require a restart of X? > Or if not try setting the AltGr variant explicitly: > > $ setxkbmap -model pc104 -layout us -variant altgr-intl -option > compose:rctrl -option terminate:ctrl_alt_bksp Neither of those has any immediate effect. > Does that repair your problem with Alt? (For me I move control and > other customizations using xmodmap. Therefore after running the above > which resets everything note that I load 'xmodmap $HOME/.xmodmap' in > order to overlay my customizations.) > > To see what the Compose key setting is doing try these combinations. > Do not hold down the Compose key. It is not a shift or control key > any longer. Tap the Compose key. Nothing will be displayed. Tap the > next letter. Nothing will be displayed. Tap the final letter. The > composed character will be displayed. One, two, three. Tap, tap, > tap. The letter is displayed after the third keystroke. First off, what and where is the 'compose' key > Compose e ' -> é > Compose a " -> ä > Compose A ` -> À > > Or the reverse. Use whichever makes sense to your brain. > > Compose ' e -> é > Compose " a -> ä > Compose ^ a -> â > Compose , c -> ç I don't see any of this happening with any of my keys listed: Left (going left from space bar): Ctrl, windows logo key (left of alt on left side - I've never known what that does), Alt. Right (going right from spacebar): Alt, Windows logo, Key with what looks like an image of a list?, Ctrl None of those do anything like what you show above. The only one that does anything on the first tap is the one that looks like a list, and it makes `9~' > And if you have loaded the AltGr variant then you can use > Right-Alt-somekey to produce characters using chords. AFAIK it is six > of one and a half dozen of the other. Personal preference as to which > you prefer. Personally I prefer the Compose key. > > The entire set of possible combinations is listed in this file. The > Compose key there is listed as Multi_key. To see how to type in any > particular character look through the file and see the combination. > > /usr/share/X11/locale/en_US.UTF-8/Compose Well, thanks for that, there are occasions when I want something unusual... the so called `mid-dot' springs to mind. (Tiny o in center of the line). [...] snipped interesting stuff > > XTerm*metaSendsEscape:true Another poster recommed that... but his was all lowercase, does it matter? ------- --------- ---=--- --------- -------- Thanks for all the helpful input. I'm still working with your suggestions and would appreciate any further input you might have. Hopefully some of my meandering will help you get a better idea of what I have here.