diff options
| author | Eli Zaretskii | 2018-04-01 12:19:49 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2018-04-01 12:19:49 +0300 |
| commit | a8ddd05d7d32946b892b9faaba6c9736ed2ad847 (patch) | |
| tree | 40a182e08bae811ba6180f50e193bfb0d44c0d9d /doc | |
| parent | 320ecd3e564facaabdb6324f94c07c447f3175b9 (diff) | |
| download | emacs-a8ddd05d7d32946b892b9faaba6c9736ed2ad847.tar.gz emacs-a8ddd05d7d32946b892b9faaba6c9736ed2ad847.zip | |
Minor copyedits of completion-at-point-functions documentation
* lisp/minibuffer.el (completion-at-point-functions):
* doc/lispref/minibuf.texi (Completion in Buffers): Fix wording
and filling.
Diffstat (limited to 'doc')
| -rw-r--r-- | doc/lispref/minibuf.texi | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/doc/lispref/minibuf.texi b/doc/lispref/minibuf.texi index b01ebb26b69..1d1c93dd144 100644 --- a/doc/lispref/minibuf.texi +++ b/doc/lispref/minibuf.texi | |||
| @@ -1877,10 +1877,11 @@ are used to compute a completion table for completing the text at | |||
| 1877 | point. It can be used by major modes to provide mode-specific | 1877 | point. It can be used by major modes to provide mode-specific |
| 1878 | completion tables (@pxref{Major Mode Conventions}). | 1878 | completion tables (@pxref{Major Mode Conventions}). |
| 1879 | 1879 | ||
| 1880 | When the command @code{completion-at-point} runs, it calls the functions in the | 1880 | When the command @code{completion-at-point} runs, it calls the |
| 1881 | list one by one, without any argument. Each function should return @code{nil} | 1881 | functions in the list one by one, without any argument. Each function |
| 1882 | unless it can and wants to take responsibility for the completion data for the | 1882 | should return @code{nil} unless it can and wants to take |
| 1883 | text at point. Otherwise it should return a list of the form | 1883 | responsibility for the completion data for the text at point. |
| 1884 | Otherwise it should return a list of the following form: | ||
| 1884 | 1885 | ||
| 1885 | @example | 1886 | @example |
| 1886 | (@var{start} @var{end} @var{collection} . @var{props}) | 1887 | (@var{start} @var{end} @var{collection} . @var{props}) |
| @@ -1910,8 +1911,8 @@ next function in @code{completion-at-point-functions} instead of | |||
| 1910 | reporting a completion failure. | 1911 | reporting a completion failure. |
| 1911 | @end table | 1912 | @end table |
| 1912 | 1913 | ||
| 1913 | The functions on this hook should generally return quickly, since they may be | 1914 | The functions on this hook should generally return quickly, since they |
| 1914 | called very often (e.g., from @code{post-command-hook}). | 1915 | may be called very often (e.g., from @code{post-command-hook}). |
| 1915 | Supplying a function for @var{collection} is strongly recommended if | 1916 | Supplying a function for @var{collection} is strongly recommended if |
| 1916 | generating the list of completions is an expensive operation. Emacs | 1917 | generating the list of completions is an expensive operation. Emacs |
| 1917 | may internally call functions in @code{completion-at-point-functions} | 1918 | may internally call functions in @code{completion-at-point-functions} |
| @@ -1934,10 +1935,11 @@ can defer generating completions until necessary. You can use | |||
| 1934 | (my-make-completions))))) | 1935 | (my-make-completions))))) |
| 1935 | @end smallexample | 1936 | @end smallexample |
| 1936 | 1937 | ||
| 1937 | Additionally, the @var{collection} should generally not be pre-filtered based | 1938 | Additionally, the @var{collection} should generally not be |
| 1938 | on the current text between @var{start} and @var{end}, because that is the | 1939 | pre-filtered based on the current text between @var{start} and |
| 1939 | responsibility of the caller of @code{completion-at-point-functions} to do that | 1940 | @var{end}, because that is the responsibility of the caller of |
| 1940 | according to the completion styles it decides to use. | 1941 | @code{completion-at-point-functions} to do that according to the |
| 1942 | completion styles it decides to use. | ||
| 1941 | 1943 | ||
| 1942 | A function in @code{completion-at-point-functions} may also return a | 1944 | A function in @code{completion-at-point-functions} may also return a |
| 1943 | function instead of a list as described above. In that case, that | 1945 | function instead of a list as described above. In that case, that |