bugGNU nano - Bugs: bug #50415, after an external spell check, the...

 
 

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

bug #50415: after an external spell check, the cursor is not placed at end-of-line again

Submitter:  Benno Schulenberg <bens>
Submitted:  Mon 27 Feb 2017 07:52:19 PM UTC
   
 
Severity:  2 - Minor Status:  Fixed
Assigned to:  bens Open/Closed:  Closed

Wed 01 Mar 2017 10:05:09 AM UTC, comment #2: 

Fixed in git, adf69a05.

Benno Schulenberg <bens>
Group administrator
Tue 28 Feb 2017 07:06:32 PM UTC, comment #1: 

If before starting a spellcheck the cursor is at the end of a line (current_x points at '\0'), then ensure that it points there again also afterward.

Benno Schulenberg <bens>
Group administrator
Mon 27 Feb 2017 07:52:19 PM UTC, original submission:  

To reproduce, run: src/nano --ignore --speller="aspell -x -c -l en"

Then type the misspelled word "wondeful", without the quotes and without hitting Enter.  Note that the cursor now sits after the "l".  Then type ^T, and choose 1) to correct the misspelling.  See that now the cursor sits on the "l".  This is not right: if the word expands, and the cursor is on the same line as the corrected word, the cursor should adapt its position.

Of course: in general this is not possible, because when replacing the current buffer with the spell-corrected buffer, nano has no idea where in the buffer the spell program made any changes.  But at least this one special case, which will occur quite often (the user typing ^T while while the cursor is at the end of a piece of text she has just typed), could be handled correctly: when the cursor sits at EOF when ^T is typed, put it again at EOF when the speller returns.

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 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2017-04-02 bens Open/ClosedOpen Closed
    2017-03-01 bens StatusNone Fixed
    2017-02-28 bens Assigned toNone bens
        Summaryafter an external spell check, the cursor position is not properly adjusted after an external spell check, the cursor is not placed at end-of-line again

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code