[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Nano-devel] Nano with Line Numbering
From: |
Faissal Bensefia |
Subject: |
Re: [Nano-devel] Nano with Line Numbering |
Date: |
Tue, 20 Sep 2016 12:38:28 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 |
On 20/09/16 11:23, Benno Schulenberg wrote:
>
> On Mon, Sep 19, 2016, at 16:43, Faissal Bensefia wrote:
>> On 18/09/16 19:09, Benno Schulenberg wrote:
>> I have attached the new patch.
>
> Okay. Now try this:
> stty cols 44 && src/nano --ignore --soft --linenum +4 README.GIT
>
> Notice how line 4 is wrapped over three lines, but the third line
> is empty. Now press <Down>. One expects the cursor to go to the
> start of line 5, but instead it goes to the empty tail of line 4.
> Not good. Now press <Right> <Right>... The cursor moves as if
> there is a very long invisible tail on line 4. Now press W. The
> character appears in line 5, but the cursor stays on the line above
> it. Also notice how line 5 seems to be broken into two lines and
> all the lines after it were renumbered. But that is all just in
> appearance -- things are messed up and the cursor is never shown
> where it really is.
>
>> Sorry about being too terse, I hope this is a bit better.
>
> Yes, much better. Thanks.
>
> Benno
>
I have fixed the issue you mentioned, the issue came from this
- openfile->current_y += strlenpt(line->data) / (COLS - margin + 1) +
1;
+ openfile->current_y += strlenpt(line->data) / (COLS - margin) + 1;
This was a mistake in adapting it to use margin. The new patch is attached.
~Faissal Bensefia
0001-Added-line-numbers.patch
Description: Text Data
- Re: [Nano-devel] Nano with Line Numbering, (continued)
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/09/12
- Re: [Nano-devel] Nano with Line Numbering, Faissal Bensefia, 2016/09/12
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/09/12
- Re: [Nano-devel] Nano with Line Numbering, Faissal Bensefia, 2016/09/15
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/09/16
- Re: [Nano-devel] Nano with Line Numbering, Faissal Bensefia, 2016/09/18
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/09/18
- Re: [Nano-devel] Nano with Line Numbering, Faissal Bensefia, 2016/09/19
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/09/20
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/09/20
- Re: [Nano-devel] Nano with Line Numbering,
Faissal Bensefia <=
- Re: [Nano-devel] Nano with Line Numbering, Benno Schulenberg, 2016/09/20