Article View: gnu.emacs.bug
Article #98854problem with SUN Type4 Kbd (azerty) and emacs under X11R4
From: Benoit Debande
Date: Wed, 20 Feb 1991 18:22
Date: Wed, 20 Feb 1991 18:22
98 lines
3849 bytes
3849 bytes
Hello,
Perhaps this is a bug report, but anyway it can help other people
I don't know if it is an EMACS bug or an X11R4 bug, but I think
that the problem is more towards X11R4 as the problem lies in
the header X11/Xutil.h
The problem :
I'm working on a SUN IPC (SUNOS4.1.0) under X11R4
with an azerty keyboard.
When I want to issue some characters as ( @ ~ \ 5 ~ ),
I must push the so-named "mode_switch" key plus the
corresponding key wher ethe symbol is written to the left.
To do this, I must declare the mode_switch as a modifier
via xmodmap statements.
BUT, in emacs, the mode_switch key (whatever keycode I assign to
this keysym) issue a <ESC> [-1z and I can't issue the famous
characters described earlier.
The solution :
1. While hacking the x11term.c and the X11/Xutil.c, I see that mode_switch
is considered as a MiscFunction key and NOT as a Modifier Key
( see #define IsMiscFunctionKey(keysym) in X11/Xutil.c )
2. I don't like to modify "standard X distribution" , so I modified
the emacs x11term.c (you can see the diff files lower)
3. With this modification, the Mode_switch key didn't work properly.
That's because I assigned this modifier to Mod1 and in
x11term.c , the Mod1 sets the METABIT
4. So I had to undefine mod1 and define mod2 to mode_switch
5. All works well ....
*** x11term.org Wed Feb 20 18:41:51 1991
--- x11term.c Wed Feb 20 18:40:49 1991
***************
*** 1407,1414 ****
/* Someday this will be unnecessary as we will
be able to use XRebindKeysym so XLookupString
will have already given us the string we want. */
! if (IsFunctionKey(keysym) ||
! IsMiscFunctionKey(keysym)) {
strcpy(mapping_buf,"[");
strcat(mapping_buf,stringFuncVal(keysym));
#ifdef sun
--- 1407,1423 ----
/* Someday this will be unnecessary as we will
be able to use XRebindKeysym so XLookupString
will have already given us the string we want. */
!
!
! /* Mode_switch ISN'T a function key
! * but IsMiscFunction returns true !
! *
! * B. DEBANDE 20/02/91
! */
!
! if (( (unsigned)(keysym) != XK_Mode_switch ) && (IsFunctionKey(keysym)
||
! IsMiscFunctionKey(keysym))) {
!
strcpy(mapping_buf,"[");
strcat(mapping_buf,stringFuncVal(keysym));
#ifdef sun
===============================================================================
Dr. Benoit DEBANDE E-MAIL : debande@smd.ucl.ac.be
School of Medicine debande@buclln11.bitnet
Catholic University of Louvain FAX : 32-2-7645322
Av. Hippocrate 50 (50.20) PHONE : 32-2-7645268
B-1200 BRUXELLES (BELGIUM)
===============================================================================
Theory : it doesn't work an you know why
Practice : it works an you don't know why
C programming : it doesn't work and you don't know why
===============================================================================
--
Technical Details
Message-ID:
<9102201822.AA01993@smdsun.smd.ucl.ac.be>Path:
arc1-ca.pugleaf.net!gmdzi!unido!fauern!ira.uka.de!sol.ctr.columbia.edu!spool.mu.edu!samsung!sdd.hp.com!elroy.jpl.nasa.gov!ncar!zaphod.mps.ohio-state.edu!tut.cis.ohio-state.edu!unreplyable!garbageShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fb2f1,3388a2678b0b2f9c,start X-Google-Attributes: gidfb2f1,public X-Google-ArrivalTime: 1991-02-20 10:22:46 PST Path: arc1-ca.pugleaf.net!gmdzi!unido!fauern!ira.uka.de!sol.ctr.columbia.edu!spool.mu.edu!samsung!sdd.hp.com!elroy.jpl.nasa.gov!ncar!zaphod.mps.ohio-state.edu!tut.cis.ohio-state.edu!unreplyable!garbage From: Debande%smd.ucl.ac.be@MITVMA.MIT.EDU (Benoit Debande) Newsgroups: gnu.emacs.bug Subject: problem with SUN Type4 Kbd (azerty) and emacs under X11R4 Message-ID: <9102201822.AA01993@smdsun.smd.ucl.ac.be> Date: 20 Feb 91 18:22:46 GMT Sender: daemon@tut.cis.ohio-state.edu Distribution: gnu Organization: GNUs Not Usenet Lines: 98 Approved: bug-gnu-emacs@prep.ai.mit.edu