On Sun, 2 Feb 2003, Angus Leeming wrote: > > > } > > > > 'Shift-Space' does not produce any print-out! In fact, I see that no > > signal from the keyboard is entering into this part in input.c. Hm....... > > Does input.c get called at all for any keypress events. Must do. (Add a print$ > at the very top of the file.) >
Not the entire input.c but the "do_keyboard" part of input.c. This happens only when the cursor is on the XWorkArea. On xforms-box, however, the keyboard event goes through do_keyboard part. > You mentioned earlier that when you are in composition mode 'Space' is handle$ > automatically by X. Ie it 'knows" that this means that composition is now > finished and that it should give you the keysym for the fully composed Korean > char when you look for it in XmbLookupString. > I have now second thought by looking at the debug messages below.... > Is 'Shift-Space' also 'hardcoded' in this way. Ie, if you have created > form->xic when you show the window, does this mean that 'Shift-Space' is used > to tell X that composition is starting? > > If so then your 'Shift Space' has the same role as my 'Multi_key'. > > I wonder if it returns some strange keysym from fl_XLookupString? Perhaps add > some code to do_keyboard, after the call to fl_XLookupString but before our > friend: > > /* keysym == NoSymbol during multi-byte char composition. > Eg, I've typed Multi_key-a but not yet ' to give > Silently swallow these partial-compositions. */ > if (keysym == NoSymbol && kbuflen == 0) > return; > > A few print statements never hurt ;-) > > printf("keysym %d, keybuf %s\n", keysym, keybuf); > if (keysym != 0) { > char const * const tmp = XKeysymToString(keysym); > printf("keysym is %s\n", tmp); > } > Here are debug messages: 1."Shift-Space";{(keysym 65505, keybuf ,keysym is Shift_L), (keysym 0, keybuf)} 2.during composition; {keysym 0, keybuf} 3."Space"; {(keysym 0, keybuf "some CJK-characters"), (keysym 32, keybuf,keysym is space)}. This tells you that I was wrong to say "keysym is non-zero for composed CJK-characters". I now wonder where I got this nonsense! Sorry for giving you a wrong information. > Apart from that, I'm out of ideas. > Oh, No! Don't be! cghan