summaryrefslogtreecommitdiff
path: root/run_vim.py
diff options
context:
space:
mode:
Diffstat (limited to 'run_vim.py')
-rwxr-xr-xrun_vim.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/run_vim.py b/run_vim.py
index 93f15e5..e7afd60 100755
--- a/run_vim.py
+++ b/run_vim.py
@@ -43,6 +43,8 @@ nvim = neovim.attach('socket', path=nvim_socket)
existing_buffers = get_listed_buffers(nvim)
if '--float' in sys.argv:
+
+ float_title = filenames[0] if len(filenames) > 0 else ""
nvim.command(
'call nvim_open_win(0, 1, {' +
"'relative': 'editor'," +
@@ -53,7 +55,7 @@ if '--float' in sys.argv:
"'anchor': 'NW'," +
"'style': 'minimal'," +
"'border': 'single'," +
- "'title': [['" + filenames[0] + "', 'Statement']]" +
+ "'title': [['" + float_title + "', 'Statement']]" +
"})");
nvim.command("set winhighlight=Normal:Normal")
else: