Howdy, I’m a new user to Sublime. I’ve only been using it for a couple of days but I’m really digging how everything fits together. Currently I’m working through getting things set up (snippets, etc).
The crux of my “problem” (such as it is) is that I work with both Objective-C projects as well as C/C++ projects. I’m sure you know where this is heading (pun!); By default *.h is associated with C++, which makes the syntax coloring not look right for Objective-C. My searches and what I’ve learned about how settings work would indicate that this isn’t a setting that can be overridden on a per-project basis because it needs to exist in a file with a specific name.
However, from looking at the API reference it looks like the on_new()/on_load()/on_post_save() events might be useful along with a per-project setting that would tell them to examine the extension of the file being created/loaded/saved and, if there is an appropriate project setting, change the syntax.
Is that something that’s actually viable? If so, it seems like something that might already have been written, but so far my searches have come up empty, so any help there would be appreciated as well.