Multiple level of autobrace
AbandonedPublic

Authored by cullmann on Mar 27 2019, 10:50 PM.

Details

Reviewers
cactus
Summary

Currently, only one level of autobrace is working.
If the user type (()), the result is (())).

This patch remember multiple levels of autobrace.
With this, if the user type (()), the result is (()) as expected.

Test Plan

In kate with autobrace enabled:

is for the cursor position.
  • Enter ((

The result is ((|))

  • Enter (())

The result is (())|

  • Enter (( then backspace

The result is (|)

  • Enter (( then backspace twice

The result is |

  • Enter ([])

The result is ([])|

  • Enter {{

The result is {{|}}

  • Enter {{}} then left arrow twice, then backspace

The result is {|}}

Diff Detail

Repository
R39 KTextEditor
Branch
MultipleLevelAutobrace (branched from master)
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 10209
Build 10227: arc lint + arc unit
cactus created this revision.Mar 27 2019, 10:50 PM
Restricted Application added projects: Kate, Frameworks. · View Herald TranscriptMar 27 2019, 10:50 PM
Restricted Application added subscribers: kde-frameworks-devel, kwrite-devel. · View Herald Transcript
cactus requested review of this revision.Mar 27 2019, 10:50 PM

This patch looks similar to D12295
My suggestion to the issue D19608

Oh, I'm sorry. I did not see that.
I'm waiting this feature for a while. I am glad this is fix.

cullmann commandeered this revision.Wed, May 8, 5:40 PM
cullmann added a reviewer: cactus.
cullmann added a subscriber: cullmann.

We consider this fixed with D19608.
If you disagree, feel free to reopen this request.
Btw., thanks for the incentive to submit a patch!

cullmann abandoned this revision.Wed, May 8, 5:41 PM