This sounds like a silly nit-picky thing, but actually from a usability standpoint it's kind of huge. I've had more users stymied by this than I can count. They see the help text saying "brush: LANG" and so they put "brush: PHP" or "brush: JAVA". But the brush only works with lowercase declarations. Even if they see the available languages block with a list of what they can put, they'll still try to put it in upper- or mixed-case because of the help message.
Two solutions:
1. The simple one: update the help text to say "brush: lang", which I did and it seems to have helped a fair bit
2. Make the brush case-insensitive. This is a better solution, imo, from an elegance standpoint, but a lot more work. :)
Comments
Comment #1
mattyoung commented>1. The simple one: update the help text to say "brush: lang", which I did and it seems to have helped a fair bit
Even "brush: lang" can be confusing. To be totally clear, we will have to say "brush: lang, where lang is one of as3,bash,cpp,....,xml", something like that.
>2. Make the brush case-insensitive. This is a better solution, imo, from an elegance standpoint, but a lot more work. :)
To make this happen, you can make a feature request at https://github.com/alexgorbatchev/SyntaxHighlighter
Comment #2
Renee S commentedFeature request made. I like the idea of expanding the help text a bit more: extra help is always better than not enough.
Comment #3
mattyoung commentedI changed the filter tip to:
Syntax highlight code surrounded by the <pre class="brush: lang">...</pre> tags, where lang is one of the following language brushes: as3, applescript, bash, powershell, scala, sql, vb.
The list of brush names change depend on what language are enabled in the admin page.
It's quite verbose but this hopefully will eliminate any confusion.
Comment #4
fizk commentedComment #4.0
fizk commentedgrammar