[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/popper 809ec965d8 097/102: popper: popper-cycle can cyc
From: |
ELPA Syncer |
Subject: |
[elpa] externals/popper 809ec965d8 097/102: popper: popper-cycle can cycle backwards |
Date: |
Fri, 8 Sep 2023 15:58:57 -0400 (EDT) |
branch: externals/popper
commit 809ec965d8f6f74ce408e3a8b5974b43371c1528
Author: Karthik Chikmagalur <karthikchikmagalur@gmail.com>
Commit: Karthik Chikmagalur <karthikchikmagalur@gmail.com>
popper: popper-cycle can cycle backwards
* popper.el (popper-cycle, popper-cycle-backwards,
popper-open-latest): Allow `popper-cycle' to cycle backwards with
a negative prefix arg. Add `popper-cycle-backwards' for backwards
cycling.
---
popper.el | 25 ++++++++++++++++++-------
1 file changed, 18 insertions(+), 7 deletions(-)
diff --git a/popper.el b/popper.el
index 7710340c53..d8bd3e9a6c 100644
--- a/popper.el
+++ b/popper.el
@@ -451,7 +451,7 @@ a popup buffer to open."
nil 'remove 'equal)))
(buf (cdr new-popup)))
(if (not (buffer-live-p buf))
- (popper-open-latest)
+ (popper-open-latest group)
(display-buffer buf)
(with-current-buffer buf
(run-hooks 'popper-open-popup-hook)))
@@ -533,14 +533,16 @@ windows as it can."
(popper--open-all)
(popper-open-latest group)))))
-(defun popper-cycle (&optional default-group)
+(defun popper-cycle (&optional num)
"Cycle visibility of popup windows one at a time.
-With a prefix argument DEFAULT-GROUP, cycle through popups
-belonging to the default group."
- (interactive "P")
+If numeric prefix argument NUM is negative, cycle backwards.
+
+If NUM is 0, cycle through popups belonging to the default
+group."
+ (interactive "p")
(let* ((group (when (and popper-group-function
- (not default-group))
+ (not (equal num 0)))
(funcall popper-group-function))))
(if (null popper-open-popup-alist)
(popper-open-latest group)
@@ -550,9 +552,18 @@ belonging to the default group."
(popper-close-latest)
(let ((bufs (cdr (assoc group popper-buried-popup-alist))))
(setf (alist-get group popper-buried-popup-alist nil nil 'equal)
- (append (cdr bufs) (cons (car bufs) nil))))
+ (if (> num 0)
+ (append (cdr bufs) (cons (car bufs) nil))
+ (append (last bufs) (butlast bufs)))))
(popper-open-latest group)))))
+(defun popper-cycle-backwards (&optional num)
+ "Cycle visibility of popup windows backwards, one at a time.
+
+See `popper-cycle' for NUM and details."
+ (interactive "p")
+ (popper-cycle (- num)))
+
(defun popper-raise-popup (&optional buffer)
"Raise a popup to regular status.
If BUFFER is not specified,raise the current buffer."
- [elpa] externals/popper 918306c2af 066/102: Updated README with popper-echo demo and new vids, (continued)
- [elpa] externals/popper 918306c2af 066/102: Updated README with popper-echo demo and new vids, ELPA Syncer, 2023/09/08
- [elpa] externals/popper 8592573f33 070/102: Fixed popper-echo display when groups are symbols, ELPA Syncer, 2023/09/08
- [elpa] externals/popper 7b02960025 082/102: Revert "Fix pcase clause for native-comp", ELPA Syncer, 2023/09/08
- [elpa] externals/popper 60297066e3 085/102: pcase 'otherwise' clause should be _ not 'T (#28), ELPA Syncer, 2023/09/08
- [elpa] externals/popper 6599c9b5a1 086/102: eliminate all warnings generated during byte-compilation (#33), ELPA Syncer, 2023/09/08
- [elpa] externals/popper 7ea13618c8 087/102: Remove needless quote (#37), ELPA Syncer, 2023/09/08
- [elpa] externals/popper d7560f1835 089/102: Fix for #35: alist argument ignored by default popper display func, ELPA Syncer, 2023/09/08
- [elpa] externals/popper 47bf592c89 081/102: Fix pcase clause for native-comp, ELPA Syncer, 2023/09/08
- [elpa] externals/popper da70c8296a 092/102: popper-echo.el: Tweak popper echo display format, ELPA Syncer, 2023/09/08
- [elpa] externals/popper 76b1a1f1bc 094/102: popper-echo: Tweak popper group display, ELPA Syncer, 2023/09/08
- [elpa] externals/popper 809ec965d8 097/102: popper: popper-cycle can cycle backwards,
ELPA Syncer <=
- [elpa] externals/popper fe4f0b3b8b 100/102: popper.el, README: Release version 0.4.6, ELPA Syncer, 2023/09/08
- [elpa] externals/popper 031e4d093c 102/102: popper: Update defcustom for popper-reference-buffers, ELPA Syncer, 2023/09/08
- [elpa] externals/popper 3406efb1df 088/102: Fix byte-compile warning in popper-echo, ELPA Syncer, 2023/09/08
- [elpa] externals/popper 71bbc5fc10 096/102: popper: Handle atomic window popups, ELPA Syncer, 2023/09/08
- [elpa] externals/popper 793aef4e5f 099/102: popper.el: Documentation changes for ELPA, ELPA Syncer, 2023/09/08
- [elpa] externals/popper ecc01a46b0 101/102: popper: Revert type natnum to integer, ELPA Syncer, 2023/09/08
- [elpa] externals/popper 38811f9c09 014/102: project root integrated into popper-popup-status, ELPA Syncer, 2023/09/08
- [elpa] externals/popper f9fef8192a 084/102: Fix popper-mode-line not respecting nil., ELPA Syncer, 2023/09/08
- [elpa] externals/popper 527a85c491 079/102: Fix setup instructions (non use-package) for popper-echo #21, ELPA Syncer, 2023/09/08
- [elpa] externals/popper e399120223 095/102: popper-echo: Fix string truncation, ELPA Syncer, 2023/09/08