[Github-comments] [geany/geany] Improve auto close (#2943)

Jeremias Kleer notifications at xxxxx
Fri Oct 15 06:20:44 UTC 2021


The Geany automatic closing of typed ", ', (, [ and { isn't working very well.
For e.g. typing
```
void main() {
}
```
results in
```
void main() {
    })
```
Above the automatically inserted closing parenthesis stays after the cursor when I type the closing parenthesis and so it is moving while typing at the very end, after the curly braces.

Or typing the following, the automatically inserted closing double quote moves with the cursor.
`std::string d = "asdf";`
results in
`std::string d = "asdf";""`

This is only circumventable with using the arrow keys or clicking with the mouse after the automatically inserted closing character.

Furthermore automatically inserting isn't working if Geany somehow finds a closing character somewhere else, e.g. inside the above example curly braces `void main() {}` typing:
`if() {`
doesn't add an closing brace as it find the closing from the `main`.

As I love to use Geany in my everday work this would be a very valuable improvement. So I wouldn't need need to compile my own better Geany every now and then.
You can view, comment on, or merge this pull request online at:

  https://github.com/geany/geany/pull/2943

-- Commit Summary --

  * <a href="https://github.com/geany/geany/pull/2943/commits/d246870dbb081a6888f0a7a7dd8d3c1305567da3">Consume closing brackets, braces, parenthesis, single and double quotes</a>
  * <a href="https://github.com/geany/geany/pull/2943/commits/b3d0cdd1de364c253d18a36bb225a928feb10eff">Nice on-new-line bracket handling</a>

-- File Changes --

    M doc/geany.txt (5)
    M src/editor.c (172)
    M src/editor.h (1)
    M src/sciwrappers.c (10)
    M src/sciwrappers.h (3)

-- Patch Links --

https://github.com/geany/geany/pull/2943.patch
https://github.com/geany/geany/pull/2943.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/2943
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20211014/40e5380b/attachment-0001.htm>


More information about the Github-comments mailing list