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

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

[elpa] externals/ivy-posframe 6d697ff 190/195: Try to fix: Posframe max-


From: Feng Shu
Subject: [elpa] externals/ivy-posframe 6d697ff 190/195: Try to fix: Posframe max-width? #82
Date: Sat, 3 Oct 2020 07:12:11 -0400 (EDT)

branch: externals/ivy-posframe
commit 6d697ff00ac406b919eba8665b1bc18a2b423cda
Author: feng <feng@debian>
Commit: feng <feng@debian>

    Try to fix: Posframe max-width? #82
---
 ivy-posframe.el | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/ivy-posframe.el b/ivy-posframe.el
index b77a05d..419c8d0 100644
--- a/ivy-posframe.el
+++ b/ivy-posframe.el
@@ -278,8 +278,12 @@ This variable is useful for `ivy-posframe-read-action' .")
   (list
    :height ivy-posframe-height
    :width ivy-posframe-width
-   :min-height (or ivy-posframe-min-height (+ ivy-height 1))
-   :min-width (or ivy-posframe-min-width (round (* (frame-width) 0.62)))))
+   :min-height (or ivy-posframe-min-height
+                   (let ((height (+ ivy-height 1)))
+                     (min height (or ivy-posframe-height height))))
+   :min-width (or ivy-posframe-min-width
+                  (let ((width (round (* (frame-width) 0.62))))
+                    (min width (or ivy-posframe-width width))))))
 
 (defun ivy-posframe-display (str)
   "Display STR via `posframe' by `ivy-posframe-style'."



reply via email to

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