fix(highlite): g:terminal_color_xx not being set

Previous changes to this plugin prevented the terminal color from being
set.

Even before the changes, the terminal color was not set in all
conditions. Now it will be!
This commit is contained in:
Iron-E 2020-12-05 17:44:20 -05:00
parent 20bc365437
commit 2541117eb6
No known key found for this signature in database
GPG Key ID: 19B71B7B7B021D22
1 changed files with 3 additions and 3 deletions

View File

@ -153,9 +153,9 @@ function highlite.highlight(highlight_group, attributes) -- {{{ †
end --}}} ‡
function highlite:highlight_terminal(terminal_ansi_colors)
if self.using_hex_or_256 then for index, color in ipairs(terminal_ansi_colors) do
vim.g['terminal_color_'..index] = vim.o.termguicolors and color[_PALETTE_HEX] or color[_PALETTE_256]
end end
for index, color in ipairs(terminal_ansi_colors) do
vim.g['terminal_color_'..index] = vim.o.termguicolors and color[_PALETTE_HEX] or color[_PALETTE_256] or get(color, _PALETTE_ANSI)
end
end
return setmetatable(highlite, {