Re: [PATCH] Internal editor brokeness with ncurses (fwd)



Hello,

On Fri, 12 Nov 2004, Vladimir Nadvornik wrote:

> On Wednesday 10 November 2004 13:02, Pavel Tsekov wrote:
> > Here is a changelog entry for this patch:
> >
> > 2004-11-10  Pavel Tsekov  <ptsekov gmx net>
> >
> > 	* editdraw.c (print_to_widget): Don't use addch() with negative
> > 	offset to skip over excessive columns. Output only those columns
> > 	that should be displayed on the screen.
> > _______________________________________________
>
>
> There is similar problem in dialog.c. If the dialog is wider than the screen,
> it writes to negative columns.
> This patch fixes it.
>
> --- src/dialog.c
> +++ src/dialog.c
> @@ -196,6 +196,12 @@
>      if ((flags & DLG_TRYUP) && (y1 > 3))
>         y1 -= 2;
>
> +    if (x1 < 0)
> +       x1 = 0;
> +
> +    if (y1 < 0)
> +       y1 = 0;
> +

I don't think so. The patch just avoids the use of negative offsets but
it doesn't deal with the excessive line length afaics. If you read
my explanation of the editor problem, you'll see that the unpleasent
visual effect is due to fact that when using certain ncurses routines
to write lines longer then COLS you'll get the excess columns on the next
line.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]