summaryrefslogtreecommitdiff
path: root/lua
diff options
context:
space:
mode:
authorSimon Hauser <Simon-Hauser@outlook.de>2022-07-12 15:47:39 +0200
committerGitHub <noreply@github.com>2022-07-12 15:47:39 +0200
commit5acb9474a09966c03c0c2541f0d48367d5532029 (patch)
tree28f51516db43a5fc563e0b899289b59fe94a0501 /lua
parent5f253751916664caa15d9d6de8325e796db72686 (diff)
fix: cursor theme for nvim 0.7 (#2069)
Diffstat (limited to 'lua')
-rw-r--r--lua/telescope/pickers/layout_strategies.lua7
1 files changed, 6 insertions, 1 deletions
diff --git a/lua/telescope/pickers/layout_strategies.lua b/lua/telescope/pickers/layout_strategies.lua
index 6e09c64..7af7761 100644
--- a/lua/telescope/pickers/layout_strategies.lua
+++ b/lua/telescope/pickers/layout_strategies.lua
@@ -600,7 +600,12 @@ layout_strategies.cursor = make_documented_layout(
end
local position = vim.api.nvim_win_get_position(0)
- local winbar = vim.o.winbar == "" and 0 or 1
+ local winbar = (function()
+ if vim.fn.exists "&winbar" == 1 then
+ return vim.o.winbar == "" and 0 or 1
+ end
+ return 0
+ end)()
local top_left = {
line = vim.fn.winline() + position[1] + bs + winbar,
col = vim.fn.wincol() + position[2],