SHExBrushes

SyntaxHighlighter Extended Brushes.

Extended syntax highlighter brushes for the script SyntaxHighlighter 3 by Alex Gorbachev.
HTML5, CSS3, PHP5.5, Javascript.

Download »

Share : FacebookTweetGoogle+

Info : This brushes pack for SyntaxHighlighter 3.x by Alex Gorbatchev simply extends the original brushes for the following languages : HTML5 (XML brush), CSS3 and SASS, PHP5.5, JavaScript and SQL. I made that for my own personal use so why not share :) You will find below the list of all the improvements i've made. In general, the proposed brushes provide better visibility of the code.

Installation

Download brushes (.zip)

Extract archive (shexbrushes.zip). It contains two folders : css and js. Copy the contents of the js folder and paste it in the directory containing your brushes for SyntaxHighlighter. You should replace the original brushes if they are already present.

Additional styles

This pack of extended brushes adds new CSS classes to extend the coloring. Much of them used only to colorize HTML tags differently according to their type (list tags, form tags, ...). If you don't use the HTML brush, you can ignore this classes (*tag and *att CSS classes, from the highlighted line in the code below).
Copy and paste the content of the code below into your theme file for SyntaxHighlighter (i.e shThemeDefault.css by défault).

.syntaxhighlighter .color4, .syntaxhighlighter .color4 a {
  color: #2a8596 !important;
}
.syntaxhighlighter .color5, .syntaxhighlighter .color5 a {
  color: #f90 !important;
}
.syntaxhighlighter .spechar {
  color: #00de1f !important;
}
.syntaxhighlighter .punct {
  color: white !important;
}
.syntaxhighlighter .digit {
  color: #c86021 !important;
}
.syntaxhighlighter .function {
  color: #9f3 !important;
}
/* Below : HTML brush colors */
.syntaxhighlighter .anchortag {
  color: #9f3 !important;
}
.syntaxhighlighter .anchoratt {
  color: #00de1f !important;
}
.syntaxhighlighter .formtag {
  color: #f90 !important;
}
.syntaxhighlighter .formatt {
  color: #d98a14 !important;
}
.syntaxhighlighter .scripttag {
  color: #c02910 !important;
}
.syntaxhighlighter .scriptatt {
  color: #9e2815 !important;
}
.syntaxhighlighter .csstag {
  color: #dddd00 !important;
}
.syntaxhighlighter .cssatt {
  color: #caca19 !important;
}
.syntaxhighlighter .metatag {
  color: #dddd00 !important;
}
.syntaxhighlighter .metaatt {
  color: #caca19 !important;
}
.syntaxhighlighter .imgtag {
  color: #96f !important;
}
.syntaxhighlighter .imgatt {
  color: #8346fc !important;
}
.syntaxhighlighter .listtag {
  color: #e3de5f !important;
}
.syntaxhighlighter .listatt {
  color: #c6c25c !important;
}
.syntaxhighlighter .mediatag {
  color: #fcf !important;
}
.syntaxhighlighter .mediaatt {
  color: #f9f !important;
}
.syntaxhighlighter .tabletag {
  color: #06dec7 !important;
}
.syntaxhighlighter .tableatt {
  color: #00c4af !important;
}
.syntaxhighlighter .objtag {
  color: #3a87e7 !important;
}
.syntaxhighlighter .objatt {
  color: #2679e0 !important;
}

You may need to adjust the colors to your theme. My personal theme, used here on this site, is included in the archive (in the css folder) and does not require the addition of previous styles.

More infos

What's new ?

Below you find a list of all improvements made on the brushes in this pack.

shBrushCss.js shBrushSass.js

Updated list of CSS properties and values for CSS3 support.
Updated list of size units.
Specific coloring for the CSS @* rules.
Specific coloring for some chars : { } ( ) , ; ..

shBrushJScript.js

Updated list of reserved keywords.
Specific coloring for javascript regex.
Specific coloring for some special chars.
Specific coloring for numbers.

shBrushPhp.js

Updated list of reserved keywords, functions and constants, for full Php5.5 support.
Specific coloring for some keywords.
Specific coloring for some special chars.
Specific coloring for numbers.

shBrushXml.js

HTML : Specific coloring for tags and attributes according to their type.
Types: forms, images, anchor, lists, medias, metas, objects, scripts, style, tables.
HTML5 Support.

shBrushSql.js

Specific coloring for some special chars.
Specific coloring for numbers.

Conclusion

For any questions, don't hesitate to contact me, I will try to answer you as best I can. Maybe you've noticed, my english is not perfect. You can also contact me for any correction.

CSS properties list, JavaScript and Php keywords and functions lists, and HTML tags and attributes list, are full and up to date at October 1st 2013.

Don't hesitate to comment and share this page ;)

Credits

Changes made by Robin Calmejane (nomadOnWeb)
SyntaxHighlighter by Alex Gorbatchev

License

Like SyntaxHighlighter, this plugin is released under LGPL licence.

Share : FacebookTweetGoogle+