diff options
author | Chris Feng <chris.w.feng@gmail.com> | 2015-09-24T12·03+0800 |
---|---|---|
committer | Chris Feng <chris.w.feng@gmail.com> | 2015-09-24T12·03+0800 |
commit | 4ad76b879d2f3807828de5345d5da4cac301415d (patch) | |
tree | 1c36764eec116f4e08efaaa9975e37a6d7d70206 | |
parent | 22ee3e6c5ffdc73f231e7125f48827dc1d44237f (diff) |
Fix a calculation error of the position of a floating frame
* exwm-floating.el (exwm-floating--set-floating): The position of a floating frame should be relative to its workspace.
-rw-r--r-- | exwm-floating.el | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/exwm-floating.el b/exwm-floating.el index 924f7cffca9f..0994cb9914cc 100644 --- a/exwm-floating.el +++ b/exwm-floating.el @@ -135,8 +135,8 @@ (setq edges nil))) (if edges ;; Put at the center of leading window - (setq x (/ (- (+ (elt edges 2) (elt edges 0)) width) 2) - y (/ (- (+ (elt edges 3) (elt edges 1)) height) 2)) + (setq x (/ (- (elt edges 2) (elt edges 0) width) 2) + y (/ (- (elt edges 3) (elt edges 1) height) 2)) ;; Put at the center of screen (setq x (/ (- display-width width) 2) y (/ (- display-height height) 2)))))) |