diff options
| author | Jimmy Aguilar Mena | 2022-03-10 11:24:17 +0100 |
|---|---|---|
| committer | Jimmy Aguilar Mena | 2022-03-10 14:37:40 +0100 |
| commit | 6b3c665d2a8070791dff6520652c00c7b44d64bd (patch) | |
| tree | 33ded75bc7884c98b33fe1b6ea4cb995fd7ddf3b /lisp | |
| parent | c6e079ae15002268d90869a43f66d962175e4cdb (diff) | |
| download | emacs-6b3c665d2a8070791dff6520652c00c7b44d64bd.tar.gz emacs-6b3c665d2a8070791dff6520652c00c7b44d64bd.zip | |
completion-auto-help new values.
Added also entries to news and manual
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/minibuffer.el | 29 |
1 files changed, 18 insertions, 11 deletions
diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index 36b8d808417..c6a803cbc44 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el | |||
| @@ -898,7 +898,11 @@ If the value is t the *Completions* buffer is displayed whenever completion | |||
| 898 | is requested but cannot be done. | 898 | is requested but cannot be done. |
| 899 | If the value is `lazy', the *Completions* buffer is only displayed after | 899 | If the value is `lazy', the *Completions* buffer is only displayed after |
| 900 | the second failed attempt to complete." | 900 | the second failed attempt to complete." |
| 901 | :type '(choice (const nil) (const t) (const lazy))) | 901 | :type '(choice (const :tag "Disabled" nil) |
| 902 | (const :tag "Enabled legacy" t) | ||
| 903 | (const :tag "After a second attempt" lazy) | ||
| 904 | (const :tag "Visible update" visible) | ||
| 905 | (const :tag "Always update" always))) | ||
| 902 | 906 | ||
| 903 | (defvar completion-styles-alist | 907 | (defvar completion-styles-alist |
| 904 | '((emacs21 | 908 | '((emacs21 |
| @@ -1343,16 +1347,19 @@ when the buffer's text is already an exact match." | |||
| 1343 | (completion--cache-all-sorted-completions beg end comps) | 1347 | (completion--cache-all-sorted-completions beg end comps) |
| 1344 | (minibuffer-force-complete beg end)) | 1348 | (minibuffer-force-complete beg end)) |
| 1345 | (completed | 1349 | (completed |
| 1346 | ;; We could also decide to refresh the completions, | 1350 | (cond |
| 1347 | ;; if they're displayed (and assuming there are | 1351 | (exact |
| 1348 | ;; completions left). | 1352 | ;; If completion did not put point at end of field, |
| 1349 | (minibuffer-hide-completions) | 1353 | ;; it's a sign that completion is not finished. |
| 1350 | (if exact | 1354 | (minibuffer-hide-completions) |
| 1351 | ;; If completion did not put point at end of field, | 1355 | (completion--done completion |
| 1352 | ;; it's a sign that completion is not finished. | 1356 | (if (< comp-pos (length completion)) |
| 1353 | (completion--done completion | 1357 | 'exact 'unknown))) |
| 1354 | (if (< comp-pos (length completion)) | 1358 | ((pcase completion-auto-help |
| 1355 | 'exact 'unknown)))) | 1359 | ('visible (get-buffer-window "*Completions*" 0)) |
| 1360 | ('always t)) | ||
| 1361 | (minibuffer-completion-help beg end)) | ||
| 1362 | (t (minibuffer-hide-completions)))) | ||
| 1356 | ;; Show the completion table, if requested. | 1363 | ;; Show the completion table, if requested. |
| 1357 | ((not exact) | 1364 | ((not exact) |
| 1358 | (if (pcase completion-auto-help | 1365 | (if (pcase completion-auto-help |