Ticket #2394 (closed defect: fixed)
Persistent selection backspace issues
Reported by: | gotar | Owned by: | |
---|---|---|---|
Priority: | trivial | Milestone: | 4.7 |
Component: | mcedit | Version: | 4.7.4 |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Branch state: | Votes for changeset: |
Description
- mcedit new_empty_file
- type in 0123456789
now two versions:
3a. F3 5*left F3 - now digits 5-9 are marked and cursors stays above 5
4a. 2*right A backspace - the new symbol appears between 6 and 7, but after removal digit 4 is marked as well(!)
or:
3b. home F3 5*right F3 - now digits 0-4 are marked and cursor stays above 5
4b. 2*left A backspace - the new symbol appears between 2 and 3, but after removal digit 5 is marked as well(!)
This means that inserting symbol extends selection, but backspace doesn't shrink it back (while delete does) respectively to direction (every time as a result selection END moves).
And now it becames more interesting:
5a. ctrl-u - 'A' gets back between 6 and 7, but 4 remains marked
6a. ctrl-u - 'A' gets away, but acting like backspace not undo - now 3 is marked as well(!)
5b. ctrl-u - 'A' gets back between 2 and 3, but 5 remains marked
6b. ctrl-u - 'A' gets away, but just like it was backspaced not deleted, i.e. marking additional digit 6(!)
So effectively by inserting a letter, removing it and undoing both the operations our selection widened by 2 characters - while first behaviour (p. 3-4) can be logically explained, there's no place for that in undo (p. 5-6): selection should shrink back to 5 characters, not further extend.
But keep backspacing in a) scenario ;)
7a. 3-9 are marked, cursor stays above 7: press backspace 4 times - we've just lost left part of selection(!) and we're back in mark mode (just press left to see it).
Change History
comment:2 Changed 14 years ago by angel_il
- Status changed from new to closed
- Resolution set to fixed
comment:3 Changed 14 years ago by gotar
- Status changed from closed to reopened
- Resolution fixed deleted
Most of the glitches are fixed now, however I've encountered some:
- mcedit new_empty_file
- type in 0123456789
- F3 5*left F3 - digit '4' is not marked at this point
- backspace, ctrl-u - digit '4' is marked now
- left, 2*del, 2*ctrl-u - digits '4' and '5' are not marked.
So it seems something is still wrong with EditUndo (the same happened in 4.7.4).
gotar:
3a..4a and 3b..4b fixed by #2437
i think 5a..7a fixed too.
please try fix from #2437