On Oct 7, 8:08 pm, David Young <[email protected]> wrote: > When the parser is going through the text, does it search for all > matches of config.formatters[0] and replace text with the html tags, > then search the text (now with some tags) for all matches of > config.formatters[1]? I'm curious about how nesting/greediness are > handled. I think it does the parsing in one run. If you have a look at Formatter [1] it generates a very big xx|yyy|zzz regexp, to identify a starting point. If you have a look at config.formatters [2], you'll see that most of them have a "termRegExp: /(\n)/gm," which specifies the end of one recogniced block. There is also a lookaheadRegExp:
Wikification is done by the Wikifier Have a closer look at the following two functions, to see what's going on. Wikifier.prototype.subWikifyUnterm = function(output) Wikifier.prototype.subWikifyTerm = function(output,terminatorRegExp) Hope this helps. ==================== @core devs. Is there a detailed description, how tw syntax parsing is done, somewhere out there?? ==================== -mario [1] http://www.tiddlytools.com/insideTW/#Formatter [2] http://www.tiddlytools.com/insideTW/#config.formatters -- You received this message because you are subscribed to the Google Groups "TiddlyWikiDev" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/tiddlywikidev?hl=en.
