Index: gtk/gtkimcontextsimple.c
===================================================================
--- gtk/gtkimcontextsimple.c	(revision 21583)
+++ gtk/gtkimcontextsimple.c	(working copy)
@@ -419,9 +419,32 @@
 #define IS_DEAD_KEY(k) \
     (((k) >= GDK_dead_grave && (k) <= (GDK_dead_dasia+1)) || \
      ((g_unichar_type (gdk_keyval_to_unicode (k)) == G_UNICODE_NON_SPACING_MARK) && \
-      ((k) < 0x1000000)))
+      ((k) < 0x1000000) && is_compose_script (gdk_keyval_to_unicode (k))))
 
 static gboolean
+is_compose_script (gunichar ch)
+{
+  static const GUnicodeScript compose_scripts[] = {
+    G_UNICODE_SCRIPT_COMMON,
+    G_UNICODE_SCRIPT_INHERITED,
+    G_UNICODE_SCRIPT_CYRILLIC,
+    G_UNICODE_SCRIPT_GREEK,
+    G_UNICODE_SCRIPT_LATIN,
+  };
+
+  GUnicodeScript script = g_unichar_get_script (ch);
+  gint i;
+
+  for (i = 0; i < G_N_ELEMENTS (compose_scripts); i++)
+    {
+      if (compose_scripts[i] == script)
+        return TRUE;
+    }
+
+  return FALSE;
+}
+
+static gboolean
 check_algorithmically (GtkIMContextSimple    *context_simple,
 		       gint                   n_compose)
 
