Bug 453354 - Multi-line edits in block selection mode spawn additional brackets, all brackets are auto selected
Summary: Multi-line edits in block selection mode spawn additional brackets, all brack...
Status: CONFIRMED
Alias: None
Product: kdevelop
Classification: Applications
Component: All editors (other bugs)
Version First Reported In: 5.7.211203
Platform: Manjaro Linux
: NOR minor
Target Milestone: ---
Assignee: kdevelop-bugs-null
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-05-03 18:15 UTC by Daniel
Modified: 2024-01-15 03:24 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel 2022-05-03 18:15:44 UTC
SUMMARY
When editing multiple lines in block selection mode everything works as expected, until you type brackets (closing or opening). An additional undesired bracket is added, all the brackets (the one you typed as well as the additional one) are selected and thus overwritten on the next button press. True for all () {} []



STEPS TO REPRODUCE
1.  Turn on block select mode
2.  Select multiple lines
3.  Type your text including a bracket (opening or closing)

OBSERVED RESULT
Typed ")" got ")(" (text selected)

EXPECTED RESULT
Type ")" get ")" (text not selected)

SOFTWARE/OS VERSIONS
Currently tested on 5.7.211203 on Manjaro Linux

ADDITIONAL INFORMATION
Comment 1 aaron.c.hammond 2024-01-15 03:24:20 UTC
Confirmed in Version 5.10.221202 (22.12.2), Kate Version 22.12.3

I have automatic bracket closure turned off, but still automatically closes brackets while in block select mode.
I believe it is due to the `when you type these characters while text is selected, they will surround the selected text instead of replacing it` option in the editing options.
Selecting a vertical column of lines with width 0 (I intend to insert text across many lines) probably fires the 'selected' criteria, despite no characters being selected.

Would prefer for kate/kdevelop to ~never~ add automatic brackets, or at least let me configure it.