emacs-devel
[Top][All Lists]
Advanced

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

widget-complete and C-g to hide *Completions*


From: Mauro Aranda
Subject: widget-complete and C-g to hide *Completions*
Date: Tue, 12 Jan 2021 21:19:13 -0300

When in some mode like emacs-lisp-mode, after the *Completions* buffer
pops up, typing C-g will hide it (at least in emacs -Q).

But when using widget-complete, which uses completion-in-region instead
of completion-at-point, that doesn't happen.

Test case would be like this:

(defcustom foo "black" "..."
  :group 'emacs
  :type 'color)

Eval and then M-x customize-option RET foo
Move to the color widget and type C-k to erase the value.
Then write something like "bl" and type C-M-i, to get the *Completions*
buffer, with values "black", "blue", at least, hopefully.
Type C-g: Quitting doesn't hide *Completions*, like in other modes
(e.g., emacs-lisp-mode).

I'd like to know why the use of completion-in-region in widget-complete
doesn't turn on completion-in-region-mode, and what would be the steps
to make that happen, but I got lost quickly in the completion code, so
perhaps someone else can take a look.  Is it required that
completion-in-region-mode-predicate is non-nil? That is not documented,
but the code seems to expect that.



reply via email to

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