Closed adam-ah closed 11 years ago
1., to use all open buffers (with same file type)?
Please read FAQ.
Q: I want to complete from all buffers.
A: |g:neocomplcache_same_filetype_lists|
let g:neocomplcache_same_filetype_lists = {}
let g:neocomplcache_same_filetype_lists._ = '_'
2., scan a directory recursively for possible hits?
You can use tags complete by using "ctags -R" command. But it is too heavy.
I improved buffer cache timing. Please update and check it. And you should install vimproc.
Thanks for the quick reply - however, I don't want to use all buffers, just all buffers with same filetype. I thought the default behaviour is to use that - so when I'm editing A.js and B.js is open as a buffer (#2) by default I would see completions from B.js in A.js.
Please tell me the representation way. I will check.
Sorry, not too sure what you mean ?!
You should update neocomplcache. I think the problem is fixed. But if it is not fixed in your environment, please tell me the representation way(command).
It's not fixed yet. So the way I can reproduce it: vi A.js :badd B.js MyObj. # in A.js typing the . brings up only the default functions :buffer 2 MyObjc.ban # typing the . correctly displays ban :buffer 1 MyObj.b # .ban correctly appears
Maybe adding a buffer does not refresh the cache?
I improved for it.
I don't want to use all buffers, just all buffers with same filetype.
@adam-ho In some cases, we need completting from other filetypes like
.c
and .h
.css
,.javascript
and .html
But you can custom it by g:neocomplcache_same_filetype_lists
.
just know that. is there defualt same_filetype settings?
Thanks Shougo, fcaa25e9b850a256f4027a89f2398ed422b97967 seems to fix it!
just know that. is there defualt same_filetype settings?
Because it is complicated, please refer to neocomplcache#init#_variables()
in autoload/neocomplcache/init.vim for the initial value.
Just out of curiosity: maybe I'm doing something completely wrong but I'm not sure how people could use it before this fix? I mean completing across files is one of the most fundamental features right? So before this fix how could you complete across files? :)
@adam-ho <c-x><c-n>
or <c-x><c-p>
vim's built-in feature
erm... yeah, that's the title of the bug report :) However, the whole point of this plugin is to avoid using that, isn't it? :)
Tried to find any reasonable solution but no luck so far. The use case is simple: I have several buffers open (Javascript files). If I press CTRL-O CTRL-N the completion correctly shows the possible endings marking the source file. However, neocomplcache only shows completions from the current buffer.
How can I convince neocomplcache
1., to use all open buffers (with same file type)? 2., scan a directory recursively for possible hits?
Thanks!
vimrc:
let g:neocomplcache_enable_at_startup = 1
VIM - Vi IMproved 7.3 (2010 Aug 15, compiled Jun 24 2011 20:00:09) Mac OS X