-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Truncated text in floating preview #8
Comments
I've done some more digging and it looks like the completion source is adding those truncations. However, the question still remains about the |
I've written the following function while adapting Nvim-R's omnicompletion to avoid truncated text in the non docked float window created by function FormatTxt(text, splt, jn, maxl)
let wlist = split(a:text, a:splt)
let txt = ['']
let ii = 0
let maxlen = a:maxl - len(a:jn)
for wrd in wlist
if len(txt[ii] . a:splt . wrd) < maxlen
let txt[ii] .= a:splt . wrd
else
let ii += 1
let txt += [wrd]
endif
endfor
let txt[0] = substitute(txt[0], '^' . a:splt, '', '')
return join(txt, a:jn)
endfunction The arguments received by
In the above example, the text in the float window would be more readable if modified by
The two spaces after the line break would indent the output. Python documentation is complex to format because it mix function calls with normal text which require different split and join patterns. Perhaps |
I have the plugin installed, but the text is very truncated for some reason, and in addition, there is a
~
character at the bottom of the preview window for some reason. I'm using the plugin with Deoplete and LanguageClient-NeoVim.Here is my config:
The text was updated successfully, but these errors were encountered: