[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Nano-devel] Nano with Line Numbering
From: |
Benno Schulenberg |
Subject: |
Re: [Nano-devel] Nano with Line Numbering |
Date: |
Mon, 10 Oct 2016 13:37:26 +0200 |
On Sun, Oct 9, 2016, at 18:54, Faissal Bensefia wrote:
> On 09/10/16 16:58, Benno Schulenberg wrote:
> > Second, it doesn't fix the issue. When running 'stty rows 20 &&
> > stty cols 70 && src/nano --ignore --softwrap +999 README --line'
> > the cursor is still after "hand" instead of on the final line.
>
> Ah I see, sorry I misread what you said. This diff should fix it, it was
> an issue with scrolling not taking into account the margin.
It still doesn't fix the issue. Do you test with the given command
at all?
The problem, though, is not in your patch but in do_gotolinecolumn(),
which does not take softwrap into account when trying to figure out
whether the target line is near the bottom of the file. I've pushed
a change that will avoid the issue.
However, your patch is lacking several more "COLS - margin" changes.
See attached diff. I don't know if all of them are needed, and if
there are not others that need to be changed. Probably it will be
cheaper to compute a COLS - margin up front and use that everywhere
instead of repeating the computation many times.
Benno
--
http://www.fastmail.com - The way an email service should be
additional-COLS-minus-margin.patch
Description: Text Data
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/10/09
- Re: [Nano-devel] Nano with Line Numbering, Faissal Bensefia, 2016/10/09
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/10/09
- Re: [Nano-devel] Nano with Line Numbering, Faissal Bensefia, 2016/10/09
- Re: [Nano-devel] Nano with Line Numbering,
Benno Schulenberg <=
- Re: [Nano-devel] Nano with Line Numbering, Faissal Bensefia, 2016/10/10
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/10/11
- Re: [Nano-devel] Nano with Line Numbering, Faissal Bensefia, 2016/10/11
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/10/11
- Re: [Nano-devel] Nano with Line Numbering, Faissal Bensefia, 2016/10/12
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/10/12
- Re: [Nano-devel] Nano with Line Numbering, Brand Huntsman, 2016/10/12
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/10/13
- Re: [Nano-devel] Nano with Line Numbering, Faissal Bensefia, 2016/10/13
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/10/13