diff src/drawline.c @ 18364:ee489bb09ea8 v8.1.2176

patch 8.1.2176: syntax attributes not combined with Visual highlighting Commit: https://github.com/vim/vim/commit/8459006af5e78bd0bd6dcfc6d54ddac35a91ee1c Author: Bram Moolenaar <Bram@vim.org> Date: Fri Oct 18 23:12:20 2019 +0200 patch 8.1.2176: syntax attributes not combined with Visual highlighting Problem: Syntax attributes not combined with Visual highlighting. (Arseny Nasokin) Solution: Combine the attributes. (closes #5083)
author Bram Moolenaar <Bram@vim.org>
date Fri, 18 Oct 2019 23:15:03 +0200
parents 596a04c49d76
children 86c00b8fefea
line wrap: on
line diff
--- a/src/drawline.c
+++ b/src/drawline.c
@@ -1470,9 +1470,21 @@ win_line(
 	    attr_pri = TRUE;
 #ifdef LINE_ATTR
 	    if (area_attr != 0)
+	    {
 		char_attr = hl_combine_attr(line_attr, area_attr);
+# ifdef FEAT_SYN_HL
+		if (syntax_attr != 0)
+		    char_attr = hl_combine_attr(syntax_attr, char_attr);
+# endif
+	    }
 	    else if (search_attr != 0)
+	    {
 		char_attr = hl_combine_attr(line_attr, search_attr);
+# ifdef FEAT_SYN_HL
+		if (syntax_attr != 0)
+		    char_attr = hl_combine_attr(syntax_attr, char_attr);
+# endif
+	    }
 # ifdef FEAT_TEXT_PROP
 	    else if (text_prop_type != NULL)
 	    {