diff --git a/README.md b/README.md index 261eb1c..1a143e8 100644 --- a/README.md +++ b/README.md @@ -41,6 +41,7 @@ use 'sindrets/winshift.nvim' require("winshift").setup({ highlight_moving_win = true, -- Highlight the window being moved focused_hl_group = "Visual", -- The highlight group used for the moving window + window_picker_hl_group = "StatusLineNC" -- The highlight group used for the target windows moving_win_options = { -- These are local options applied to the moving window while it's -- being moved. They are unset when you leave Win-Move mode. diff --git a/doc/winshift.txt b/doc/winshift.txt index 4927984..b93ffaa 100644 --- a/doc/winshift.txt +++ b/doc/winshift.txt @@ -27,6 +27,7 @@ Example configuration with default settings: require("winshift").setup({ highlight_moving_win = true, -- Highlight the window being moved focused_hl_group = "Visual", -- The highlight group used for the moving window + window_picker_hl_group = "StatusLineNC" -- The highlight group used for the target windows moving_win_options = { -- These are local options applied to the moving window while it's -- being moved. They are unset when you leave move mode. diff --git a/lua/winshift/colors.lua b/lua/winshift/colors.lua index 775b5a9..7c85a32 100644 --- a/lua/winshift/colors.lua +++ b/lua/winshift/colors.lua @@ -171,6 +171,8 @@ function M.get_hl_groups() or (M.get_bg({ hl_focused, "Normal" }) or "white") local fg_focused = reverse and (M.get_bg({ hl_focused, "Normal" }) or "black") or nil + local hl_window_picker = config.get_config().window_picker_hl_group + return { Normal = { fg = fg_focused, bg = bg_focused }, EndOfBuffer = { fg = bg_focused, bg = bg_focused }, @@ -178,7 +180,7 @@ function M.get_hl_groups() CursorLineNr = { fg = M.get_fg("CursorLineNr"), bg = bg_focused, gui = M.get_gui("CursorLineNr") }, SignColumn = { fg = M.get_fg("SignColumn"), bg = bg_focused }, FoldColumn = { fg = M.get_fg("FoldColumn"), bg = bg_focused }, - WindowPicker = { fg = "#ededed", bg = "#4493c8", ctermfg = 255, ctermbg = 33, gui = "bold" }, + WindowPicker = { fg = M.get_fg(hl_window_picker), bg = M.get_bg(hl_window_picker), gui = M.get_gui(hl_window_picker) }, } end diff --git a/lua/winshift/config.lua b/lua/winshift/config.lua index 270d2f4..d6f52b6 100644 --- a/lua/winshift/config.lua +++ b/lua/winshift/config.lua @@ -5,6 +5,7 @@ local M = {} M.defaults = { highlight_moving_win = true, focused_hl_group = "Visual", + window_picker_hl_group = "StatusLineNC", moving_win_options = { wrap = false, cursorline = false,