bugGNU nano - Bugs: bug #46591, indenting confuses the undo system

 
 

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

bug #46591: indenting confuses the undo system

Submitter:  Benno Schulenberg <bens>
Submitted:  Wed 02 Dec 2015 06:44:03 PM UTC
   
 
Severity:  3 - Normal Status:  Fixed
Assigned to:  bens Open/Closed:  Closed

Sat 09 Jan 2016 04:18:29 PM UTC, comment #2: 

Bug #46860 requests the undo system to also cover indenting/unindenting.

Benno Schulenberg <bens>
Group administrator
Thu 03 Dec 2015 09:36:24 AM UTC, comment #1: 

The temporary mistake prevention went into SVN, r5474, plus notes about this in the documentation, r5475.

Benno Schulenberg <bens>
Group administrator
Wed 02 Dec 2015 06:44:03 PM UTC, original submission:  

Indenting or unindenting will make the undo items add and remove the wrong characters.

For example, run 'src/nano --ignore +6 README', and type:

^Space ^Space big Space Home
M-A  Down Down Down
Shift+Alt+}  Shift+Alt+{
M-U

See how "ano " is deleted instead of "big ".

I think that -- as with bug #45531 -- it is better to sacrifice the undo stack than to do the wrong thing when the user hits M-U.

The proper fix is, of course, to instrument the indenting routine with add_undo() and update_undo() calls, but that will require much more thinking.  So, as a temporary measure...

Benno Schulenberg <bens>
Group administrator

 

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

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by bens (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 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2016-07-22 bens StatusReady For Test Fixed
    2016-01-09 bens Open/ClosedOpen Closed
    2015-12-03 bens StatusNone Ready For Test

    Back to the top

    Powered by Savane 3.13-4448.
    Corresponding source code