On Feb 13, 2007, at 1:29 PM, Jon Ippolito wrote:
Let's say I want to color all div tags in HTML red. I've tried variations on "entity.tag.div" in Prefs > Fonts & Colors without success. I've a basic familiarity with RegExp, and it looks like Bundle grammar supports RegExp, but I can't see where syntax coloring might be defined in the HTML Bundle either.
As an addendum to what Steve has said, the grammar is full of rules that give names to things (scopes). In the grammar, this appears as a name=... thing. You can basically target those.
In your particular case, the div is matched in the grammar in the exact same way as any other tag, so there is no way to color it separately, unless you alter the grammar.
Some doc references:
http://macromates.com/textmate/manual/ language_grammars#language_grammars http://macromates.com/textmate/manual/scope_selectors#scope_selectors http://macromates.com/textmate/manual/themes#themes
Haris