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

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

[elpa] externals/posframe e2d9880 1/3: * posframe.el (posframe-show): le


From: ELPA Syncer
Subject: [elpa] externals/posframe e2d9880 1/3: * posframe.el (posframe-show): let :width/height <= parent frame width/height.
Date: Wed, 3 Nov 2021 01:57:38 -0400 (EDT)

branch: externals/posframe
commit e2d9880968600a24f3a7bf33c451d20032df03c0
Author: Feng Shu <tumashu@163.com>
Commit: Feng Shu <tumashu@163.com>

    * posframe.el (posframe-show): let :width/height <= parent frame 
width/height.
---
 posframe.el | 18 ++++++++++--------
 1 file changed, 10 insertions(+), 8 deletions(-)

diff --git a/posframe.el b/posframe.el
index 016785b..5e93aae 100644
--- a/posframe.el
+++ b/posframe.el
@@ -542,15 +542,17 @@ You can use `posframe-delete-all' to delete all 
posframes."
          (min-width (or min-width 1))
          (min-height (or min-height 1))
          (width (when width
-                  (max min-width
-                       (if (numberp max-width)
-                           (min width max-width)
-                         width))))
+                  (min (max min-width
+                            (if (numberp max-width)
+                                (min width max-width)
+                              width))
+                       (frame-width))))
          (height (when height
-                   (max min-height
-                        (if (numberp max-height)
-                            (min height max-height)
-                          height))))
+                   (min (max min-height
+                             (if (numberp max-height)
+                                 (min height max-height (frame-height))
+                               height))
+                        (frame-height))))
          (x-pixel-offset (or x-pixel-offset 0))
          (y-pixel-offset (or y-pixel-offset 0))
          ;;-----------------------------------------------------



reply via email to

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