… | |
… | |
178 | #endif |
178 | #endif |
179 | }; |
179 | }; |
180 | |
180 | |
181 | ///////////////////////////////////////////////////////////////////////////// |
181 | ///////////////////////////////////////////////////////////////////////////// |
182 | |
182 | |
183 | #ifdef USE_XIM |
183 | #if USE_XIM |
184 | struct rxvt_xim : refcounted |
184 | struct rxvt_xim : refcounted |
185 | { |
185 | { |
186 | void destroy (); |
186 | void destroy (); |
187 | rxvt_display *display; |
187 | rxvt_display *display; |
188 | |
188 | |
… | |
… | |
218 | void clear (); |
218 | void clear (); |
219 | }; |
219 | }; |
220 | |
220 | |
221 | enum { |
221 | enum { |
222 | DISPLAY_HAS_RENDER = 1 << 0, |
222 | DISPLAY_HAS_RENDER = 1 << 0, |
|
|
223 | DISPLAY_HAS_RENDER_10 = 1 << 1, |
223 | DISPLAY_HAS_RENDER_MUL = 1 << 1, |
224 | DISPLAY_HAS_RENDER_MUL = 1 << 2, |
224 | DISPLAY_HAS_RENDER_CONV = 1 << 2, |
225 | DISPLAY_HAS_RENDER_CONV = 1 << 3, |
225 | }; |
226 | }; |
226 | |
227 | |
227 | struct rxvt_display : refcounted |
228 | struct rxvt_display : refcounted |
228 | { |
229 | { |
229 | event_vec<xevent_watcher> xw; |
230 | event_vec<xevent_watcher> xw; |
230 | |
231 | |
231 | ev::prepare flush_ev; void flush_cb (ev::prepare &w, int revents); |
232 | ev::prepare flush_ev; void flush_cb (ev::prepare &w, int revents); |
232 | ev::io x_ev ; void x_cb (ev::io &w, int revents); |
233 | ev::io x_ev ; void x_cb (ev::io &w, int revents); |
233 | |
234 | |
234 | #ifdef USE_XIM |
235 | #if USE_XIM |
235 | refcache<rxvt_xim> xims; |
236 | refcache<rxvt_xim> xims; |
236 | vector<im_watcher *> imw; |
237 | vector<im_watcher *> imw; |
237 | |
238 | |
238 | void im_change_cb (); |
239 | void im_change_cb (); |
239 | void im_change_check (); |
240 | void im_change_check (); |
… | |
… | |
268 | void set_selection_owner (rxvt_term *owner, bool clipboard); |
269 | void set_selection_owner (rxvt_term *owner, bool clipboard); |
269 | |
270 | |
270 | void reg (xevent_watcher *w); |
271 | void reg (xevent_watcher *w); |
271 | void unreg (xevent_watcher *w); |
272 | void unreg (xevent_watcher *w); |
272 | |
273 | |
273 | #ifdef USE_XIM |
274 | #if USE_XIM |
274 | void reg (im_watcher *w); |
275 | void reg (im_watcher *w); |
275 | void unreg (im_watcher *w); |
276 | void unreg (im_watcher *w); |
276 | |
277 | |
277 | rxvt_xim *get_xim (const char *locale, const char *modifiers); |
278 | rxvt_xim *get_xim (const char *locale, const char *modifiers); |
278 | void put_xim (rxvt_xim *xim); |
279 | void put_xim (rxvt_xim *xim); |
279 | #endif |
280 | #endif |
280 | }; |
281 | }; |
281 | |
282 | |
282 | #ifdef USE_XIM |
283 | #if USE_XIM |
283 | struct im_watcher : rxvt_watcher, callback<void (void)> |
284 | struct im_watcher : rxvt_watcher, callback<void (void)> |
284 | { |
285 | { |
285 | void start (rxvt_display *display) |
286 | void start (rxvt_display *display) |
286 | { |
287 | { |
287 | display->reg (this); |
288 | display->reg (this); |