bugGNU nano - Bugs: bug #50645, with softwrap, PageUp/PageDown...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #50645: with softwrap, PageUp/PageDown glitches the display without smooth scrolling

Submitter:  David Lawrence Ramsey <dolorous>
Submitted:  Sun 26 Mar 2017 11:54:28 PM UTC
   
 
Severity:  3 - Normal Status:  Fixed
Assigned to:  dolorous Open/Closed:  Closed

Mon 27 Mar 2017 09:46:12 AM UTC, comment #2: 

Fixed in git, 384332d0.  Thanks for the patch.

(Closing, because an unreleased bug.)

Benno Schulenberg <bens>
Group administrator
Sun 26 Mar 2017 11:56:21 PM UTC, comment #1: 

The attached patch fixes this.

(file #40157)

David Lawrence Ramsey <dolorous>
Group Member
Sun 26 Mar 2017 11:54:28 PM UTC, original submission:  

With current git, in an 80x24 terminal, with the attached file paragraph.txt, run:

nano +12 --ignore --softwrap paragraph.txt

Press PageDown, so that the screen scrolls (it shouldn't do this, since it's at the bottom of the file, but that's a separate bug), and then press PageUp. The cursor will be placed back at the top of the file, but the top line won't change until you press PageUp again (Ctrl-L won't work).

This is caused by PageUp and PageDown's not handling the case where softwrap is on, smooth scrolling is off, and the line at the top of the screen is partially scrolled offscreen.

Specifically, nano sets current to edittop and placewewant to zero to put the cursor at the beginning of the top line of the file.  However, if the top line is partially offscreen, this is incorrect, since the line begins at firstcolumn, not zero.  Furthermore, nano changes placewewant here, but doesn't change target_column to match.  Since target_column is set based on the value of placewewant whether we're in softwrap mode or not, this means the line is drawn incorrectly.

David Lawrence Ramsey <dolorous>
Group Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by bens (Posted a comment)
  • -email is unavailable- added by dolorous (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2017-03-27 bens StatusNone Fixed
        Assigned toNone dolorous
        Open/ClosedOpen Closed
        SummaryPageUp/PageDown glitches display with softwrap and without smooth scrolling with softwrap, PageUp/PageDown glitches the display without smooth scrolling
    2017-03-26 dolorous Attached File- Added 0001-display-fix-PageUp-PageDown-display-glitches-without.patch, #40157
    2017-03-26 dolorous Attached File- Added paragraph.txt, #40156

    Back to the top

    Powered by Savane 3.13-4b48.
    Corresponding source code