emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/exwm 1e9be0d 3/3: Fix detection of `exwm-workspace--win


From: Chris Feng
Subject: [elpa] externals/exwm 1e9be0d 3/3: Fix detection of `exwm-workspace--window-y-offset'
Date: Wed, 2 Oct 2019 12:34:37 -0400 (EDT)

branch: externals/exwm
commit 1e9be0de384d0750277b350c77e5e4a5d8a8ae10
Author: Chris Feng <address@hidden>
Commit: Chris Feng <address@hidden>

    Fix detection of `exwm-workspace--window-y-offset'
    
    * exwm-workspace.el (exwm-workspace--update-offsets): Explicitly
    request the geometry of the container for the first workspace as it
    may not align with the top of the root X window.
---
 exwm-workspace.el | 14 ++++++++++----
 1 file changed, 10 insertions(+), 4 deletions(-)

diff --git a/exwm-workspace.el b/exwm-workspace.el
index 736f46f..705da30 100644
--- a/exwm-workspace.el
+++ b/exwm-workspace.el
@@ -417,13 +417,19 @@ NIL if FRAME is not a workspace"
       (with-slots (y)
           (xcb:+request-unchecked+reply exwm--connection
               (make-instance 'xcb:GetGeometry
-                             :drawable (frame-parameter frame 'exwm-outer-id)))
+                             :drawable (frame-parameter frame
+                                                        'exwm-container)))
         (with-slots ((y* y))
             (xcb:+request-unchecked+reply exwm--connection
                 (make-instance 'xcb:GetGeometry
-                               :drawable (frame-parameter frame 'exwm-id)))
-          (setq exwm-workspace--frame-y-offset (- y* y)
-                exwm-workspace--window-y-offset (- (elt edges 1) y)))))))
+                               :drawable (frame-parameter frame
+                                                          'exwm-outer-id)))
+          (with-slots ((y** y))
+              (xcb:+request-unchecked+reply exwm--connection
+                  (make-instance 'xcb:GetGeometry
+                                 :drawable (frame-parameter frame 'exwm-id)))
+            (setq exwm-workspace--frame-y-offset (- y** y*)
+                  exwm-workspace--window-y-offset (- (elt edges 1) y))))))))
 
 (defun exwm-workspace--set-active (frame active)
   "Make frame FRAME active on its monitor."



reply via email to

[Prev in Thread] Current Thread [Next in Thread]