You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is more of a question or comment than a feature request or bug report: What's the rationale for putting the cursor just before the closing bracket rather than just after, upon pressing Tab?
If I've got
foo= (|)
and press Enter to get
foo= (
|
)
and then type some elements, like
foo= (
'spam',
'ham',|
)
I would think that I am trying to get to
foo= (
'spam',
'ham',
)|
or perhaps even
foo= (
'spam',
'ham',
)
|
as simply and easily as possible, but Tab actually gets me to
foo= (
'spam',
'ham',
|)
which is probably very rarely what I want. And by that time, the closing bracket is no longer considered "automatically inserted" by VS Code, and is thus not subject to the default typeover. (Setting "editor.autoClosingOvertype": "always" could help, but some people can't stomach that option.)
I've been playing around with this a little bit, because it's close to allowing me to feel OK about letting VS Code autoclose brackets for me, but not quite there. And clearly most people don't seem to have any problem with the current VS Code behavior, with or without useTabOnHangingIndent.
The text was updated successfully, but these errors were encountered:
Not impossible to do, but it is more than a simple code change because we aren't inserting the ending bracket, we're just using textEditor.insertSnippet() to insert the newline and indentation, which restricts where we can put the cursor.
A possible work around would be to delete the bracket that exists, and insert our own, adding a $n (for some n) pointer after the bracket.
This is more of a question or comment than a feature request or bug report: What's the rationale for putting the cursor just before the closing bracket rather than just after, upon pressing Tab?
If I've got
and press Enter to get
and then type some elements, like
I would think that I am trying to get to
or perhaps even
as simply and easily as possible, but Tab actually gets me to
which is probably very rarely what I want. And by that time, the closing bracket is no longer considered "automatically inserted" by VS Code, and is thus not subject to the default typeover. (Setting
"editor.autoClosingOvertype": "always"
could help, but some people can't stomach that option.)I've been playing around with this a little bit, because it's close to allowing me to feel OK about letting VS Code autoclose brackets for me, but not quite there. And clearly most people don't seem to have any problem with the current VS Code behavior, with or without
useTabOnHangingIndent
.The text was updated successfully, but these errors were encountered: