maven-doxia-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Juan F. Codagnone" <juan-o...@zauber.com.ar>
Subject Re: Twiki Module Enhancements
Date Sat, 24 May 2008 20:58:53 GMT

Abhijit,

I am really glad to hear that you guys at Yahoo are using and
contribuiting to the twiki module.

On Friday 23 May 2008, Abhijit Bagri wrote:
...
> 2. Since toc needed the whole doc source to be supplied, I had to modify
> ByLineSource implementation to have the entire source. Since changing
> the whole line based implementation was taknig too much, I just emulated
> whole source reading and supporting the getLine method in the new
> implementation.

Couldn't be the TOC be generated transversing the block tree returned by the 
parser?

> 3. Enable linking of wiki words.
>
> Earlier a [[MyWikiWord]] would get likned to ./MyWikiWord. I am not sure
> why it was this way. Some light on this? I needed it to point it to
> ./MyWikiWord.html to be useful. Similarly for linking up wikiwords in
> [[][]].

This was fixed in http://jira.codehaus.org/browse/DOXIA-194.  

I just added a test to my working copy in the file 
http://svn.apache.org/repos/asf/maven/doxia/doxia/trunk/doxia-modules/doxia-module-twiki/src/test/java/org/apache/maven/doxia/module/twiki/parser/WordsTest.java
(where the test cases for WikiWords links lives) and i get ./MyWikiWord.html.

    public void testHtml() throws ParseException  
    {
        final StringWriter sw = new StringWriter();
        final Sink sink = new XhtmlBaseSink(sw);
        twikiParser.parse("[[MyWikiWord]]", sink);
        assertEquals("<p><a href=\"./MyWikiWord.html\">MyWikiWord</a></p>",
                 sw.toString());
    }

The links are generated by the strategy WikiWordLinkResolver and can be 
replaced.

...

> 5. Enabling verbatim and blockquote. verbatim did not seem to work
> properly for me.

verbatim worked well on our pages, but i think it can be more bulletproof and 
more general.  Don't forget to add the broken cases for regression in:

http://svn.apache.org/repos/asf/maven/doxia/doxia/trunk/doxia-modules/doxia-module-twiki/src/test/java/org/apache/maven/doxia/module/twiki/parser/VerbatimTest.java


I wrote most of the twiki module code, so do not hesitate to send me especific 
questions.

Regards, 
  Juan.

-- 
Buenos Aires, Argentina                             19°C with winds at 0 km/h
http://www.zauber.com.ar/                           http://juan.zauber.com.ar/

Mime
View raw message