comparison src/xterm.c @ 27619:1d5c785bca99

* xterm.c (x_display_and_set_cursor): Set pre-edit area. (x_display_cursor): Don't set it here. (XTread_socket) [HAVE_X_I18N] <KeyPress, KeyRelease>: Don't dispatch the event.
author Gerd Moellmann <gerd@gnu.org>
date Sat, 05 Feb 2000 16:47:08 +0000
parents 7454554ca53d
children 72e15185eeb5
comparison
equal deleted inserted replaced
27618:3afff8dbcdac 27619:1d5c785bca99
9488 abort (); 9488 abort ();
9489 } 9489 }
9490 else 9490 else
9491 abort (); 9491 abort ();
9492 } 9492 }
9493 #ifdef HAVE_X_I18N
9494 /* Don't dispatch this event since XtDispatchEvent calls
9495 XFilterEvent, and two calls in a row may freeze the
9496 client. */
9497 break;
9498 #else
9493 goto OTHER; 9499 goto OTHER;
9500 #endif
9494 9501
9495 case KeyRelease: 9502 case KeyRelease:
9503 #ifdef HAVE_X_I18N
9504 /* Don't dispatch this event since XtDispatchEvent calls
9505 XFilterEvent, and two calls in a row may freeze the
9506 client. */
9507 break;
9508 #else
9496 goto OTHER; 9509 goto OTHER;
9510 #endif
9497 9511
9498 /* Here's a possible interpretation of the whole 9512 /* Here's a possible interpretation of the whole
9499 FocusIn-EnterNotify FocusOut-LeaveNotify mess. If 9513 FocusIn-EnterNotify FocusOut-LeaveNotify mess. If
9500 you get a FocusIn event, you have to get a FocusOut 9514 you get a FocusIn event, you have to get a FocusOut
9501 event before you relinquish the focus. If you 9515 event before you relinquish the focus. If you
10385 break; 10399 break;
10386 10400
10387 default: 10401 default:
10388 abort (); 10402 abort ();
10389 } 10403 }
10404
10405 #ifdef HAVE_X_I18N
10406 if (w == XWINDOW (f->selected_window))
10407 if (FRAME_XIC (f) && (FRAME_XIC_STYLE (f) & XIMPreeditPosition))
10408 xic_set_preeditarea (w, x, y);
10409 #endif
10390 } 10410 }
10391 10411
10392 #ifndef XFlush 10412 #ifndef XFlush
10393 if (updating_frame != f) 10413 if (updating_frame != f)
10394 XFlush (FRAME_X_DISPLAY (f)); 10414 XFlush (FRAME_X_DISPLAY (f));
10407 struct window *w; 10427 struct window *w;
10408 int on, hpos, vpos, x, y; 10428 int on, hpos, vpos, x, y;
10409 { 10429 {
10410 BLOCK_INPUT; 10430 BLOCK_INPUT;
10411 x_display_and_set_cursor (w, on, hpos, vpos, x, y); 10431 x_display_and_set_cursor (w, on, hpos, vpos, x, y);
10412
10413 #ifdef HAVE_X_I18N
10414 {
10415 struct frame *f = XFRAME (w->frame);
10416
10417 if (w == XWINDOW (f->selected_window))
10418 if (FRAME_XIC (f) && (FRAME_XIC_STYLE (f) & XIMPreeditPosition))
10419 xic_set_preeditarea (w, x, y);
10420 }
10421 #endif
10422
10423 UNBLOCK_INPUT; 10432 UNBLOCK_INPUT;
10424 } 10433 }
10425 10434
10426 10435
10427 /* Display the cursor on window W, or clear it, according to ON_P. 10436 /* Display the cursor on window W, or clear it, according to ON_P.