Seems like the width for writing BIDI newlines is too wide. Adjusting the
call
to write_nstring_int() to take tb's width instead fixes this. It seems int
dw is
then obsolete. I was able to test successfully on a ltr and rtl locale.
@@ -381,7 +381,6 @@
int size;
char dir = 'N';
int newdir = 1;
- int dw = 0;
if (!c->isMapped)
return;
@@ -414,7 +413,7 @@
SLsmg_write_string(tb->blankline);
newtGotorc(c->top + i, c->left);
/* BIDI: we need *nstring* here to properly align lines */
- write_nstring_int(tb->lines[i + tb->topLine], c->width - dw, &dir);
+ write_nstring_int(tb->lines[i + tb->topLine], tb->textWidth, &dir);
/* Does new paragraph follow? */
if (!*tb->lines[i + tb->topLine])
dir = 'N';
On Sat, 23 Nov 2019 00:10:21 +0100 MichaIng <[email protected]> wrote:
> Package: whiptail
> Version: 0.52.21-3+b1
> Additionally: 0.52.20-8 (Buster) + 0.52.19-1+b1 (Stretch)
>
> When using whiptail with the "--scrollbar" option, besides the text
> scrolling ability, scroll bars should show up on the right side of the
> whiptail window.
> This is the case, but the bars start below the lines that are used by
> the text already, regardless if the text reaches the right side or not.
> Scrolling and scroll bars only make sense, when the text lines exceed
> the whiptail window lines, hence in all reasonable cases, the scroll
> bars are hidden completely.
>
> Scrolling is always possible with this option as expected and as well
> the issue does not appear on selection fields of --menu and --checklist,
> which have their own scroll bars, when required, which show up fine.
> Screenshots can be found here:
> https://github.com/MichaIng/DietPi/issues/2947
>
>