[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Collecting completion candidates from multiple files
From: |
Daniel Martín |
Subject: |
Re: Collecting completion candidates from multiple files |
Date: |
Thu, 13 Jan 2022 16:14:15 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.2 (darwin) |
xenodasein--- via "Emacs development discussions." <emacs-devel@gnu.org>
writes:
>
> I wondered about this also; is there built-in completion functionality that
> can collect all words or symbols from existing buffers of the same mode, or
> all existing buffers?
M-x find-library RET dabbrev RET
This built-in library provides hooks like
dabbrev-select-buffers-function. Packages can customize it to return a
custom list of buffers. For example, a mode for a programming language
that supports includes could implement a custom function that returns
buffers created from parsing includes recursively (something like Vim's
CTRL-P/CTRL-N, if I'm not mistaken).