[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/posframe 0f2d860 2/5: * posframe.el (posframe--fit-fram
From: |
Feng Shu |
Subject: |
[elpa] externals/posframe 0f2d860 2/5: * posframe.el (posframe--fit-frame-to-buffer): use functionp to test fit-frame-to-buffer-1 exist. |
Date: |
Wed, 3 Feb 2021 03:19:36 -0500 (EST) |
branch: externals/posframe
commit 0f2d8603662a3a868bced5f158305e609fbb6081
Author: Feng Shu <tumashu@163.com>
Commit: Feng Shu <tumashu@163.com>
* posframe.el (posframe--fit-frame-to-buffer): use functionp to test
fit-frame-to-buffer-1 exist.
---
posframe.el | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/posframe.el b/posframe.el
index bd50ed5..e55ead4 100644
--- a/posframe.el
+++ b/posframe.el
@@ -722,11 +722,11 @@ will be removed."
(let ((x-gtk-resize-child-frames posframe-gtk-resize-child-frames))
;; More info: Don't skip empty lines when fitting mini frame to buffer
(Bug#44080)
;;
http://git.savannah.gnu.org/cgit/emacs.git/commit/?id=e0de9f3295b4c46cb7198ec0b9634809d7b7a36d
- (if (version< emacs-version "27.2")
- (fit-frame-to-buffer
- posframe height min-height width min-width)
- (fit-frame-to-buffer-1
- posframe height min-height width min-width nil nil nil))))
+ (if (functionp 'fit-frame-to-buffer-1)
+ (fit-frame-to-buffer-1
+ posframe height min-height width min-width nil nil nil)
+ (fit-frame-to-buffer
+ posframe height min-height width min-width))))
(defun posframe--set-frame-size (posframe height min-height width min-width)
"Set POSFRAME's size.