Saturday, March 8, 2014

Re: Automatic completion from word list

> E.G. I type "atmcy" then space or punctuation and
> "automatically" is inserted because that's the match for
> /^a.*t.*m.*c.*y/ in the word list.

I'm currently working on a plugin[1] that can be configured to fit your example to some extent:

let g:likelycomplete#select_imap = '<c-s-space>'
let g:likelycomplete#use_fuzzy_matches = 1
let g:likelycomplete_filetypes = ["your filetype"]
let g:likelycomplete#other_sources = ['g:my_words']
let g:my_words = ['automatically']

This allows you to type

atmcy

On <c-s-space> users will be presented a list of possible completions, including "automatically". (There is also an option to use <c-x><c-u> but that's less useful for long lists.)

It's not the typical use case of that plugin though. :-)

[1] https://github.com/tomtom/likelycomplete_vim

--
--
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

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment