[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: merging results from completion-at-point-functions
From: |
Stefan Monnier |
Subject: |
Re: merging results from completion-at-point-functions |
Date: |
Sun, 01 May 2022 13:22:49 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) |
Eric S Fraga [2022-05-01 17:29:54] wrote:
> On Friday, 29 Apr 2022 at 16:52, Stefan Monnier via Users list for the GNU
> Emacs text editor wrote:
>>>> (setq-local completion-at-point-functions
>>>> (list (cape-super-capf #'cape-dabbrev #'cape-dict #'cape-keyword)))
>>
>> Note that this sets up these CAPF functions only for the buffer that's
>> current when the code is executed, so if you put it into your .emacs
>> it's probably going to affect completions in *scratch* only.
>
> Yes, that's clear. Thank you.
>
> I am setting the variable in the right place to have
> it set for the buffer I am writing in. But it just doesn't do anything
> when I try to complete.
>
> To check, if I use
>
> (setq-local completion-at-point-functions (list #'cape-dabbrev))
>
> instead of the expression above, that particular capf does get invoked.
What happens if you go to the place where you want completion to take
place and then do:
M-: (funcall (cape-super-capf #'cape-dabbrev #'cape-dict #'cape-keyword))
RET
[ It's not supposed to have any effect other than returning a value, so
the question is what value does it return. ]
Stefan