Allan Socks
Allan Socks

Reputation: 271

Why does sublime text editor 3 autocomplete when I press return?

When I am working in sublime text when I press "enter/return" a highlighted blue autocomplete section appears that reads:

div> (element)

And if I hit enter a snippet of "div>" appears, which is utterly annoying and useless. Now, I know about snippets, etc...and how to create them, but I have not created any snippets that are set to autocomplete when I press enter (and I don't know how to for that matter), but this is just annoying. Imagine editing your php and you keep getting this piece of code:

div> ~then you hit enter and the autocomplete shows up and...
div> ~then you hit again...and
div> ~kind of annoying right?

That's where I'm at. I originally thought it was a snippet I created by accident but it isn't. I removed all my snippets and the feature is still here as annoying as ever. Any ideas on what this might be? It autocompletes when I hit enter/return. Is this some feature of sublime text 3? What could this be?

Upvotes: 3

Views: 461

Answers (1)

MattDMo
MattDMo

Reputation: 102852

This is the default behavior in Sublime Text 3. To change it, open your user preferences (Preferences -> Settings-User) and add the following:

"auto_complete_commit_on_tab": true

Save the file, and now you'll only select the current autocomplete option when hitting Tab. Also, remember that you can close the autocomplete dialog by just hitting Esc.

Upvotes: 3

Related Questions