comparison src/input-method-xlib.c @ 448:3078fd1074e8 r21-2-39

Import from CVS: tag r21-2-39
author cvs
date Mon, 13 Aug 2007 11:38:25 +0200
parents 576fb035e263
children 183866b06e0b
comparison
equal deleted inserted replaced
447:4fc5f13f3bd3 448:3078fd1074e8
78 #include "buffer.h" 78 #include "buffer.h"
79 #include "console-x.h" 79 #include "console-x.h"
80 #include "EmacsFrame.h" 80 #include "EmacsFrame.h"
81 #include "events.h" 81 #include "events.h"
82 82
83 #ifndef XIM_XLIB 83 #if !defined (XIM_XLIB) && !defined (USE_XFONTSET)
84 #error XIM_XLIB is not defined?? 84 #error neither XIM_XLIB nor USE_XFONTSET is defined??
85 #endif 85 #endif
86 86
87 Lisp_Object Qxim_xlib; 87 Lisp_Object Qxim_xlib;
88 #define xim_warn(str) warn_when_safe (Qxim_xlib, Qwarning, str); 88 #define xim_warn(str) warn_when_safe (Qxim_xlib, Qwarning, str);
89 #define xim_warn1(fmt, str) warn_when_safe (Qxim_xlib, Qwarning, fmt, str); 89 #define xim_warn1(fmt, str) warn_when_safe (Qxim_xlib, Qwarning, fmt, str);
90 #define xim_info(str) warn_when_safe (Qxim_xlib, Qinfo, str); 90 #define xim_info(str) warn_when_safe (Qxim_xlib, Qinfo, str);
91 91
92 #ifdef XIM_XLIB /* XIM_XLIB specific */
92 /* Get/Set IC values for just one attribute */ 93 /* Get/Set IC values for just one attribute */
93 #ifdef DEBUG_XEMACS 94 #ifdef DEBUG_XEMACS
94 #define XIC_Value(Get_Set, xic, name, attr, value) \ 95 #define XIC_Value(Get_Set, xic, name, attr, value) \
95 do { \ 96 do { \
96 char *bad_arg; \ 97 char *bad_arg; \
118 "XIMPreeditNone|XIMStatusArea\n" 119 "XIMPreeditNone|XIMStatusArea\n"
119 "XIMPreeditNone|XIMStatusNothing\n" 120 "XIMPreeditNone|XIMStatusNothing\n"
120 "XIMPreeditNone|XIMStatusNone"; 121 "XIMPreeditNone|XIMStatusNone";
121 122
122 static XIMStyle best_style (XIMStyles *user, XIMStyles *xim); 123 static XIMStyle best_style (XIMStyles *user, XIMStyles *xim);
124 #endif /* XIM_XLIB only */
123 125
124 /* This function is documented, but no prototype in the header files */ 126 /* This function is documented, but no prototype in the header files */
125 EXTERN_C char * XSetIMValues(XIM, ...); 127 EXTERN_C char * XSetIMValues(XIM, ...);
126 128
127 void 129 void
172 { 174 {
173 xim_warn ("XSetLocaleModifiers(\"\") failed\n" 175 xim_warn ("XSetLocaleModifiers(\"\") failed\n"
174 "Check the value of the XMODIFIERS environment variable.\n"); 176 "Check the value of the XMODIFIERS environment variable.\n");
175 } 177 }
176 } 178 }
179
180 #ifdef XIM_XLIB /* starting XIM specific codes */
177 181
178 /* Callbacks for IM are supported from X11R6 or later. */ 182 /* Callbacks for IM are supported from X11R6 or later. */
179 #ifdef HAVE_XREGISTERIMINSTANTIATECALLBACK 183 #ifdef HAVE_XREGISTERIMINSTANTIATECALLBACK
180 184
181 static Boolean xim_initted = False; 185 static Boolean xim_initted = False;
1111 stderr_out ("Unit_Test: toVal.size=%d\n", toVal.size); 1115 stderr_out ("Unit_Test: toVal.size=%d\n", toVal.size);
1112 describe_XIMStyles ((XIMStyles *) toVal.addr); 1116 describe_XIMStyles ((XIMStyles *) toVal.addr);
1113 } 1117 }
1114 } 1118 }
1115 #endif 1119 #endif
1120 #endif /* XIM_XLIB only */
1116 1121
1117 #if 0 1122 #if 0
1118 /* Get a fontset for IM to use */ 1123 /* Get a fontset for IM to use */
1119 void 1124 void
1120 x_init_fontset (struct device *d) 1125 x_init_fontset (struct device *d)