Basically, I want to make a variant of Markdown which has it's own settings and file extension, and later it'll have it's own language file. I've tried creating a package, but it doesn't add anything to the list of file types in the bottom-right corner. Is this master-list of languages extensible?

You can download existing ones from http://code.google.com/p/tmbundles4win/, the only caveat being that the files must have a .tmLanguage extension. Some already do, others have to be renamed from .plist to .tmLanguage to be recognised.

It's worth noting that sublime uses Apple's byzantine propertly-list-in-xml format, which is equivalent to what you see in the above documentation, but more verbose.

Any syntax definition that has file extensions associated with it appears as a selectable option, so if you make sure you have:

Anyone out there trying this, you'll find yourself restarting sublime A LOT. If you have python installed, you can run this script; it'll create a new instance of Sublime every time you close. Very useful for reloading those .tmLanguage files.

There's the API function extractScope, which will return the extents of a given region. However, in terms of extracting an AST of the buffer, it's not great - it doesn't descend into children. e.g, if you give it a point in a string, it'll give you the extents of the string, but it won't notify you of any escaped characters, interpolated code etc contained within the string.

There's no reason the full tree structure of the buffer couldn't be exposed though.

There's also a stand alone TM syntax parser, which may be of interest: