Home Download Buy Blog Forum Support

Color Scheme Syntax

Color Scheme Syntax

Postby mattbolt on Wed Jan 09, 2013 7:03 am

Is there any reference anywhere as to what scopes SublimeText2 will respond to when making your own theme? It's driving me nuts trying to stumble across valid syntax by looking at other peoples schemes or by trial and error.
mattbolt
 
Posts: 2
Joined: Wed Jan 09, 2013 3:34 am

Re: Color Scheme Syntax

Postby iamntz on Wed Jan 09, 2013 7:13 am

You could just read a little on how textmate themes are working:

http://manual.macromates.com/en/themes
http://blog.macromates.com/2006/creating-themes/

Also, ctrl+alt+shift+p keyboard might be helpful: http://img.iamntz.com/jing/2013-01-09_08h53_13.png
iamntz
 
Posts: 819
Joined: Fri Apr 29, 2011 8:52 am
Location: Romania

Re: Color Scheme Syntax

Postby mattbolt on Wed Jan 09, 2013 9:12 am

Thanks,

I'll take a look at those. I have tried installing plugins like ScopeHunter etc. But for things like bracket matching or built in high level scope names, they don't seem to report those, I get those crazy long scopes that are specific to a language. Would be nice if Jon could throw together some documentation on what high level scopes he has implemented in the engine.

- Matt
mattbolt
 
Posts: 2
Joined: Wed Jan 09, 2013 3:34 am

Re: Color Scheme Syntax

Postby quodlibet on Sun Jan 13, 2013 12:47 pm

The scopes are determined by the syntax. You may find it helpful to have a look at the .tmLanguage files of any languages you are working with.

Also, in case you haven't worked it out yet, themes cascade -- like CSS. So make sure you cover all the basic categories (string, keyword, variable, constant, etc.) as defined in the TextMate docs: http://manual.macromates.com/en/languag ... onventions

Hope this helps,
Alex
quodlibet
 
Posts: 460
Joined: Sat Jun 18, 2011 5:53 pm


Return to General Discussion

Who is online

Users browsing this forum: Exabot [Bot] and 9 guests

cron