aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--st.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/st.c b/st.c
index bb64c55..b89d094 100644
--- a/st.c
+++ b/st.c
@@ -3912,6 +3912,13 @@ run(void) {
/* Waiting for window mapping */
do {
XNextEvent(xw.dpy, &ev);
+ /*
+ * XFilterEvent is required to be called after you using XOpenIM,
+ * this is not unnecessary.It does not only filter the key event,
+ * but some clientmessage for input method as well.
+ */
+ if(XFilterEvent(&ev, None))
+ continue;
if(ev.type == ConfigureNotify) {
w = ev.xconfigure.width;
h = ev.xconfigure.height;
remember that computers suck.