This isn't necessarily a plugin question, but this still seems like the most appropriate forum. I've noticed some languages, like Python, include rules for automatically indenting to the proper level when adding a newline. For example:
- Code: Select all
def foo():<press enter>
| # <-- cursor automatically indented to |
I've skimmed the Python.tmLanguage file, assuming that's where rules like this are defined, but haven't had any luck figuring out exactly what's doing this. I'd like to implement similar smart indentation to HTML, so that when someone types <div> followed by a newline, the cursor is positioned one level beyond the "<".
Any help would be appreciated. Thanks!