1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-07 23:10:28 -08:00
Commit graph

296 commits

Author SHA1 Message Date
Glenn Morris
73b0cd5003 Convert consecutive FSF copyright years to ranges. 2011-01-24 20:08:28 -08:00
Glenn Morris
0d9f702fd0 Nuke arch-tags. 2011-01-15 15:16:57 -08:00
Stefan Monnier
77ab81d054 Merge from emacs-23 2011-01-14 12:18:41 -05:00
Glenn Morris
5df4f04cd3 Add 2011 to FSF/AIST copyright years. 2011-01-02 15:50:46 -08:00
Stefan Monnier
67027b4979 * lisp/bindings.el (complete-symbol): Move back from minibuffer.el.
* lisp/minibuffer.el (completion-at-point): Remove the `arg'.
2010-12-06 16:06:02 -05:00
Stefan Monnier
b7e270a2c4 * lisp/minibuffer.el (completion-fail-discreetly): New var.
(completion--do-completion): Use it.
2010-11-17 21:44:44 -05:00
Stefan Monnier
d607b96bc2 Merge from emacs-23 2010-11-09 15:07:10 -05:00
Stefan Monnier
9bdba5f56b * lisp/minibuffer.el (minibuffer-completion-help): Specify the end of the
completion field.

Fixes: debbugs:7211
2010-11-08 15:53:42 -05:00
Stefan Monnier
6175cd0824 * lisp/minibuffer.el (completion-cycling): New var.
(minibuffer-complete, completion--do-completion):
Use completion--flush-all-sorted-completions.
(minibuffer-complete): Only cycle if completion-cycling is set.
(completion--flush-all-sorted-completions): Unset completion-cycling.
(minibuffer-force-complete): Set completion-cycling.
(completion-all-sorted-completions): Move declaration before first use.

Fixes: debbugs:7266
2010-10-27 22:22:29 -04:00
Juanma Barranquero
ca3fa30248 Merge changes from emacs-23 branch. 2010-10-19 13:44:07 +02:00
Stefan Monnier
8348910a63 * lisp/minibuffer.el (completion--replace): Move point where it belongs
when there's a common suffix.

Fixes: debbugs:7215
2010-10-17 13:30:22 -04:00
Juanma Barranquero
4628bef1ee Merge changes from emacs-23 branch. 2010-10-08 12:14:47 +02:00
Chong Yidong
397ae22618 Use lexical-let to avoid false matches in var completion (Bug#7056).
* lisp/minibuffer.el (completion--some, completion--do-completion)
(minibuffer-complete-and-exit, minibuffer-completion-help)
(completion-basic-try-completion)
(completion-basic-all-completions)
(completion-pcm--find-all-completions): Use lexical-let to
avoid some false matches in variable completion (Bug#7056)
2010-10-03 15:50:14 -04:00
Stefan Monnier
55586d2a88 * lisp/minibuffer.el (completion--replace): Better preserve markers.
Fixes: debbugs:7138
2010-10-01 01:05:26 +02:00
Chong Yidong
bd78fa1d54 Add "Package:" file headers to denote built-in packages. 2010-08-29 12:17:13 -04:00
Juri Linkov
8f3b8a5f42 * lisp/minibuffer.el (completions-format): Change default from nil to
`horizontal'.  Remove `nil' value from :type.  Doc fix.  (Bug#6459)
2010-06-25 00:51:14 +03:00
Stefan Monnier
5feec8cac1 * lisp/minibuffer.el (completion-file-name-table): Don't return a boundary
past the end of `string'.
(completion--file-name-table): Delegate to completion-file-name-table
for the `boundaries' case.

Fixes: debbugs:6299
2010-05-30 10:17:31 -04:00
Stefan Monnier
902a6d8d73 Allow the default completion to cycle.
* minibuffer.el (completion-cycle-threshold): New custom var.
(completion--do-completion): Use it.
(minibuffer-complete): Use cycling if appropriate.
2010-05-11 20:39:46 -04:00
Stefan Monnier
8a67c70efb * minibuffer.el (completion-pcm--pattern->regex): Fix last change.
Fixes: debbugs:6160
2010-05-11 09:24:49 -04:00
Stefan Monnier
79ccd68f68 * minibuffer.el (completion-pcm-complete-word-inserts-delimiters):
New custom variable.
(completion-pcm--string->pattern): Use it.
(completion-pcm--pattern->regex, completion-pcm--pattern->string):
Make it handle any symbol as `any'.
(completion-pcm--merge-completions): Extract common suffix for the new
`prefix' symbol as well.
(completion-substring--all-completions): Use the new `prefix' symbol.
2010-05-09 18:39:36 -04:00
Stefan Monnier
0235128c15 Merge from emacs-23 2010-05-08 14:47:07 -04:00
Stefan Monnier
f3ee9200b8 * files.el (auto-save-mode): Move to simple.el to fix bootstrap.
* simple.el (auto-save-mode): Move from files.el.
* minibuffer.el (completion--common-suffix): Fix copy&paste error.
2010-05-07 08:49:14 -04:00
Juanma Barranquero
03ffa46daa * minibuffer.el: Revert previous change. 2010-05-07 05:11:56 +02:00
Juanma Barranquero
cae7fcf92d * minibuffer.el (comps): Declare for byte-compiler. 2010-05-07 02:50:26 +02:00
Stefan Monnier
1493963bb1 Extract common suffix for * in partial-completion.
* minibuffer.el (completion--sreverse, completion--common-suffix):
New functions.
(completion-pcm--merge-completions): Extract common suffix when safe.
2010-05-05 22:59:07 -04:00
Stefan Monnier
8c0bf8b395 * minibuffer.el (tags-completion-at-point-function): Move to etags.el.
* progmodes/etags.el (tags-completion-at-point-function):
Remove left over interactive spec.  Add autoloading stub.
(complete-tag): Use tags-completion-at-point-function.
2010-04-30 21:08:43 -04:00
Chong Yidong
27601456d7 * minibuffer.el (tags-completion-at-point-function): Fix return value. 2010-04-30 19:13:22 -04:00
Chong Yidong
3a07ffce2f * minibuffer.el (tags-completion-at-point-function): New function.
(completion-at-point-functions): Use it.

* cedet/semantic.el (semantic-completion-at-point-function): New function.
(semantic-mode): Use semantic-completion-at-point-function for
completion-at-point-functions instead.

* progmodes/etags.el (complete-tag): Revert last change.
2010-04-29 11:32:11 -04:00
Chong Yidong
48111a8571 Unify complete-symbol with completion-at-point.
* bindings.el (complete-symbol): Move into minibuffer.el.

* minibuffer.el (complete-tag): Move from etags.el.  If tags
completion cannot be performed, return nil instead of signalling
an error.
(completion-at-point): Make it an alias for complete-symbol.
(complete-symbol): Move from bindings.el, and replace with the
body of completion-at-point.

* progmodes/etags.el (complete-tag): Move to minibuffer.el.

* cedet/semantic.el (semantic-mode): When enabled, add
semantic-ia-complete-symbol to completion-at-point-functions.

* cedet/semantic/ia.el (semantic-ia-complete-symbol): Return nil
if Semantic is not active.
2010-04-28 15:04:16 -04:00
Glenn Morris
d2c7b91706 * minibuffer.el (completion-at-point): Doc fix. 2010-04-20 00:37:20 -07:00
Stefan Monnier
56d365a93d (completion-styles-alist): Fix up last merge and document `substring'. 2010-04-19 14:33:11 -04:00
Stefan Monnier
6e104790e7 Merge from emacs-23 2010-04-19 11:07:52 -04:00
Stefan Monnier
79d74ac527 (completion-styles): Improve docstrings. 2010-04-19 09:17:40 -04:00
Michael Albinus
5f2b693f18 Fix Bug#5840.
* ido.el (ido-file-name-all-completions-1):
* minibuffer.el (minibuffer-completion-help):
* net/tramp.el (tramp-completion-mode-p): Use `non-essential'.
2010-04-15 00:05:14 +02:00
Stefan Monnier
e867cb5d30 Merge from `emacs-23'. 2010-03-24 14:02:56 -04:00
Stefan Monnier
002787475f Add a new completion style `substring'.
* minibuffer.el (completion-basic--pattern): New function.
(completion-basic-try-completion, completion-basic-all-completions): Use it.
(completion-substring--all-completions)
(completion-substring-try-completion)
(completion-substring-all-completions): New functions.
(completion-styles-alist): New style `substring'.
2010-03-22 20:59:49 -04:00
Juanma Barranquero
c8de140b34 Fix typos in docstrings.
* image-dired.el (image-dired-display-thumbs): Fix typo in docstring.
  (image-dired-read-comment): Doc fix.

* json.el (json-object-type, json-array-type, json-key-type, json-false)
  (json-null, json-read-number):
* minibuffer.el (completion-in-region-functions):
* calendar/cal-tex.el (cal-tex-daily-end, cal-tex-number-weeks)
  (cal-tex-cursor-week):
* emacs-lisp/trace.el (trace-function):
* eshell/em-basic.el (eshell/printnl):
* eshell/em-dirs.el (eshell-last-dir-ring, eshell-parse-drive-letter)
  (eshell-read-last-dir-ring, eshell-write-last-dir-ring):
* obsolete/levents.el (allocate-event, event-key, event-object)
  (event-point, event-process, event-timestamp, event-to-character)
  (event-window, event-x, event-x-pixel, event-y, event-y-pixel):
* textmodes/reftex-vars.el (reftex-index-macros-builtin)
  (reftex-section-levels, reftex-auto-recenter-toc, reftex-toc-mode-hook)
  (reftex-cite-punctuation, reftex-search-unrecursed-path-first)
  (reftex-highlight-selection): Fix typos in docstrings.
2010-03-22 17:50:29 +01:00
Juanma Barranquero
d120008778 * lisp/minibuffer.el (completion-in-region-functions): Fix docstring typos. 2010-03-19 14:22:15 +01:00
Stefan Monnier
c53b9c3b0a Fix in-buffer completion when after-change-functions modify the buffer.
* minibuffer.el (completion--replace): New function.
(completion--do-completion): Use it and use relative movement.
2010-02-27 16:21:43 -05:00
Stefan Monnier
51b23c4486 Make `initials' completion work for /hh -> /home/horn again (bug#5524).
* minibuffer.el (completion-initials-expand): Only check the presence
of delims *within* the boundaries, since otherwise the / delim is
always found for files.
2010-02-04 23:21:11 -05:00
Glenn Morris
114f9c9679 Add 2010 to copyright years. 2010-01-13 00:35:10 -08:00
Stefan Monnier
1d4adede54 (minibuffer-local-must-match-filename-map): Re-instate the varalias that was
accidentally removed by the 2009-11-19 change (bug#5186).
2009-12-12 05:23:54 +00:00
Stefan Monnier
51ef56c47f * minibuffer.el (completion-at-point-functions): New var.
(completion-at-point): New command.
* indent.el (indent-for-tab-command): Handle the new `complete' behavior.
* progmodes/python.el (python-mode-map): Use completion-at-point.
(python-completion-at-point): Rename from python-partial-symbol and
adjust for use in completion-at-point-functions.
(python-mode): Setup completion-at-point for Python completion.
* emacs-lisp/lisp.el (lisp-completion-at-point): New function
extracted from lisp-complete-symbol.
(lisp-complete-symbol): Use it.
* emacs-lisp/lisp-mode.el (emacs-lisp-mode): Use define-derived-mode,
setup completion-at-point for Elisp completion.
(emacs-lisp-mode-map, lisp-interaction-mode-map): Use completion-at-point.
* ielm.el (ielm-map): Use completion-at-point.
(inferior-emacs-lisp-mode): Setup completion-at-point for Elisp completion.
* progmodes/sym-comp.el: Move to...
* obsolete/sym-comp.el: Move from progmodes.
2009-12-07 20:06:26 +00:00
Stefan Monnier
365b9a6296 (minibuffer-complete-and-exit): Don't replace the
minibuffer's content with itself.
Fold the confirm-after-completion case into the `confirm' case.
(completion-pcm-word-delimiters): Add : and / to the delimiters.
2009-12-06 01:25:41 +00:00
Stefan Monnier
3e38b2bd42 (completion-in-region): Improve docstring. 2009-12-06 00:58:40 +00:00
Stefan Monnier
25b5462738 (completion-pcm--merge-try): Also consider placing point after a star, if
that's the only place where modifications can make progress.
2009-12-05 01:22:54 +00:00
Juri Linkov
7d371eac64 Provide additional default values (file name at point or at the
current Dired line) via M-n for file reading minibuffers.  (Bug#5010)

* minibuffer.el (read-file-name-defaults): New function.
(read-file-name): Reset `minibuffer-default' to nil when
it duplicates initial input `insdef'.
Bind `minibuffer-default-add-function' to lambda that
calls `read-file-name-defaults' in `minibuffer-selected-window'.
(minibuffer-insert-file-name-at-point): New command.

* files.el (file-name-at-point-functions): New defcustom.
(find-file-default): Remove defvar.
(find-file-read-args): Don't use `find-file-default'.
Move `minibuffer-with-setup-hook' that sets `minibuffer-default'
to `read-file-name'.
(find-file-literally): Use `read-file-name' with
`confirm-nonexistent-file-or-buffer'.

* ffap.el (ffap-guess-file-name-at-point): New autoloaded function.

* dired.el (dired-read-dir-and-switches):
Move `minibuffer-with-setup-hook' that sets `minibuffer-default'
to `read-file-name'.
(dired-file-name-at-point): New function.
(dired-mode): Add hook `dired-file-name-at-point' to
`file-name-at-point-functions'.
2009-11-25 17:11:29 +00:00
Stefan Monnier
d2c9fc4231 * window.el (display-buffer-mark-dedicated): New var.
(display-buffer): Obey it.
* minibuffer.el (minibuffer-completion-help): Use it.
2009-11-19 22:05:40 +00:00
Juri Linkov
3a9f97fa98 (completions-format): New defcustom.
(completion--insert-strings): Implement vertical format.
2009-11-19 17:38:37 +00:00
Stefan Monnier
a185548b1c * abbrev.el (abbrev-with-wrapper-hook): (re)move...
* simple.el (with-wrapper-hook): ...to here.  Add argument `args'.
* minibuffer.el (completion-in-region-functions): New hook.
(completion-in-region): New function.
* emacs-lisp/lisp.el (lisp-complete-symbol):
* pcomplete.el (pcomplete-std-complete): Use it.
2009-11-19 03:12:51 +00:00