Merge from savannah/emacs-30
19791839cf
; Don't document a complicated default88bc748f52
Fix minibuffer-next-completion in completing-read-multiple737f249aa2
; Document 'completing-read-multiple' in the ELisp manual37f2551460
; * lisp/gnus/nnweb.el (nnweb-type): Doc fix.
This commit is contained in:
commit
fb4daf4aa0
4 changed files with 22 additions and 23 deletions
|
@ -1242,6 +1242,16 @@ different function to completely override the normal behavior of
|
|||
@code{completing-read}.
|
||||
@end defvar
|
||||
|
||||
@findex completing-read-multiple
|
||||
@vindex crm-separator
|
||||
If you need to prompt the user for several strings, like several
|
||||
elements of a list or several parameters (e.g., user, host, and port) of
|
||||
a connection, you can use @code{completing-read-multiple}. It allows
|
||||
typing several strings separated by a separator string (by default, tabs
|
||||
and commas; customize @code{crm-separator} to change that), and provides
|
||||
completion for each individual string the user types. It returns the
|
||||
strings that were read, as a list.
|
||||
|
||||
@node Completion Commands
|
||||
@subsection Minibuffer Commands that Do Completion
|
||||
|
||||
|
|
|
@ -289,12 +289,7 @@ supersede the message in the current buffer.
|
|||
|
||||
@vindex message-ignored-supersedes-headers
|
||||
Headers matching the @code{message-ignored-supersedes-headers} are
|
||||
removed before popping up the new message buffer. The default is@*
|
||||
@samp{^Path:\\|^Date\\|^NNTP-Posting-Host:\\|^Xref:\\|^Lines:\\|@*
|
||||
^Received:\\|^X-From-Line:\\|^X-Trace:\\|^X-Complaints-To:\\|@*
|
||||
Return-Path:\\|^Supersedes:\\|^NNTP-Posting-Date:\\|^X-Trace:\\|@*
|
||||
^X-Complaints-To:\\|^Cancel-Lock:\\|^Cancel-Key:\\|^X-Hashcash:\\|@*
|
||||
^X-Payment:\\|^Approved:}.
|
||||
removed before popping up the new message buffer.
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -251,22 +251,16 @@ with empty strings removed."
|
|||
(setq-local minibuffer-completion-table #'crm--collection-fn)
|
||||
(setq-local minibuffer-completion-predicate predicate)
|
||||
(setq-local completion-list-insert-choice-function
|
||||
(lambda (start end choice)
|
||||
(if (and (stringp start) (stringp end))
|
||||
(let* ((beg (save-excursion
|
||||
(goto-char (minibuffer-prompt-end))
|
||||
(or (search-forward start nil t)
|
||||
(search-forward-regexp crm-separator nil t)
|
||||
(minibuffer-prompt-end))))
|
||||
(end (save-excursion
|
||||
(goto-char (point-max))
|
||||
(or (search-backward end nil t)
|
||||
(progn
|
||||
(goto-char beg)
|
||||
(search-forward-regexp crm-separator nil t))
|
||||
(point-max)))))
|
||||
(completion--replace beg end choice))
|
||||
(completion--replace start end choice))))
|
||||
(lambda (_start _end choice)
|
||||
(let* ((beg (save-excursion
|
||||
(if (search-backward-regexp crm-separator nil t)
|
||||
(1+ (point))
|
||||
(minibuffer-prompt-end))))
|
||||
(end (save-excursion
|
||||
(if (search-forward-regexp crm-separator nil t)
|
||||
(1- (point))
|
||||
(point-max)))))
|
||||
(completion--replace beg end choice))))
|
||||
;; see completing_read in src/minibuf.c
|
||||
(setq-local minibuffer-completion-confirm
|
||||
(unless (eq require-match t) require-match))
|
||||
|
|
|
@ -42,7 +42,7 @@
|
|||
|
||||
(defvoo nnweb-type 'google
|
||||
"What search engine type is being used.
|
||||
Valid types include `google' and `dejanews'.")
|
||||
The only valid type is currently `google'.")
|
||||
|
||||
(defvar nnweb-type-definition
|
||||
'((google
|
||||
|
|
Loading…
Add table
Reference in a new issue