quetzai / wikimodel

Automatically exported from code.google.com/p/wikimodel
0 stars 0 forks source link

[PATCH] Enhance MediaWikiScanner for attributes per table cell #187

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
The current MediaWikiScanner doesn't support attribute on table cells.
Each table cell is allowed to contain style attributes.
Quote from MediaWiki syntax page
<cite>
...
# XHTML attributes. Each mark, except table end, optionally accepts one or more 
XHTML attributes. Attributes must be on the same line as the mark. Separate 
attributes from each other with a single space.
 * Cells and caption (| or ||, ! or !!, and |+) hold content. So separate any attributes from content with a single pipe (|). Cell content may follow on same line or on following lines.
 * Table and row marks ({| and |-) do not directly hold content. Do not add pipe (|) after their optional attributes. If you erroneously add a pipe after attributes for the table mark or row mark the parser will delete it and your final attribute if it was touching the erroneous pipe!
...
</cite>

The attached patch adds the logic to the parser, that attributes
are handled and related serializers are able to handle such attributes
as WikiParams. JUnit-Test included.

Original issue reported on code.google.com by mki...@portolancs.com on 30 Jul 2010 at 1:42

GoogleCodeExporter commented 8 years ago
Patch was not correct, reworking it and will upload soon ....

Original comment by mki...@portolancs.com on 30 Jul 2010 at 3:17

GoogleCodeExporter commented 8 years ago
I've got headache from this JavaCC stuff ... I would be glad, if someone would 
contact me, that we could work together on this .JJ definitions ...

Original comment by mki...@portolancs.com on 30 Jul 2010 at 3:50

GoogleCodeExporter commented 8 years ago

Original comment by thomas.m...@gmail.com on 29 Sep 2010 at 1:50