emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: "Outer world" encoding for non-Latin1 language environments


From: Anton Zinoviev
Subject: Re: "Outer world" encoding for non-Latin1 language environments
Date: Wed, 13 Mar 2002 22:13:13 +0200
User-agent: Mutt/1.2.5i

On  7.III.2002 at 08:02 Eli Zaretskii wrote:
> 
> On Wed, 6 Mar 2002, Anton Zinoviev wrote:
> 
> > I wanted to say that there are no problems in Linux console.  The
> > problems are only in X Window.  This makes me think that the problem is
> > not because of the locale-coding-system (I am not able to check this
> > right now).
> 
> Actually, this points into the direction I was thinking of: on a text 
> terminal locale-coding-system is not used to decode keyboard input, while 
> on X it is.

(Sorry for the delayed reply.)

I investigated what happened.

Emacs tries to get a code for the received xkeysym.  It gets this code
acording to encoding of the locale Emacs is started with.  If this
encoding includes the key-pressed symbol the result is an Emacs-event of
the form [194], where 194 is the code of the key-pressed symbol.  If
this symbol is not included in the encoding of the locale, then the
result is a symbol of the form [S-Cyrillic-A].  Emacs can't interpret
such sort of events (they are not bound to any action) and that's why I
got beeps -- I started Emacs under LANG=C and thus Cyrillic symbols were
not includes of the locale encoding (i.e. ASCII).  This is not a real
bug, but only a wishlist.

However Emacs beeps also for xkeysyms like ISO_Next_Group, thou it must
interpret them the same way as Mode_switch.  This is a bug, I've
attached the fix.

Copying from a KOI8-R of ISO-8859-5 xterm and pasting in Emacs works
fine -- the result are symbols from ISO-8859-5.  Copying from an Unicode
xterm gives Japanese double-width Cyrillic symbols.  The output of C-u
C-x = is attached.

Regards, Anton Zinoviev

Attachment: emacs-isokeys.patch
Description: Text document

Attachment: emacs-paste
Description: Text document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]