diff options
author | bfredl <bjorn.linse@gmail.com> | 2023-09-17 12:23:22 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-17 12:23:22 +0200 |
commit | a0c99755b8a93143df6d1df48d401b5438d160d6 (patch) | |
tree | 5681aee9e5c9fe929067ed1d34d9683e936b9892 /src | |
parent | d70667a1c1f887529d1b4952325aff368c200ef1 (diff) | |
parent | 51836517738babaa406bc615fd9984129c5179a4 (diff) | |
download | rneovim-a0c99755b8a93143df6d1df48d401b5438d160d6.tar.gz rneovim-a0c99755b8a93143df6d1df48d401b5438d160d6.tar.bz2 rneovim-a0c99755b8a93143df6d1df48d401b5438d160d6.zip |
Merge pull request #25190 from glepnir/echo_hl
fix(highlight): correct hi command output
Diffstat (limited to 'src')
-rw-r--r-- | src/nvim/highlight_group.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/nvim/highlight_group.c b/src/nvim/highlight_group.c index b970e752bb..84cf19ba69 100644 --- a/src/nvim/highlight_group.c +++ b/src/nvim/highlight_group.c @@ -824,7 +824,7 @@ void set_hl_group(int id, HlAttrs attrs, Dict(highlight) *dict, int link_id) g->sg_link = 0; } - g->sg_gui = attrs.rgb_ae_attr; + g->sg_gui = attrs.rgb_ae_attr &~HL_DEFAULT; g->sg_rgb_fg = attrs.rgb_fg_color; g->sg_rgb_bg = attrs.rgb_bg_color; @@ -851,7 +851,7 @@ void set_hl_group(int id, HlAttrs attrs, Dict(highlight) *dict, int link_id) } } - g->sg_cterm = attrs.cterm_ae_attr; + g->sg_cterm = attrs.cterm_ae_attr &~HL_DEFAULT; g->sg_cterm_bg = attrs.cterm_bg_color; g->sg_cterm_fg = attrs.cterm_fg_color; g->sg_cterm_bold = g->sg_cterm & HL_BOLD; @@ -1441,7 +1441,7 @@ void restore_cterm_colors(void) /// @param check_link if true also check for an existing link. /// /// @return true if highlight group "idx" has any settings. -static int hl_has_settings(int idx, bool check_link) +static bool hl_has_settings(int idx, bool check_link) { return hl_table[idx].sg_cleared == 0 && (hl_table[idx].sg_attr != 0 |