Tk Source Code

Artifact [1c685dcd53]
Login

Artifact 1c685dcd535906d3f1e9d7dbc2d873ec5214e49c:

Attachment "XIM.patch" to ticket [905830ffff] added by lvirden 2004-05-04 18:33:05.
--- tkkanji.8.4.6/generic/tkEvent.c.orig	2004-04-21 10:44:16.301142000 -0400
+++ tkkanji.8.4.6/generic/tkEvent.c	2004-04-21 10:50:09.824780000 -0400
@@ -13,3 +13,3 @@
  *
- * RCS: @(#) $Id: tkEvent.c,v 1.17.2.2 2004/02/16 23:09:25 wolfsuit Exp $
+ * RCS: @(#) $Id: tkEvent.c,v 1.17.2.2.CAS 2004/04/21 10:50:00 lvirden Exp $
  */
@@ -885,2 +885,3 @@
 	if (!(winPtr->flags & (TK_CHECKED_IC|TK_ALREADY_DEAD))) {
+	    long im_event_mask = 0L;
 	    winPtr->flags |= TK_CHECKED_IC;
@@ -938,2 +939,9 @@
 	    }
+	    XGetICValues(winPtr->inputContext,
+		XNFilterEvents, &im_event_mask, NULL);
+	    if (im_event_mask != 0L) {
+		XSelectInput(winPtr->display, winPtr->window,
+		    winPtr->atts.event_mask | im_event_mask);
+		XSetICFocus(winPtr->inputContext);
+	    }
 	}