ycm-core / YouCompleteMe

A code-completion engine for Vim
http://ycm-core.github.io/YouCompleteMe/
GNU General Public License v3.0
25.44k stars 2.81k forks source link

Add "winwidth" option to g:ycm_goto_buffer_command #1956

Closed lithammer closed 8 years ago

lithammer commented 8 years ago

vim-jedi has an option to split goto commands depending on the size of the current window called "winwidth". It would be nice to add this option to YCM's g:ycm_goto_buffer_command.

------------------------------------------------------------------------------
6.11. `g:jedi#use_splits_not_buffers`   *g:jedi#use_splits_not_buffers*

If you want to open new split for "go to", you could set this option to the
direction which you want to open a split with.

Options: top, left, right, bottom or winwidth
Default: "" (not enabled by default)

Note: with the 'winwidth' option the window is split vertically or horizontally
depending on the width of the window relative to 'textwidth'. This essentially
means that if the window is big enough it will be split vertically but if it is
small a horizontal split happens.
Valloric commented 8 years ago

Eh, IMO it's too gimmicky. :)

Thanks for sharing the idea though.