Wednesday, October 31, 2012

Re: Avoid typing, completion listing

Le mardi 30 octobre 2012 22:24:19 UTC+1, niva a écrit :
> Hi,I present this kind of file to the user and want to avoid him to type some text that I have in a list. D_foo=D_bar=D_foobar=I have a list in memory that contains some words: let mylist=["word1","word2","word3","word4"].I would like to avoid user to type words that I ever had into mylist I think to use completion list and let it appears on insert mode after each equal sign. How can I do that ?Thank you

I have tried this to make autocompletion in insert mode:
set dictionary=keys(myDict)
set completeopt=menu

But, not only keys of mydict appears when I type CTRL+N CTRL+P.

The menu appears and contains all lines of all opened buffers.

How can I do to restrain on keys of my Dict ?
Thank you


--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments: