Closed blayz3r closed 3 years ago
I think an extra blank line might be necessary if, for example, the paragraph is a function definition. I changed the code to add an extra blank line only if the last line is not a blank line yet. Is it OK now?
Still see it, does the fix work on your machine? I agree, it works the way you expect for a class or function but introduces extra lines for regular paragraphs.
I never use the send paragraph function...
Could you, please, try changing the code in ftplugin/python_cmdline.vim
(line 42) from
if a:lines[len(a:lines)-1] == ''
call VimCmdLineSendCmd(join(a:lines, b:cmdline_nl))
else
call VimCmdLineSendCmd(join(add(a:lines, ''), b:cmdline_nl))
endif
to
call VimCmdLineSendCmd(join(a:lines, b:cmdline_nl))
? Does it work?
Yep better. thanks.
Using :call PythonSourceLines(getline(1,3)) works fine but it looks like:
Adds the empty line before the loop breaks
Windows 10, python 3.7