GNU bug report logs - #45177
27.1; Access to invoking top level command in minibuffer

Previous Next

Package: emacs;

Reported by: clemera <at> posteo.net

Date: Fri, 11 Dec 2020 14:21:02 UTC

Severity: normal

Tags: fixed

Found in version 27.1

Fixed in version 28.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 45177 <at> debbugs.gnu.org (full text, mbox):

From: Drew Adams <drew.adams <at> oracle.com>
To: clemera <at> posteo.net, 45177 <at> debbugs.gnu.org
Subject: RE: bug#45177: 27.1; Access to invoking top level command in
 minibuffer
Date: Fri, 11 Dec 2020 09:35:25 -0800 (PST)
> For command based settings it would be nice to be able to have
> access to the top level command from which the current minibuffer
> session was invoked from. This should also work with multiple minibuffer
> invokations during a command. Using `minibuffer-setup-hook' to save
> `real-this-command' does not work, for example with:

FWIW, `icicle-mode' puts this on `pre-command-hook':

(defun icicle-top-level-prep ()
  "Do top-level stuff.  Used in `pre-command-hook'."
  (unless (> (minibuffer-depth) 0)
    ;; ... <other stuff>
    (unless (memq this-command 
                  '(minibuffer-complete-and-exit
                    icicle-minibuffer-complete-and-exit
                    exit-minibuffer
                    icicle-exit-minibuffer))
      (setq icicle-last-top-level-command  this-command))
    ;; ... <other stuff>
    ))

(defvar icicle-last-top-level-command nil
  "Last top-level command used.")




This bug report was last modified 3 years and 330 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.