Syntax Highlighter module

Oct 17, 2010 at 9:45 AM

You can find first revision of Syntax Highlighter module from It currently only includes C# and JScript brushes but it should be very easy to add the rest. I'm investigating how to use the shAutoloader to do the actual loading of the brushes to make the experience bit better if the future versions.

Note that it is built against the latest dev branch version of Orchard and DOES NOT work with the 0.5 release.

Oct 17, 2010 at 3:41 PM

It might be interesting to provide a Settings section with your module so that users can checkbox the scripts they want to include in the output. Might even be interesting to uncheck eveything so that users can include the appropriates resources in their specific templates if they want, instead of having them rendered on every pages.

And it would make an excellent module in the gallery. You could also create a CodePlex project to host it, and provide some documentation.

Can I also suggest you to follow our coding syntax conventions ?

Oct 18, 2010 at 11:37 AM

Yes that is the plan. I think that if I get the autoloader working with orchard the configuration becomes obsolete as it loads the required scripts on demand. I've already created a codeplex project for it and will publish it as soon as I've cleaned up the code according to Orchard "standards".

ps. I understand that you use opening bracket on same line as the "definition" because of javascript "standards" but still it makes my eyes hurt and causes my brain to freeze while looking at it :D

Oct 18, 2010 at 5:42 PM

Module is now published at

Oct 19, 2010 at 12:41 PM

How do I get the module published to Orchard gallery? Does the gallery support pre-release versions? Like if I stamp my module to require OrchardVersion: 0.8 alpha or something it would be only possibly to install it to current dev branch version.

Oct 19, 2010 at 2:30 PM

As of 0.8 release the feed will be upgraded to have only compatible modules. You can already prepare your package an test it using this documentation:

You will need an account for that. Bradley Milignton is taking care of that currently. I will ask how he wants to be contacted.

Oct 19, 2010 at 8:51 PM
Edited Oct 19, 2010 at 8:54 PM

I have released a new version which uses autoloader script to dynamically load used brushes. This greatly extends list of highlighted languages. Full list updated at the front page of the home page.

Oct 19, 2010 at 9:10 PM


Oct 20, 2010 at 7:43 AM

It would be great to see this added to the Orchard gallery feed.  Pick a password for the gallery and send me the hash code in email.<pick a password>

Oct 21, 2010 at 4:08 PM

Finally it is available from Orchard Gallery. I'm still releasing pre-build packages at the homepage just in case someone needs them. I recommend you install it from the gallery.

Oct 21, 2010 at 5:38 PM

Fantastic! Thanks!

Oct 21, 2010 at 5:44 PM

I've also written a short tutorial of my module development setup. You can read it from Orchard module development setup

Dec 26, 2010 at 6:12 AM

Hi there,


maybe i missing something but i have the latest 0.9 installed and go to the control panel, Gallery, Modules and don't see the Syntax highlighter ??



Dec 26, 2010 at 6:58 AM

Modules need to be republished in the new gallery after they've been verified for the new version. It's up to the authors of each module to do so.

Dec 26, 2010 at 4:37 PM

Thanks Bertrand

Dec 27, 2010 at 7:46 AM

I havent gotten around checking the latest version of Orchard yet. I'll be traveling today so I'll try updating the Syntax Highlighter to latest version tomorrow.

Dec 27, 2010 at 8:48 AM

Great stuff! thanks!  I would love to take a look at as well to see how it was done... I am trying some modules too..


But i think the syntax highlighter would be a great asset to my blog ... thanks

Dec 28, 2010 at 8:14 PM

I've finished testing and updating the syntax highlighter to work with latest 0.9.x version of Orchard. I've published the latest version to Orchard Gallery:

You should be able to install it directly from the Gallery feature of Orchard.

If you want to take a look at the sources you can find them from All contributions are welcome!