This is an automatically generated e-mail. To reply, visit: https://git.reviewboard.kde.org/r/118955/

This review has been submitted with commit e4bc98575a5810746df2e02a660ae8c923263cfe by Miquel Sabaté to branch KDE/4.13.

- Commit Hook


On June 28th, 2014, 3:28 p.m. UTC, Miquel Sabaté Solà wrote:

Review request for Kate and Michal Humpula.
By Miquel Sabaté Solà.

Updated June 28, 2014, 3:28 p.m.

Bugs: 336357
Repository: ktexteditor

Description

Right now the way we replace characters with the "r" command is too naive. If we press keys like backspace, capslock, left, etc. after pressing "r", the replace should be canceled. Moreover, if we press the enter key after pressing "r", then a newline should be the character being added. All of these things are now possible with this patch.

This is not the cleanest patch ever (adding the encoded2qt function is a bit too hack-ish), but I've tried fixing this in other ways and all of them failed miserably :)

Testing

I've added a couple of tests.

Diffs

  • autotests/src/vimode/modes.h (019097d)
  • autotests/src/vimode/modes.cpp (8519511)
  • src/vimode/katevikeyparser.h (abfc3af)
  • src/vimode/katevikeyparser.cpp (d97481c)
  • src/vimode/katevinormalmode.cpp (9643d60)

View Diff