nano-devel
[Top][All Lists]
Advanced

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

Re: [Nano-devel] Updated FIX for undo/redo


From: Benno Schulenberg
Subject: Re: [Nano-devel] Updated FIX for undo/redo
Date: Mon, 05 May 2014 13:31:18 +0200

Hello Mark,

On Wed, Apr 23, 2014, at 7:58, Mark Majeres wrote:
> I updated the undo/redo patch.  Patch was created against svn rev.4808
> It turned into a lot more editing than I anticipated.

I've normalized the whitespace in your patch -- see attached.
The biggest change is the removal of an unneeded else after
an if (...) break; it saves a whole level of indentation.


The patch seemed to work fine, until I tried this, typing into
an empty buffer, and using src/nano -I --nonewlines --undo:

two words<Enter>
more words<^K> <Up> <^U>

<M-U> <M-U> <M-U> <M-U> <M-U>
<M-E> <M-E> <M-E> <M-E> 
Segmentation fault.

(Without the --nonewlines it works fine.)


Alternatively, with the same command, type into empty buffer:

<Enter>
<Tab>two words<Enter>
<Tab>more words<^K> <Up> <^Space> <^Space>

(The cursor now sits on the w of "words" after "two".)

<^U>
<M-U> <M-U> <M-U> <M-U> <M-U> <M-U>
<M-E> <M-E> <M-E> <M-E> <M-E> <M-E>
Segmentation fault.

(Also without the --nonewlines it fails.)

Notice how after the fourth <M-U> the cursor sits on the
"w" of "two" instead of at the very end of that line.  And
thus after the third <M-E> the "two" gets broken into two
instead of just a newline being added.

Regards,

Benno

-- 
http://www.fastmail.fm - Faster than the air-speed velocity of an
                          unladen european swallow

Attachment: undoredo.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]