LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 12-08-2003, 09:36 PM   #1
cilantro
LQ Newbie
 
Registered: Dec 2003
Distribution: RH 9
Posts: 5

Rep: Reputation: 0
Emacs 8-bit input as meta key


When logged into a remote machine, I run emacs inside an xterm window using "emacs -nw".
Starting with emacs 21, I'm having trouble getting 8-bit data to be interpreted as a meta key; instead of M-d I get an a-umlaut. I have access to 4 Linux machines which behave differently:
Machine 1 (RH 9; emacs 21.2): LANG=en-US.UTF8 produces accented characters;
LANG=en-US gives meta key.
Machine 2 (RH 9; emacs 21.2): Always gives meta key.
Machine 3 (Debian 3; emacs 21.2): Always gives meta key.
Machine 4 (SuSE 9; emacs 21.3): Never gives meta key.
So far as I can tell, the environments on all 4 machines are the same, but I don't understand all this locale stuff, nor the new mule support in emacs.

Can someone tell me a reliable way to force emacs to interpret 8-bit characters the old way, that is, as though the meta key were held down? I'm willing to disable international character support if necessary. The only kluge I've been able to come up with is to reprogram all the 8-bit keys I use to not self-insert, but rather map to their meta equivalents, but there's surely a better way.

I'm considering switching from RH to SuSE, but want to get this resolved first if possible.

Thanks.
 
Old 12-08-2003, 09:43 PM   #2
ToniT
Senior Member
 
Registered: Oct 2003
Location: Zurich, Switzerland
Distribution: Debian/unstable
Posts: 1,357

Rep: Reputation: 47
Puting to your ~/.inputrc
Code:
set input-meta on
set output-meta on
set convert-meta off
might help.

I have also in my ~/.emacs
Code:
(custom-set-variables
 '(current-language-environment "Latin-9")
 '(default-input-method "latin-9-prefix")
 '(keyboard-coding-system (quote iso-latin-9))
)
 
Old 12-08-2003, 10:06 PM   #3
cilantro
LQ Newbie
 
Registered: Dec 2003
Distribution: RH 9
Posts: 5

Original Poster
Rep: Reputation: 0
Thanks, but neither of these worked.
(Your inputrc commands appear to be in /etc/inputrc already.)
 
Old 12-09-2003, 03:41 PM   #4
ToniT
Senior Member
 
Registered: Oct 2003
Location: Zurich, Switzerland
Distribution: Debian/unstable
Posts: 1,357

Rep: Reputation: 47
One more thing. In xterm, there is a setting (Ctrl-firstMouseButton) called 'Meta sends escape'. It might also have an effect.

To make setting permanent, put a line 'XTerm*metaSendsEscape: true' to your Xresourses file (/etc/Xresourses/aFile or ~/.Xresources). Loading of file in users home directory might depend on the distribution. 'xrdb -merge ~/.Xresources' changes the settings recardless of the distribution.
 
Old 12-09-2003, 09:27 PM   #5
cilantro
LQ Newbie
 
Registered: Dec 2003
Distribution: RH 9
Posts: 5

Original Poster
Rep: Reputation: 0
No change.

Meta commands in tcsh, which uses emacs-like syntax, work fine, even though the same commands yield 8-bit characters with "cat -v".
(This is true on all machines referred to in my original post.)

I think it must be an emacs setting; I want meta to load the esc-map, rather than self-insert commands.
 
Old 12-11-2003, 11:21 PM   #6
cilantro
LQ Newbie
 
Registered: Dec 2003
Distribution: RH 9
Posts: 5

Original Poster
Rep: Reputation: 0
Finally figured it out -- just put
(set-keyboard-coding-system nil)
in .emacs!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
.Xmodmap and meta key jrdioko Linux - Software 11 10-03-2005 07:09 AM
Changing the Meta key from Esc to Alt primo *BSD 0 08-27-2005 05:18 PM
Emacs Trouble, Meta key not working chandru.in Slackware 6 07-18-2005 04:53 AM
Best way to map Windows key to Meta in Terminal eltecolote Linux - General 1 06-15-2005 09:09 AM
xterm meta key bob66 Linux - Software 0 03-25-2005 09:26 AM


All times are GMT -5. The time now is 09:43 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration