Then I believe we can implement the logic used in MS Visual Studio editor and in Visual Studio Code. If only one is a brace, the highlighting logic will remain as currently: to point a brace the cursor bar can be either before or after the brace. If we have several braces in a row, the highlighting should be based on the brace position. ( It could be based on after-brace position, too. But, I believe the brace position is more straightforward and more consistent for users. I am not talking about OVERWRITE mode when the cursor is underline).
The goto placement should move the caret to matching brace position. If the cursor is after a single brace, double goto will not return to the initial position, however, it will always return to the same brace, that is most important.
Changes should be done in editor_highlight_braces and goto_matching_brace.
I attached these two functions. I also attached three screenshots demonstrating the highlighting logic.
editor_highlight_braces-functon.txt
goto_matching_brace-function.txt

screenshot from 2019-02-03 12-59-39
screenshot from 2019-02-03 12-59-53
screenshot from 2019-02-03 13-00-12


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.