diff -urN gtksourceview-1.0.1-orig/gtksourceview/gtksourceview.c gtksourceview-1.0.1/gtksourceview/gtksourceview.c
--- gtksourceview-1.0.1-orig/gtksourceview/gtksourceview.c	2004-09-21 20:12:40.496155000 +0900
+++ gtksourceview-1.0.1/gtksourceview/gtksourceview.c	2004-09-21 20:07:06.896009000 +0900
@@ -1687,6 +1687,7 @@
 	GtkTextIter cur;
 	GtkTextMark *mark;
 	gint key;
+	static gboolean imflag = FALSE;
 
 	view = GTK_SOURCE_VIEW (widget);
 	buf = gtk_text_view_get_buffer (GTK_TEXT_VIEW (widget));
@@ -1696,6 +1697,12 @@
 	mark = gtk_text_buffer_get_insert (buf);
 	gtk_text_buffer_get_iter_at_mark (buf, &cur, mark);
 	
+	if (gtk_im_context_filter_keypress(GTK_TEXT_VIEW(widget)->im_context, event) == TRUE)
+	{
+		if (imflag) imflag = FALSE;
+		else imflag = TRUE;
+		return TRUE;
+	}
 	if ((key == GDK_Return) && view->priv->auto_indent)
 	{
 		/* Auto-indent means that when you press ENTER at the end of a
@@ -1703,6 +1710,17 @@
 		 * level as the previous line.
 		 */
 		gchar *indent = NULL;
+		if (imflag)
+		{
+			gchar *str;
+			PangoAttrList *attr;
+			gint cursor_pos;
+			gtk_im_context_get_preedit_string (
+				GTK_TEXT_VIEW(widget)->im_context, &str, &attr, 
+				&cursor_pos);
+			if (str && strlen(str))
+				return FALSE;
+		}
 
 		/* Calculate line indentation and create indent string. */
 		indent = compute_indentation (view, 
