about summary refs log tree commit diff
path: root/exwm-core.el
diff options
context:
space:
mode:
authorSteven Allen <steven@stebalien.com>2022-07-25T16·33-0700
committerAdrián Medraño Calvo <adrian@medranocalvo.com>2022-11-22T00·00+0000
commit4e1bb33f3782e82bacf2940eeb22f4b1e3daef76 (patch)
tree282c494eb68542cd5287a13310809f818df6ec8f /exwm-core.el
parente9cc0962cc478640afe3001e39ff32577d73d6a0 (diff)
Add a module for setting the X background
When enabled, EXWM will automatically set the background color either
the user-specified color, or theme's default background color. This will
even work with compositors such as picom.

* background.el: add it.
* exwm-core (exwm--intern-atom): optionally take a conn.
Diffstat (limited to 'exwm-core.el')
-rw-r--r--exwm-core.el4
1 files changed, 2 insertions, 2 deletions
diff --git a/exwm-core.el b/exwm-core.el
index 995b590dc582..3215dcdd2c32 100644
--- a/exwm-core.el
+++ b/exwm-core.el
@@ -155,9 +155,9 @@ Nil can be passed as placeholder."
                                          (if height xcb:ConfigWindow:Height 0))
                      :x x :y y :width width :height height)))
 
-(defun exwm--intern-atom (atom)
+(defun exwm--intern-atom (atom &optional conn)
   "Intern X11 ATOM."
-  (slot-value (xcb:+request-unchecked+reply exwm--connection
+  (slot-value (xcb:+request-unchecked+reply (or conn exwm--connection)
                   (make-instance 'xcb:InternAtom
                                  :only-if-exists 0
                                  :name-len (length atom)