Mercurial > emacs
comparison src/xfns.c @ 89145:9feda646c377
(x_window, x_window): Use use_xim.
author | Dave Love <fx@gnu.org> |
---|---|
date | Sat, 05 Oct 2002 14:38:51 +0000 |
parents | aabfe2dc76da |
children | ffa18ef18e45 |
comparison
equal
deleted
inserted
replaced
89144:ab07a01e1a94 | 89145:9feda646c377 |
---|---|
3429 | 3429 |
3430 static XFontSet xic_create_xfontset P_ ((struct frame *, char *)); | 3430 static XFontSet xic_create_xfontset P_ ((struct frame *, char *)); |
3431 static XIMStyle best_xim_style P_ ((XIMStyles *, XIMStyles *)); | 3431 static XIMStyle best_xim_style P_ ((XIMStyles *, XIMStyles *)); |
3432 | 3432 |
3433 | 3433 |
3434 /* Supported XIM styles, ordered by preferenc. */ | 3434 /* Supported XIM styles, ordered by preference. */ |
3435 | 3435 |
3436 static XIMStyle supported_xim_styles[] = | 3436 static XIMStyle supported_xim_styles[] = |
3437 { | 3437 { |
3438 XIMPreeditPosition | XIMStatusArea, | 3438 XIMPreeditPosition | XIMStatusArea, |
3439 XIMPreeditPosition | XIMStatusNothing, | 3439 XIMPreeditPosition | XIMStatusNothing, |
3885 class_hints.res_class = (char *) XSTRING (Vx_resource_class)->data; | 3885 class_hints.res_class = (char *) XSTRING (Vx_resource_class)->data; |
3886 XSetClassHint (FRAME_X_DISPLAY (f), XtWindow (shell_widget), &class_hints); | 3886 XSetClassHint (FRAME_X_DISPLAY (f), XtWindow (shell_widget), &class_hints); |
3887 | 3887 |
3888 #ifdef HAVE_X_I18N | 3888 #ifdef HAVE_X_I18N |
3889 FRAME_XIC (f) = NULL; | 3889 FRAME_XIC (f) = NULL; |
3890 #ifdef USE_XIM | 3890 if (use_xim) |
3891 create_frame_xic (f); | 3891 create_frame_xic (f); |
3892 #endif | |
3893 #endif | 3892 #endif |
3894 | 3893 |
3895 f->output_data.x->wm_hints.input = True; | 3894 f->output_data.x->wm_hints.input = True; |
3896 f->output_data.x->wm_hints.flags |= InputHint; | 3895 f->output_data.x->wm_hints.flags |= InputHint; |
3897 XSetWMHints (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), | 3896 XSetWMHints (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), |
3990 InputOutput, /* class */ | 3989 InputOutput, /* class */ |
3991 FRAME_X_VISUAL (f), | 3990 FRAME_X_VISUAL (f), |
3992 attribute_mask, &attributes); | 3991 attribute_mask, &attributes); |
3993 | 3992 |
3994 #ifdef HAVE_X_I18N | 3993 #ifdef HAVE_X_I18N |
3995 #ifdef USE_XIM | 3994 if use_xim |
3996 create_frame_xic (f); | 3995 { |
3997 if (FRAME_XIC (f)) | 3996 create_frame_xic (f); |
3998 { | 3997 if (FRAME_XIC (f)) |
3999 /* XIM server might require some X events. */ | 3998 { |
4000 unsigned long fevent = NoEventMask; | 3999 /* XIM server might require some X events. */ |
4001 XGetICValues(FRAME_XIC (f), XNFilterEvents, &fevent, NULL); | 4000 unsigned long fevent = NoEventMask; |
4002 attributes.event_mask |= fevent; | 4001 XGetICValues(FRAME_XIC (f), XNFilterEvents, &fevent, NULL); |
4003 attribute_mask = CWEventMask; | 4002 attributes.event_mask |= fevent; |
4004 XChangeWindowAttributes (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), | 4003 attribute_mask = CWEventMask; |
4005 attribute_mask, &attributes); | 4004 XChangeWindowAttributes (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), |
4006 } | 4005 attribute_mask, &attributes); |
4007 #endif | 4006 } |
4007 } | |
4008 #endif /* HAVE_X_I18N */ | 4008 #endif /* HAVE_X_I18N */ |
4009 | 4009 |
4010 validate_x_resource_name (); | 4010 validate_x_resource_name (); |
4011 | 4011 |
4012 class_hints.res_name = (char *) XSTRING (Vx_resource_name)->data; | 4012 class_hints.res_name = (char *) XSTRING (Vx_resource_name)->data; |