1
0
forked from pool/mutt
mutt/COLS-workaround.dif

38 lines
914 B
Plaintext
Raw Normal View History

Use professionel VLINE
---
sidebar.c | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
--- sidebar.c
+++ sidebar.c 2016-07-26 12:32:38.170166748 +0000
@@ -547,6 +547,7 @@ static int draw_divider (int first_row,
{
/* Calculate the width of the delimiter in screen cells */
int delim_len = mutt_strwidth (SidebarDividerChar);
+ int altchar = 0;
if (delim_len < 1)
return delim_len;
@@ -557,13 +558,19 @@ static int draw_divider (int first_row,
if (delim_len > SidebarWidth)
return -1;
+ if (delim_len == 1 && strcmp(SidebarDividerChar, "|") == 0)
+ altchar++;
+
SETCOLOR(MT_COLOR_DIVIDER);
int i;
for (i = 0; i < num_rows; i++)
{
move (first_row + i, SidebarWidth - delim_len);
- addstr (NONULL(SidebarDividerChar));
+ if (altchar)
+ addch (ACS_VLINE);
+ else
+ addstr (NONULL(SidebarDividerChar));
}
return delim_len;