jump to navigation
Le Petit
Support EFF

Freedom of Speech

Human Rights

petikr Badge
A petikr badge showing public photos from Clas le Petit. Make your own badge here .

Syntax Highlighter Plugin Thursday 2009-02-26

This is an experimental post, to test if the syntax highlighter plugin wp-synhighlight really works.
In my first attempt I just dropped the plugin into the plugins directory and here I’m going to add some Actionscript code:
[codesyntax lang="actionscript3"]public Class Nuts()
{
var none:NoOne;
// Initiate this class
public function Nuts()
{
none = new noOne();
}
}
[/codesyntax]

Comments»

a gravatar Petit writes on
Thursday 2009-02-26

Oooh! Pretty nice and straight forward. I could write the code within sqaure bracketed tags adding the language to highlight, and could do that directly in WYSIWYG editor without bothering about html markup.
Notably, this code snippet can collapse and expand :)
No I have to change the colors and other visual stuff to what I like. ( This of course you will not see )

a gravatar Petit writes on
Thursday 2009-02-26

However :(
By default it uses inline styles, that are hard to come by – probably hiding in some php code. I’d certainly prefer CSS classes and an external stylesheet.
As it is, the produced code is unreadable, if you have to go on the backside of things. It is also *very* verbose, inlining all CSS – bah!

a gravatar Welcome/Välkommen Petit