… | |
… | |
59 | #if ENABLE_EWMH |
59 | #if ENABLE_EWMH |
60 | XA_NET_WM_PID, |
60 | XA_NET_WM_PID, |
61 | XA_NET_WM_NAME, |
61 | XA_NET_WM_NAME, |
62 | XA_NET_WM_ICON_NAME, |
62 | XA_NET_WM_ICON_NAME, |
63 | XA_NET_WM_PING, |
63 | XA_NET_WM_PING, |
|
|
64 | XA_NET_WM_ICON, |
64 | #endif |
65 | #endif |
65 | #if USE_XIM |
66 | #if USE_XIM |
66 | XA_WM_LOCALE_NAME, |
67 | XA_WM_LOCALE_NAME, |
67 | XA_XIM_SERVERS, |
68 | XA_XIM_SERVERS, |
68 | #endif |
69 | #endif |
… | |
… | |
73 | #if ENABLE_XEMBED |
74 | #if ENABLE_XEMBED |
74 | XA_XEMBED, |
75 | XA_XEMBED, |
75 | XA_XEMBED_INFO, |
76 | XA_XEMBED_INFO, |
76 | #endif |
77 | #endif |
77 | #if !ENABLE_MINIMAL |
78 | #if !ENABLE_MINIMAL |
78 | // these are usually allocated by other subsystens, but we do it |
79 | // these are usually allocated by other subsystems, but we do it |
79 | // here to avoid a server roundtrip. |
80 | // here to avoid a server roundtrip. |
80 | XA_SCREEN_RESOURCES, |
81 | XA_SCREEN_RESOURCES, |
81 | XA_XDCCC_LINEAR_RGB_CORRECTION, |
82 | XA_XDCCC_LINEAR_RGB_CORRECTION, |
82 | XA_XDCCC_LINEAR_RGB_MATRICES, |
83 | XA_XDCCC_LINEAR_RGB_MATRICES, |
83 | XA_WM_COLORMAP_WINDOWS, |
84 | XA_WM_COLORMAP_WINDOWS, |
… | |
… | |
267 | void put_xim (rxvt_xim *xim); |
268 | void put_xim (rxvt_xim *xim); |
268 | #endif |
269 | #endif |
269 | }; |
270 | }; |
270 | |
271 | |
271 | #ifdef USE_XIM |
272 | #ifdef USE_XIM |
272 | struct im_watcher : rxvt_watcher, callback<void (void)> { |
273 | struct im_watcher : rxvt_watcher, callback<void (void)> |
|
|
274 | { |
273 | void start (rxvt_display *display) |
275 | void start (rxvt_display *display) |
274 | { |
276 | { |
275 | display->reg (this); |
277 | display->reg (this); |
276 | } |
278 | } |
277 | |
279 | |
… | |
… | |
329 | operator Pixel () const { return c.pixel; } |
331 | operator Pixel () const { return c.pixel; } |
330 | |
332 | |
331 | bool operator == (const rxvt_color &b) const { return Pixel (*this) == Pixel (b); } |
333 | bool operator == (const rxvt_color &b) const { return Pixel (*this) == Pixel (b); } |
332 | bool operator != (const rxvt_color &b) const { return Pixel (*this) != Pixel (b); } |
334 | bool operator != (const rxvt_color &b) const { return Pixel (*this) != Pixel (b); } |
333 | |
335 | |
|
|
336 | bool is_opaque () const |
|
|
337 | { |
|
|
338 | #if XFT |
|
|
339 | return c.color.alpha == rgba::MAX_CC; |
|
|
340 | #else |
|
|
341 | return 1; |
|
|
342 | #endif |
|
|
343 | } |
|
|
344 | |
334 | bool alloc (rxvt_screen *screen, const rgba &color); |
345 | bool alloc (rxvt_screen *screen, const rgba &color); |
335 | void free (rxvt_screen *screen); |
346 | void free (rxvt_screen *screen); |
336 | |
347 | |
337 | void get (rgba &color); |
348 | void get (rgba &color); |
338 | void get (XColor &color); |
349 | void get (XColor &color); |