how editor.autoClosingOvertype works in vscode settings - visual-studio-code

can anyone show me how editor.autoClosingOvertype works in vscode settings? thank you very much

Overtype mode allows you to type the SAME character as the next character and NOT have that same character added again but act as if you typed the same character on top of that already existing character.
It is used by people who want to keep their hands on the keyboard and simply type the next character to get PAST it. It can be much faster to simply type the next character if you want to get past it (rather than right-arrowing past it) but you don't want two of those characters.
In this case you asked about overtyping and the editor.autoClosingOvertype which applies to quotes or brackets. There are three options for that setting.
never means when you type the quote or closing bracket (when you are right before it) - it is NOT typed over and another quote or closing bracket is simply added where you typed it.
always means always overtype that next closing quote or bracket no matter how it might have been inserted in the first place. Sometimes those quotes/brackets were added automatically by the vscode language server and sometimes by another method (like a snippet).
auto - the default will overtype that next closing quote or bracket only when it was automatically added by the vscode language server and not when it was added by any other means.

Related

vs code expand selection doesn't respect word separators setting

When I run the command "Expand Selection" with my cursor in a kebab-case-word-like-this, I want it to select the whole word including the dashes, but it breaks at the dash, even though my configured "Editor: Word Separators" (editor.wordSeparators) does not include dash (it's unchanged from the default). Any way to make it select the entire thing on the first expansion? Kebab case is the convention for clojure and this glitch makes it really tedious. It seems that deleteWordLeft and deleteWordRight also don't respect editor.wordSeparators.

VS Code editor places cursor after commas/quotations

When I type a single comma or quotation mark in VS Code editor, the editor automatically adds a second one, which is OK, but than it places the cursor outside right after the commas, so if I need to write something between the commas (Which is normally the case...) I need to move the cursor back between the commas.
I would like to change this behavior and place the cursor automatically between commas or quotations.
Does anyone have an idea?

Sublime Text 2 how to wrap selection with quotes/auto-pairing

I just switched from Textmate 2 to Sublime Text 2. I figured that typing single quotes or brackets would automatically generate a second quote or bracket with the cursor in between ("auto-pairing" is what they call it, Textmate2 does this by default) but this isn't happening.
I see that in the preferences->settings-Default there is some JSON configuration that would seem to be doing what I need but this is not the case. I haven't changed any of this default configuration.
Could someone help me add to my preferences->settings-User the configuration I need to enable auto-pairing for all the common tags, i.e., "'{[(?
Right now I'm working on a client's laptop and running Sublime Text 2 portable version from my flash drive. No additional packages installed, default settings. Everything works as expected:
When I type a single or double quote, brackets, square or curly brackets it adds a closing one and puts cursor in the middle.
When I select smth and press any of mentioned above keys it surrounds selection with pair of appropriate quotes or brackets.
Check your Settings>Default, look for this:
// Controls auto pairing of quotes, brackets etc
"auto_match_enabled": true,
It's near line 89 or so.
Not a direct answer to your question..but I have installed a few plugins in ST2 and auto-pairing works fine.
I am not sure which plugin is responsible for it. Let me know if you would like me to share the list of plugins.

Is there a way to make content assist in Eclipse (JDT) show up automatically after I type "new"?

Most of the time after typing "new" I press Ctrl-space to quickly choose the necessary class. I want Eclipse to show the tooltip automatically, like VS+Resharper does.
If you do not have any hesitation in typing a single whitespace, you can add the whitespace character to the list of characters that will trigger the content assist dialog. The default character is the dot (.) character, to which you can add other characters.
I haven't found a way to avoid specifying any trigger character, and still get the content assist dialog. So, with the whitespace character in the list, you have to type in new instead of just new, and you can get what you desire (or more than what you need, as the dialog pops up on every space entered).

Hungry Backspace in Eclipse?

In some editors there exist plugins implementing a feature called "hungry backspace" or "hungry delete".
If this mode is active in a text editor then one hit to the backspace key will automatically delete all whitespace chars backwards from the current cursor position up to the first non-whitespace character.
For example, this feature exists for Emacs and IntelliJ IDEA.
Does anyone know if it is also available in Eclipse?
Alt-Del is probably as close as you're going to get without writing a plugin yourself. Others have asked for this feature (coming from intelliJ) but so far it doesn't exist, or it's not published.
-Adam
CTRL-backspace is pretty close too: delete previous word:
function(); (4 spaces)
+ CTRL-BACKSPACE gives:
function
Other than that, AnyEdit plugin can convert trailing spaces into tabs (but also into "", effectively removing them)
Ctrl+Shift+Left, Backspace always works for me. works in notepad, web browsers, everywhere.
Stick to the standards :)
In SciTE, and Eclipse (3.4), Ctrl+Shift+Del with the caret after the last visible character will delete these spaces. Ie. it deletes from caret to end of line.
Actually, in SciTE I don't need to do that, since I have set it up to automatically remove these trailing spaces when saving.
Note: In Preferences > General > Keys, there is a Remove Trailing Whitespace binding (without key assignment by default) which seems to apply to File.
From eclipse Windows menu/Preferences
Search for Keys and filter to "Delete Previous Word"and Bind it to the Ctrl+Backspace