@@ -2182,6 +2182,11 @@ See the file type feature summary for an overview of the features available for
21822182each file type. See the _YcmCompleter subcommands_ section for more information
21832183on the available subcommands and their usage.
21842184
2185+ Some commands, like | Format | accept a range, like ':%YcmCompleter Format'.
2186+
2187+ Some commands like | GetDoc | and the various | GoTo | commands respect modifiers,
2188+ like ':rightbelow YcmCompleter GetDoc', ':vertical YcmCompleter GoTo'.
2189+
21852190-------------------------------------------------------------------------------
21862191 *youcompleteme-ycmcompleter-subcommands*
21872192YcmCompleter Subcommands ~
@@ -2418,6 +2423,25 @@ under the cursor. Depending on the file type, this includes things like:
24182423- Python docstrings,
24192424- etc.
24202425
2426+ The documentation is opened in the preview window, and options like
2427+ 'previewheight' are respected. If you would like to customise the height and
2428+ position of this window, we suggest a custom command that:
2429+
2430+ - Sets 'previewheight' temporarily
2431+ - Runs the | GetDoc | command with supplied modifiers
2432+ - Restores 'previewheight' .
2433+
2434+ For example:
2435+ >
2436+ command -count ShowDocWithSize
2437+ \ let g:ph=&previewheight
2438+ \ <bar> set previewheight=<count>
2439+ \ <bar> <mods> YcmCompleter GetDoc
2440+ \ <bar> let &previewheight=g:ph
2441+ <
2442+ You can then use something like ':botright vertical 80ShowDocWithSize'. Here's
2443+ an example of that: https://asciinema.org/a/hE6Pi1gU6omBShwFna8iwGEe9
2444+
24212445Supported in filetypes: 'c, cpp, objc, objcpp, cuda, cs, go, java, javascript,
24222446python, typescript, rust'
24232447
0 commit comments