[Mono-winforms-list] patch to filter some XIM events out #1

Atsushi Eno atsushi at ximian.com
Wed Feb 6 22:43:51 EST 2008


I had hard time to show XIM frontend UI on winforms. I'm still not fully
successful[*1], but now
at least I can enable XIM mode with scim.

Note that this patch does not enable internationalized text input yet.
There still seem some
or many issues that block Xutf8LookupString() results.

The patch is somehow questionable:

- I moved call to X11Keyboard.EnsureLayoutInitialized() to
X11Keyboard.ctor(). Without this
iiimx shows inconsistent key state[*2], but I'm not sure if this change
is mandatory.
- Now there are two filters for X11 events:
- for KeyPress and KeyRelease, for FocusWindow (as it used to be done).
- for everything, for IntPtr.Zero (i.e. event.AnyEvent.Window IIRC): it
is required to filter
XIM events out correctly. For example, XIM raises XClientMessageEvent
that should be
filtered out.

[*1] iiimx (atok x3) and kinput2 still fail for me.
[*2] Yes, I still cannot get its UI "show" up, but I can differentiate
its XIM-ish mode and
non-XIM-ish mode by not seeing keyboard inputs to a textbox.

I still need some more changes, but I think those changes could be applied.

Atsushi Eno

-------------- next part --------------
A non-text attachment was scrubbed...
Name: xim-filter-20080206.patch
Type: text/x-patch
Size: 4339 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/mono-winforms-list/attachments/20080207/88d05259/attachment.bin 

More information about the Mono-winforms-list mailing list