Community
Participate
Working Groups
0.3 RC2 I tried writing a simple syntax highlighting grammary for ruby. It worked, but because we only define a very minimal CSS theme, most of it appeared not to work. I think we should provide default theme styles for the most basic grammar structures. Otherwise anyone attempting to write a grammar is likely to be frustrated as it won't appear to work. Note that we have bug 347493 that tracks allowing plugins to contribute CSS. I'm suggesting we add a few extra CSS classes in 0.3 so people can write minimal syntax highlighters. TextMate defines a reasonably small set of top-level groups, and I suggest we define a default style for each of these: comment constant entity invalid keyword markup meta storage string support variable I see these are already stubbed in default-theme.css but currently commented out.
I agree, this should be part of the polish work for RC3.
According to the TextMate docs, "support" is quite abstract, so I'm not sure a default style is appropriate there. Here's the change, on a topic branch: http://git.eclipse.org/c/orion/org.eclipse.orion.client.git/commit/?h=bug360967&id=a34fcf5a47669e793c61f6d80b105122495a67e4 In a few places I used specialized rules to avoid styling very different constructs the same way. For example "keyword" affects both keyword.control (if, while) and keyword.operator (&&, ||) which normally we don't want to look the same.
x
I'm fine with this, and as an aside I like this direction where there are "well-known" and documented style names and am still pretty against injecting arbitrary CSS.
Looks good to me. Your defaults look reasonable. I tried with my toy ruby syntax highlighter and it worked well. I also checked that our HTML files still highlight nicely.
pushed to master http://git.eclipse.org/c/orion/org.eclipse.orion.client.git/commit/?id=128671b76b6ef5cec1a5ef3803854f36bfe54eeb