Problem: On a narrow screen ":hi" output is confusing.
Solution: Insert a space between highlight group name and "xxx". (Masato
Nishihaga, closes #4599)
{
int endcol = 19;
int newline = TRUE;
+ int name_col = 0;
if (!did_header)
{
if (got_int)
return TRUE;
msg_outtrans(HL_TABLE()[id - 1].sg_name);
+ name_col = msg_col;
endcol = 15;
}
else if (msg_col + outlen + 1 >= Columns)
/* Show "xxx" with the attributes. */
if (!did_header)
{
+ if (endcol == Columns - 1 && endcol <= name_col)
+ msg_putchar(' ');
msg_puts_attr("xxx", syn_id2attr(id));
msg_putchar(' ');
}
call assert_match('hi Normal\s*clear', hlNormal)
endif
endfunc
+
+function Test_no_space_before_xxx()
+ let l:org_columns = &columns
+ set columns=17
+ let l:hi_StatusLineTermNC = join(split(execute('hi StatusLineTermNC')))
+ call assert_match('StatusLineTermNC xxx', l:hi_StatusLineTermNC)
+ let &columns = l:org_columns
+endfunction
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 1606,
/**/
1605,
/**/