summaryrefslogtreecommitdiff
path: root/lisp/icomplete.el
Commit message (Collapse)AuthorAgeFilesLines
* Quote some literal keys to get help-key-binding faceStefan Kangas2022-07-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/align.el (align): * lisp/bindings.el (undo-repeat-map): * lisp/calc/calc-embed.el (calc-do-embedded): * lisp/calc/calc-prog.el (calc-user-define-invocation): * lisp/calc/calc-yank.el (calc--edit-mode): * lisp/comint.el (comint-history-isearch) * lisp/dired.el (dired-mode): * lisp/emulation/viper.el (viper-mode): * lisp/erc/erc-button.el (erc-button-face): * lisp/erc/erc-track.el (erc-track-enable-keybindings): * lisp/gnus/gnus-art.el (gnus-article-button-face): * lisp/gnus/gnus-eform.el (gnus-edit-form): * lisp/gnus/gnus-sum.el (gnus-summary-stop-at-end-of-message) (gnus-summary-goto-unread): * lisp/icomplete.el (icomplete-show-matches-on-no-input): * lisp/image-mode.el (image-scroll-up): * lisp/international/iso-transl.el (iso-transl-set-language): * lisp/isearch.el (isearch-forward-regexp): * lisp/misc.el (butterfly): * lisp/outline.el (outline-minor-mode-cycle-filter) (outline-minor-mode-cycle): * lisp/progmodes/grep.el (rgrep): * lisp/progmodes/gud.el (gud-gdb-repeat-map, gud-sdb-repeat-map) (gud-dbx-repeat-map, gud-xdb-repeat-map, gud-perldb-repeat-map) (gud-pdb-repeat-map, gud-guiler-repeat-map, gud-jdb-repeat-map): * lisp/progmodes/idlw-shell.el (idlwave-shell-graphics-window-size) (idlwave-shell-mode): * lisp/progmodes/idlwave.el (idlwave-shell-debug-modifiers) (idlwave-list-shell-load-path-shadows): * lisp/progmodes/python.el (python-shell-get-process-or-error): * lisp/repeat.el (repeat-check-key): * lisp/replace.el (query-replace, query-replace-regexp) (read-regexp): * lisp/simple.el (read-extended-command-predicate): * lisp/tab-bar.el (tab-bar-switch-repeat-map) (tab-bar-move-repeat-map): * lisp/term.el (ansi-term): * lisp/textmodes/reftex-index.el (reftex-index-phrases-set-macro-key): * lisp/vc/emerge.el (emerge-scroll-left, emerge-scroll-right): * lisp/windmove.el: * lisp/winner.el (winner-mode): Quote literal keys to get 'help-key-binding' face. * lisp/comint.el (comint-insert-previous-argument): Use regular quotes.
* Merge from origin/emacs-28Stefan Kangas2022-06-241-1/+1
|\ | | | | | | | | | | | | a772c0b852 ; Fix typos: prefer US spelling. # Conflicts: # doc/misc/modus-themes.org
| * ; Fix typos: prefer US spelling.Stefan Kangas2022-06-231-1/+1
| |
* | * lisp/icomplete.el: Consider a list in minibuffer-default (bug#55800)Juri Linkov2022-06-121-3/+8
| | | | | | | | | | * lisp/icomplete.el (icomplete--sorted-completions): Handle a string value in the first element of the list of default values in minibuffer-default.
* | icomplete-in-buffer doc fixLars Ingebrigtsen2022-06-081-1/+1
| | | | | | | | | | * lisp/icomplete.el (icomplete-in-buffer): dabbrev now uses icomplete-in-buffer (bug#45764).
* | Make the icomplete-in-buffer doc string document moreLars Ingebrigtsen2022-05-071-1/+3
| | | | | | | | | | * lisp/icomplete.el (icomplete-in-buffer): Note what this variable does and doesn't do (bug#45768).
* | (icomplete-exhibit): Fix use in-bufferStefan Monnier2022-05-061-31/+30
| | | | | | | | | | | | | | Also prefer #' to quote function names and remove redundant :group args. * lisp/icomplete.el (icomplete-exhibit): Don't presume the completion field ends at `point-max`.
* | Merge from origin/emacs-28Eli Zaretskii2022-01-011-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 836be7a112 ; * etc/refcards/ru-refcard.tex: Update Copyright year. 86cbc6ee4a * lisp/net/tramp-sh.el: Adapt copyright year ebe8772f65 ; Minor fixes related to copyright years 23c1ee6989 ; * test/manual/etags/ETAGS.good_N: Adjust to copyright ye... 8d3fc7ec89 * src/xfaces.c (face_for_font): Make 'hash' be uintptr_t. 19dcb237b5 ; Add 2022 to copyright years. # Conflicts: # etc/NEWS # etc/refcards/ru-refcard.tex # lib/cdefs.h # lisp/erc/erc-dcc.el # lisp/erc/erc-imenu.el # lisp/erc/erc-replace.el # lisp/image-dired.el # lisp/progmodes/xref.el # m4/alloca.m4 # m4/byteswap.m4 # m4/errno_h.m4 # m4/getopt.m4 # m4/gnulib-common.m4 # m4/inttypes.m4 # m4/stddef_h.m4 # m4/stdint.m4 # m4/sys_socket_h.m4
| * ; Add 2022 to copyright years.Eli Zaretskii2022-01-011-1/+1
| |
* | lisp/icomplete.el (icomplete-fido-backward-updir): Expand "~/"Rasmus2021-11-121-7/+11
| | | | | | | | | | * lisp/icomplete.el (icomplete-fido-backward-updir): Expand "~/" (bug#43925).
* | * lisp/icomplete.el (icomplete-exhibit): Remove workaroundAaron Jensen2021-10-311-5/+0
|/
* ; Minor stylistic fixes found by checkdocStefan Kangas2021-09-161-1/+1
|
* Double check completions-group customization variable in IcompleteJoão Távora2021-08-221-1/+2
| | | | | | bug#48545 * lisp/icomplete.el (icomplete--augment): Double check completions-group.
* Make icomplete-forward-completions O(1) when icomplete-scroll is tJoão Távora2021-08-191-3/+3
| | | | | | | | | In particular, this makes the recently added icomplete-vertical-goto-last (bug#49005) be O(n) instead of O(n^2). That used to be almost unbearably slow for large n. * lisp/icomplete.el (icomplete-forward-completions): don't call last unless needed.
* Minor doc fixes in icomplete.elEli Zaretskii2021-08-191-2/+3
| | | | | * lisp/icomplete.el (icomplete-section): Add :version. (icomplete--augment): Doc fix.
* ; Correct :version tag of icomplete-selected-match faceJoão Távora2021-08-191-1/+1
| | | | * lisp/icomplete.el (icomplete-selected-match): Fix :version
* Section by 'group-function' in Icomplete and Fido's vertical modesJoão Távora2021-08-191-55/+94
| | | | | | | | | Fixes: bug#48545 * lisp/icomplete.el (icomplete--augment): Rewrite from icomplete--affixate. (icomplete--render-vertical): Rework. (icomplete--vertical-minibuffer-setup): Separator is hardcoded "\n", no need to set.
* Bind <up> and <down> in icomplete-vertical-modeJoão Távora2021-08-171-0/+2
| | | | | | | Suggested by Ergus <spacibba@aol.com> * lisp/icomplete.el (icomplete-vertical-mode-minibuffer-map): Bind <up> and <down>
* Jump to first,last completion with M-<, M-> in icomplete-vertical-modeJoão Távora2021-08-171-12/+29
| | | | | | | | | | | | Fixes: bug#49005 Co-authored-by: Simon Lang <simon.lang@outlook.com> * lisp/icomplete.el (icomplete-backward-completions): Return non-nil iff something was stepped. Ajust docstring. (icomplete-forward-completions): Adjust docstring. (icomplete-vertical-goto-first, icomplete-vertical-goto-last): New commands. (icomplete-vertical-mode-minibuffer-map): Bind new commands to M-< and M->.
* Make icomplete-vertical-mode take immediate effect (bug#49075)João Távora2021-08-161-1/+14
| | | | | | | | * etc/NEWS: Mention change. * lisp/icomplete.el (icomplete-vertical-mode): (fido-vertical-mode): Tweak docstring. Turn on icomplete-mode. and fido-mdoe
* Fix bug#50063 when using icomplete-fido-kill with C-x p pJoão Távora2021-08-151-4/+7
| | | | | | | | | C-x p p utilizes a completion table "category" which is 'project-file' icomplete-fido-kill only functioned for 'buffer' and 'file', and failed with a non-informative message when something else was used. * lisp/icomplete.el (icomplete-fido-kill): Support 'project-file' class. Use cl-case, instead of pcase.
* Use 'remember-buffer' in remember.el doc strings.Gabriel do Nascimento Ribeiro2021-07-191-6/+12
| | | | | | | | | * lisp/textmodes/remember.el (remember-initial-contents) (remember-before-remember-hook, remember-destroy): Refer to `remember-buffer'. * lisp/textmodes/remember.el (remember-buffer): Make into defcustom (bug#49373).
* Speed up fido-modeDmitry Gutov2021-07-041-6/+9
| | | | * lisp/icomplete.el (icomplete-completions): Speed up fido-mode (bug#48841).
* In files that use allout use it for all headingsJonas Bernoulli2021-06-301-4/+4
| | | | | | | * lisp/allout.el: Don't prefix regular comments with three semicolons. * lisp/icomplete.el: Use allout syntax for all headings. * lisp/net/eudc.el: Use allout syntax for all headings.
* Consider environment vars in Fido's directory-aware RET bindingJoão Távora2021-06-051-1/+2
| | | | | | | Fixes: bug#48782 * lisp/icomplete.el (icomplete-fido-ret): Consider environment variables in dir expansion.
* Make icomplete less blinky and more responsiveDmitry Gutov2021-06-051-16/+2
| | | | | | | | * lisp/icomplete.el (icomplete-pre-command-hook, icomplete-tidy): Remove, update the callers (https://lists.gnu.org/archive/html/emacs-devel/2021-06/msg00111.html). (icomplete-compute-delay): Change the default to 150ms. (icomplete-max-delay-chars): Change the default to 2.
* Add annotation capability to icomplete-vertical-modeJoão Távora2021-06-011-10/+51
| | | | | | | | Co-authored-by Daniel Mendler <mail@daniel-mendler.de> * lisp/icomplete.el (icomplete--affixate): New helper. (icomplete--render-vertical): Use it. Rework. (icomplete-completions): Pass md to icomplete--render-vertical.
* Improve icomplete-vertical-mode and fido-vertical-modeJoão Távora2021-06-011-124/+238
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This mode is intended to be used with Icomplete ('M-x icomplete-mode') or Fido ('M-x fido-mode'), to display the list of completions candidates vertically instead of horizontally. When used with Icomplete, completions are rotated and selection kept at the top. When used with Fido, completions scroll like a typical dropdown widget. If the dropdown behaviour is desired for Icomplete (instead of rotation), icomplete-scroll can be adjusted separately by the user. * etc/NEWS (icomplete-vertical-mode): Reword. * lisp/icomplete.el (simple): Require it. (icomplete-selected-match): New face. (icomplete-scroll): New user-visible var. (icomplete-forward-completions): Rework. (icomplete-backward-completions): Rework. (icomplete--fido-mode-setup): Prefer icomplete-scroll according to icomplete-vertical mode. (icomplete-minibuffer-setup): Initialize icomplete--scrolled-completions. (fido-vertical-mode): An alias for icomplete-vertical-mode. (icomplete-exhibit): Init icomplete--scrolled-past. Adjust overlay. (icomplete--render-vertical): New helper. (icomplete--sorted-completions): If cache is stale, also invalidate icomplete--scrolled-past. (icomplete-completions): Rework. Mostly reformat. * lisp/simple.el (max-mini-window-lines): New helper. (display-message-or-buffer): Use it.
* ; Remove some useless commentsStefan Kangas2021-04-161-1/+0
|
* Add new icomplete-vertical-modeGregory Heytings2021-04-101-4/+38
| | | | | | | | | | | | | Co-authored-by: João Távora <joaotavora@gmail.com> * lisp/icomplete.el (icomplete-completions): Consider icomplete-vertical-mode. (icomplete-vertical-mode-minibuffer-map): New map. (icomplete--vertical-minibuffer-setup): New helper. (icomplete-vertical-mode): New minor mode. * doc/emacs/buffers.texi (Icomplete): Mention icomplete-vertical-mode. * etc/NEWS: Mention icomplete-vertical-mode
* Update copyright year to 2021Paul Eggert2021-01-011-1/+1
| | | | Run "TZ=UTC0 admin/update-copyright".
* Don't show matches with no input for nil icomplete-show-matches-on-no-inputJuri Linkov2020-12-141-6/+14
| | | | | | | | | | | | | * lisp/icomplete.el (icomplete-show-matches-on-no-input): Fix docstring. (icomplete--initial-input): New internal variable. (icomplete-minibuffer-setup): Set buffer-local icomplete--initial-input to icomplete--field-string. (icomplete-ret, icomplete-force-complete-and-exit) (icomplete--sorted-completions, icomplete-exhibit): Compare icomplete--initial-input with icomplete--field-string to detect no input. (Bug#19031) etc/NEWS: Remove duplicate entry.
* Prefer setq-local in most filesStefan Kangas2020-12-091-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/apropos.el (apropos-print): * lisp/buff-menu.el (Buffer-menu-mode): * lisp/calc/calc.el (calc-trail-buffer): * lisp/chistory.el (command-history-mode): * lisp/dabbrev.el: * lisp/dframe.el (dframe-frame-mode): * lisp/doc-view.el (doc-view-presentation-mode): * lisp/ebuff-menu.el (electric-buffer-menu-mode) (electric-buffer-update-highlight): * lisp/edmacro.el (edit-kbd-macro): * lisp/face-remap.el (buffer-face-set, buffer-face-toggle): * lisp/files.el: (find-file-noselect-1, hack-local-variables-confirm) (set-visited-file-name, revert-buffer--default): * lisp/filesets.el (filesets-spawn-external-viewer): * lisp/find-dired.el (find-dired): * lisp/find-lisp.el (find-lisp-find-dired-internal): * lisp/finder.el (finder-mode): * lisp/font-core.el (font-lock-default-function): * lisp/format.el (format-annotate-function): * lisp/help-fns.el (describe-variable): * lisp/help-mode.el (help-mode): * lisp/icomplete.el (icomplete-minibuffer-setup) (icomplete--in-region-setup): * lisp/ido.el (ido-completion-help, ido-tidy): * lisp/international/robin.el (robin-activate): * lisp/leim/quail/hangul.el (hangul-input-method-activate): * lisp/leim/quail/uni-input.el (ucs-input-activate): * lisp/man.el (Man-mode): * lisp/master.el (master-set-slave): * lisp/minibuffer.el (minibuffer-completion-help) (read-file-name-default): * lisp/outline.el (outline-minor-mode): * lisp/pcomplete.el (pcomplete-comint-setup): * lisp/proced.el (proced-mode): * lisp/recentf.el (recentf-edit-list, recentf-open-files-items): * lisp/replace.el (occur-1): * lisp/reveal.el (reveal-mode): * lisp/ruler-mode.el (ruler--save-header-line-format): * lisp/scroll-lock.el (scroll-lock-mode): * lisp/startup.el (normal-top-level, normal-splash-screen): * lisp/strokes.el (strokes-list-strokes): * lisp/thumbs.el (thumbs-insert-image, thumbs-show-thumbs-list): * lisp/tree-widget.el (tree-widget-set-theme): * lisp/window.el (read-buffer-to-switch): * lisp/xwidget.el (xwidget-webkit-begin-edit-textarea): Prefer setq-local.
* Clarify icomplete-show-matches-on-no-input doc stringLars Ingebrigtsen2020-12-071-1/+1
| | | | | * lisp/icomplete.el (icomplete-show-matches-on-no-input): Clarify doc string (bug#19031), suggested by Andrii Kolomoiets.
* Revert "Clarify icomplete-show-matches-on-no-input doc string"Lars Ingebrigtsen2020-12-071-6/+1
| | | | | | This reverts commit f352c57972d24464a42ea3e65dc8ac07d8e0517c. The new explanation of what icomplete does is wrong.
* Clarify icomplete-show-matches-on-no-input doc stringLars Ingebrigtsen2020-12-041-1/+6
| | | | | * lisp/icomplete.el (icomplete-show-matches-on-no-input): Clarify the meaning of the variable (bug#19031).
* Fix up fix for bug#19032João Távora2020-09-091-1/+1
| | | | | * lisp/icomplete.el (icomplete-ret): Call minibuffer-icomplete-and-exit, not minibuffer-exit.
* Change icomplete-show-matches-on-no-input behaviour for Icomplete onlyJoão Távora2020-09-081-1/+15
| | | | | | | | | | | | | | Fixes: bug#19032, bug#43120 Previous fixes to bug#19032 introduced bugs in Fido mode. This fix relies on a new command bound to RET. * etc/NEWS (Miscellaneous): Mention icomplete-show-matches-on-no-input. * lisp/icomplete.el (icomplete-show-matches-on-no-input): Add comment. (icomplete-minibuffer-map): Rebind minibuffer-complete-and-exit to icomplete-ret. (icomplete-ret): New command.
* Revert two commits for bug#19032João Távora2020-09-081-9/+2
| | | | | | | | | | | | This reverts: - commit 585fe00557489e49188b6a301f001ef01ff15dcb, which is titled "Fix up previous icomplete-show-matches-on-no-input change" - commit 1b8d369c381b5a63e40529d0d95dfa75d94b8e09, which is titled "Change icomplete-show-matches-on-no-input behavior". A simpler, less intrusive fix follows shortly after this commit.
* Better explain behaviour of icomplete--sorted-completionsJoão Távora2020-09-071-16/+53
| | | | * lisp/icomplete.el (icomplete--sorted-completions): Overhaul comment
* Don't resort Icomplete candidates when default already on topJoão Távora2020-09-061-8/+13
| | | | | | | | | | | | | | Fixes: bug#43222 Icomplete mode re-sorts candidates, bubbling the default to top if it's found somewhere down the list. This is done according to two criteria: exact match and prefix match. Before this fix, it didn't take into account the possibility that the exact match for the default would already be on top, and would incorrectly bubble a prefixing completion down the list to the top. This commit fixes that. * lisp/icomplete.el (icomplete--sorted-completions): Rework. Recomment.
* Fix up previous icomplete-show-matches-on-no-input changeLars Ingebrigtsen2020-09-051-1/+1
| | | | | * lisp/icomplete.el (icomplete-completions): Ensure that the default value is cleared (bug#43120).
* Change icomplete-show-matches-on-no-input behaviorLars Ingebrigtsen2020-08-141-2/+9
| | | | | | | | | | * lisp/icomplete.el (icomplete-show-matches-on-no-input): Doc fix. (icomplete-completions): Set completion-content-when-empty. * lisp/minibuffer.el (completion-content-when-empty): New variable. (completion--complete-and-exit): Use it (bug#19032). Based on a patch by Matthew Leach <matthew@mattleach.net>.
* Delete, don't kill, dir dir fragments in icomplete-fido-backward-updirJoão Távora2020-06-131-1/+4
| | | | | | | Reported by: Andrew Schwartzmeyer <andrew@schwartzmeyer.com> * lisp/icomplete.el (icomplete-fido-backward-updir): Don't save dir fragments to kill ring.
* Have Fido mode also imitate Ido mode in ignore-case optionsJoão Távora2020-06-051-1/+4
| | | | | | | Suggested by Sean Whitton <spwhitton@spwhitton.name>. * lisp/icomplete.el (icomplete--fido-mode-setup): Set ignore-case options.
* Correct Fido-mode's backspacing of directories with spacesJoão Távora2020-04-161-1/+1
| | | | | | | Fixes: bug#40625 * lisp/icomplete.el (icomplete-fido-backward-updir): Use zap-up-to-char.
* Default completion-flex-nospace to nilJoão Távora2020-04-151-0/+1
| | | | | | | | | | | By default, the flex completion style _does_ match spaces. Fixes: bug#40625 * lisp/icomplete.el (icomplete--fido-mode-setup): Force completion-flex-nospace to nil. * lisp/minibuffer.el (completion-flex-nospace): Default to nil.
* Let fido-mode users force a minibuffer-exitJoão Távora2020-03-071-4/+8
| | | | | * lisp/icomplete.el (icomplete-fido-exit): Add FORCE arg. Rewrite docstring. (bug#38992)
* icomplete-fido-exit: New command for the M-j bindingDmitry Gutov2020-03-071-1/+8
| | | | | * lisp/icomplete.el (icomplete-fido-exit): New command. (icomplete-fido-mode-map): Use it (bug#38992).
* minibuffer-force-complete-and-exit: Allow input with no matchesDmitry Gutov2020-03-071-1/+1
| | | | | | | | | | * lisp/minibuffer.el (minibuffer--require-match): New variable. (completing-read-default): Bind it to the REQUIRE-MATCH value. (minibuffer-force-complete-and-exit): Consult it to allow input with no matches when a match is not required (bug#38992). * lisp/icomplete.el (icomplete-exhibit): Use it to render the correct parens around matches.