Prabir's Blog

where the tech matters...

Windows Live Writer Syntax Highlighter

July 05
by prabir 5. July 2009 21:52

Syntax highlighting technique provides the readers with more attractive and easy to read code snippets. It is one of the must have for a blog (at least for mine). In my previous article I had mentioned about how to integrate Syntax Highlighter 1.5.1 to Blog Engine .NET with help of Windows Live Writer.

Well, this article is about integrating Syntax Higlighter 2.0 Windows Live Writer Plugin(I will be posting another article soon on integrating Syntax Higlighter 2.0 with Blog Engine You can find the article on integrating with blog engine out here). I actually went up searching for syntax highlighter 2.0 plugin support for Windows Live Writer but couldn’t a suitable one. I landed up writing my own plugin. This plugin is based on the modification of a plugin written in VB which can be found at http://wlwsyntaxhighlighter.codeplex.com. (My version of the plugin is written in C#).

You can either download the setup file and install or do it manually. For manual installation you will need to download the zip file at the end of this post and extract the .dll file to C:\Program Files\Windows Live\Writer\Plugins folder. (Please you appropriate destination where your Windows Live Writer is installed.) Next time when you start Windows Live Writer the plugin will automatically be loaded. Click on Syntax Higlighter… to insert you code. To uninstall the plugin make sure Windows Live Writer is not running and delete Prabir.wlw.Syntaxhiglighter.dll from Plugins folder.

image

A new dialog will open where you can choose your language and type the code. In the Language drop down box you can type your custom language even if it is not in the drop down box but make sure you also upload appropriate js scripts to your website to support the language.

image Since it makes use of Smart Content Editor you can later on edit your code using the menu at the right. Since this plugin is still under development. Most of the features are disabled. As of now some of the features that were disabled have been enabled.

 

image

I would also recommend you to read my article on integrating Syntax Higlighter 2.0 with Blog Engine.NET.

You can download the source code along with the latest setup from the codeplex website at http://codehighlighter.codeplex.com/

Prabir.wlw.Syntaxhiglighter.dll.zip (38.40 kb) [Downloads: 130]
Prabir.wlw.SyntaxHiglighter.msi (Setup) (360.00 kb) [Downloads: 184]

Get from Windows Live Gallery


Share/Save/Bookmark Subscribe

Tags: ,

Blog | BlogEngine.NET

Comments

7/5/2009 9:55:13 PM #

trackback

Windows Live Writer Syntax Highlighter

You've been kicked (a good thing) - Trackback from DotNetKicks.com

DotNetKicks.com

7/5/2009 9:57:50 PM #

trackback

Prabir's Blog | Windows Live Writer Syntax Highlighter

Thank you for submitting this cool story - Trackback from DotNetShoutout

DotNetShoutout

7/6/2009 12:16:17 PM #

trackback

Подсветка синтаксиса в Windows Live Writer

Thank you for submitting this cool story - Trackback from progg.ru

progg.ru

7/6/2009 8:44:48 PM #

trackback

Prabir's Blog | Windows Live Writer Syntax Highlighter

Prabir's Blog | Windows Live Writer Syntax Highlighter

Dash Technical Notes

7/12/2009 5:01:18 AM #

Antoine Gemis

Thanks for sharing. This is usefull.

Antoine Gemis France

7/23/2009 3:34:44 AM #

trackback

Prabir's Blog | Windows Live Writer Syntax Highlighter

DotNetBurner - burning hot .net content

DotNetBurner - Tips & Tricks

8/25/2009 6:50:16 PM #

吴鹏(AlphaWu)

Thanks for your share.

吴鹏(AlphaWu) People's Republic of China

9/13/2009 12:12:59 AM #

prabirshrestha

source code of this windows live writer plugin have been released at http://synatxhiglighter.codeplex.com

prabirshrestha Nepal

9/28/2009 11:19:26 PM #

Annuities

Cool tool. i like it.

Annuities United States

11/5/2009 2:15:14 AM #

trackback

Installing BlogEngine.NET on GoDaddy

Installing BlogEngine.NET on GoDaddy

GetYourFix()

11/19/2009 4:52:24 AM #

waggi

Great post.

waggi United States

11/24/2009 11:19:18 AM #

Yachika Verma

Thanks for great info. I will visit your blog for more interesting posts like this.

Yachika Verma India

12/6/2009 11:10:37 PM #

prabirshrestha

Version 0.2 for syntax higlighter have been released at blog.prabir.me/.../...ive-Writer-v02-released.aspx

prabirshrestha Nepal

12/7/2009 6:31:26 PM #

seoul girls

nice template and great article.thanks this is great information

seoul girls United States

12/19/2009 10:56:52 AM #

miracle cabbage soup diet

Hi nice to read this I realy like to



Regards
Rawls


miracle cabbage soup diet United States

12/19/2009 12:21:17 PM #

miracle cabbage soup diet

wanted to thank you for this great read!! I definitely enjoying every little bit of it I have you bookmarked to check out new stuff you post


Regards
Edwards







miracle cabbage soup diet United States

12/20/2009 12:27:48 AM #

article directory

For manual installation you will need to download the zip file at the end of this post and extract the .dll file to C:\Program Files\Windows Live\Writer\Plugins folder.

article directory United Kingdom

12/22/2009 5:40:01 PM #

Straight Razors

I value your discussing this with us. I enjoy studying about a subject that I'm passionate about. Please update your web site when you know more. This has aided me a large amount. Thanks.

Straight Razors United States

12/31/2009 3:00:36 PM #

trackback

Best of 2009

Best of 2009

Prabir's Blog

blog comments powered by Disqus