laurentj/wikirenderer — pull request #1 by Amaury (2012-12-29 21:44:04+00:00)
Title: PSR-* compliancy

I did a refactoring of WikiRenderer, to make it compliant with PSR-0 and PSR-2 (it followed the PSR-1 rules already).

* **PSR-0**: Everything is placed in a "\WikiRenderer" namespace. Each class has its own file. Hence the need to use an autoloader mechanism. Rules for wiki processing are placed in a "\WikiRenderer\Markup" namespace.
* **PSR-2**: The code was slightly rewritten to be normalized.

I renamed the "src" directory to "lib".
I rewrote the code which translates WR3 wiki language to HTML, DocBook and text. As long as they are not rewritten too, other syntaxes (classicwr, dokuwiki, jwiki, trac) will not work anymore.

I did another modification in the \WikiRenderer\Renderer object. It's constructor accepts only a \WikiRenderer\Config object as a parameter, or a NULL value (or no parameter at all). If nothing is given, the «WR3 to xHTML» syntax is still loaded by default. But I removed to possibility to give a string; I think it doesn't make sense (it works only with the syntaxes bundled in WikiRenderer, not with third-parties syntaxes).