Merge remote-tracking branch 'origin/master' into dev

This commit is contained in:
David Halter
2013-01-22 06:56:40 +01:00
3 changed files with 18 additions and 2 deletions

View File

@@ -53,6 +53,9 @@ in your jedi-vim repository.
The autocompletion can be used with <ctrl+space>, if you want it to work with
<tab> you can use `supertab <https://github.com/ervandew/supertab>`_.
On Arch Linux, you can also install jedi-vim from AUR: `vim-jedi
<https://aur.archlinux.org/packages/vim-jedi/>`__.
Options
=======
@@ -103,6 +106,13 @@ you don't want this:
let g:jedi#popup_on_dot = 0
Jedi selects the first line of the completion menu: for a better typing-flow and
usually saves one keypress.
.. code-block:: vim
let g:jedi#popup_select_first = 0
There's some support for refactoring:
.. code-block:: vim

View File

@@ -40,7 +40,12 @@ end
if g:jedi#popup_on_dot
if stridx(&completeopt, 'longest') > -1
inoremap <buffer> . .<C-R>=jedi#do_popup_on_dot() ? "\<lt>C-X>\<lt>C-O>" : ""<CR>
if g:jedi#popup_select_first
inoremap <buffer> . .<C-R>=jedi#do_popup_on_dot() ? "\<lt>C-X>\<lt>C-O>\<lt>C-N>" : ""<CR>
else
inoremap <buffer> . .<C-R>=jedi#do_popup_on_dot() ? "\<lt>C-X>\<lt>C-O>" : ""<CR>
end
else
inoremap <buffer> . .<C-R>=jedi#do_popup_on_dot() ? "\<lt>C-X>\<lt>C-O>\<lt>C-P>" : ""<CR>
end

View File

@@ -34,7 +34,8 @@ let s:settings = {
\ 'pydoc': "'K'",
\ 'show_function_definition': 1,
\ 'function_definition_escape': "'≡'",
\ 'auto_close_doc': 1
\ 'auto_close_doc': 1,
\ 'popup_select_first': 1
\ }
for [key, val] in items(s:settings)