about summary refs log tree commit diff
path: root/exwm-floating.el
diff options
context:
space:
mode:
authorChris Feng <chris.w.feng@gmail.com>2016-08-12T11·18+0800
committerChris Feng <chris.w.feng@gmail.com>2016-08-12T11·18+0800
commitdb5128c1b9f77ecefd62a7150ccbdef33dd870af (patch)
tree6a6078d9d3bdd28e4dab4c28398aa698c408a810 /exwm-floating.el
parent8e3fc3602f649fca47a61a2be2072521a352a62a (diff)
Fix CreateWindow attributes
; Also fix various compile warnings.

* exwm-floating.el (exwm-floating--set-floating):
* exwm-manage.el (exwm-manage--manage-window):
* exwm-systemtray.el (exwm-systemtray--init):
* exwm-workspace.el (exwm-workspace--add-frame-as-workspace)
(exwm-workspace--init):
* exwm.el (exwm--init-icccm-ewmh):
Explicitly specify the class (InputOutput or InputOnly) and for an
InputOutput X window the background pixmap when creating an X window.
Diffstat (limited to 'exwm-floating.el')
-rw-r--r--exwm-floating.el20
1 files changed, 15 insertions, 5 deletions
diff --git a/exwm-floating.el b/exwm-floating.el
index 7c5d811bf5ca..6f6cfecbfe4a 100644
--- a/exwm-floating.el
+++ b/exwm-floating.el
@@ -70,11 +70,14 @@ context of the corresponding buffer.")
 
 (defvar exwm-workspace--current)
 (defvar exwm-workspace--struts)
+(defvar exwm-workspace--workareas)
+(defvar exwm-workspace-current-index)
 
 (declare-function exwm-layout--refresh "exwm-layout.el" ())
 (declare-function exwm-layout--show "exwm-layout.el" (id &optional window))
 (declare-function exwm-layout--iconic-state-p "exwm-layout.el" (&optional id))
 (declare-function exwm-workspace--minibuffer-own-frame-p "exwm-workspace.el")
+(declare-function exwm-workspace--position "exwm-workspace.el" (frame))
 
 (defun exwm-floating--set-floating (id)
   "Make window ID floating."
@@ -191,12 +194,19 @@ context of the corresponding buffer.")
       ;; a child of the X window container.
       (xcb:+request exwm--connection
           (make-instance 'xcb:CreateWindow
-                         :depth 0 :wid frame-container
+                         :depth 0
+                         :wid frame-container
                          :parent container
-                         :x 0 :y 0 :width width :height height :border-width 0
-                         :class xcb:WindowClass:CopyFromParent
-                         :visual 0      ;CopyFromParent
-                         :value-mask xcb:CW:OverrideRedirect
+                         :x 0
+                         :y 0
+                         :width width
+                         :height height
+                         :border-width 0
+                         :class xcb:WindowClass:InputOutput
+                         :visual 0
+                         :value-mask (logior xcb:CW:BackPixmap
+                                             xcb:CW:OverrideRedirect)
+                         :background-pixmap xcb:BackPixmap:ParentRelative
                          :override-redirect 1))
       ;; Put it at bottom.
       (xcb:+request exwm--connection