Skip to content

Commit a232437

Browse files
zeertzjqchrisbra
authored andcommitted
patch 9.1.0488: Wrong padding for pum "kind" with 'rightleft'
Problem: Wrong padding for pum "kind" with 'rightleft'. Solution: Fix off-by-one error (zeertzjq). The screen_fill() above is end-exclusive, and - With 'rightleft' it fills `pum_col - pum_base_width - n + 1` to `col`, so the next `col` should be `pum_col - pum_base_width - n`. - With 'norightleft' it fills `col` to `pum_col - pum_base_width + n - 1`, so the next `col` should be `pum_col - pum_base_width + n`. closes: #15004 Signed-off-by: zeertzjq <[email protected]> Signed-off-by: Christian Brabandt <[email protected]>
1 parent ae321b5 commit a232437

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

src/popupmenu.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -728,7 +728,7 @@ pum_redraw(void)
728728
{
729729
screen_fill(row, row + 1, pum_col - pum_base_width - n + 1,
730730
col + 1, ' ', ' ', attr);
731-
col = pum_col - pum_base_width - n + 1;
731+
col = pum_col - pum_base_width - n;
732732
}
733733
else
734734
#endif

src/testdir/dumps/Test_pum_highlights_06.dump

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
| +0&#ffffff0@70|o>f|o|f
2-
| +0#4040ff13&@58| +0#0000001#e0e0e08@1|d|n|i|k|o@1|f| @3|o|o+0#00e0e07#ffd7ff255|f
3-
| +0#4040ff13#ffffff0@58| +0#0000001#ffd7ff255@1|d|n|i|k|o@1|f| |r|a|b|o|o+0#0000e05&|f
4-
| +0#4040ff13#ffffff0@58| +0#0000001#ffd7ff255@1|d|n|i|k|o@1|f| |z|a|B|o|o+0#0000e05&|f
5-
| +0#4040ff13#ffffff0@58| +0#0000001#ffd7ff255@1|d|n|i|k|o@1|f|a|l|a|b|o|o+0#0000e05&|f
2+
| +0#4040ff13&@58| +0#0000001#e0e0e08|d|n|i|k|o@1|f| @4|o|o+0#00e0e07#ffd7ff255|f
3+
| +0#4040ff13#ffffff0@58| +0#0000001#ffd7ff255|d|n|i|k|o@1|f| @1|r|a|b|o|o+0#0000e05&|f
4+
| +0#4040ff13#ffffff0@58| +0#0000001#ffd7ff255|d|n|i|k|o@1|f| @1|z|a|B|o|o+0#0000e05&|f
5+
| +0#4040ff13#ffffff0@58| +0#0000001#ffd7ff255|d|n|i|k|o@1|f| |a|l|a|b|o|o+0#0000e05&|f
66
| +0#4040ff13#ffffff0@73|~
77
| @73|~
88
| @73|~

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -704,6 +704,8 @@ static char *(features[]) =
704704

705705
static int included_patches[] =
706706
{ /* Add new patch number below this line */
707+
/**/
708+
488,
707709
/**/
708710
487,
709711
/**/

0 commit comments

Comments
 (0)