Hi, I use textilize() which is a great way of letting end users edit contents. But the code in RedCloth is quite compact, and doesn''t allow for easily adding correct typographic behaviour depending on the lang of the text. For instance, correct quoting uses round double quotes in english and double carons ? ? in french; the spaces before punctuation can be corrected too. I''d like to know if there is an effort somewhere to clean up a bit the RedCloth code, and add an api to hook some behaviours from ruby code. Another very similar point would be the ability to add some custom tags in textitlize, like #mycontroller/myreport# that would create a div from the myreport action of mycontroller (ie, call render_component). I can do it now with replacement before and after textilize calls, but it''s a bit heavy... -- Jean-Christophe Michel
Jean-Christophe Michel wrote: > I use textilize() which is a great way of letting end users edit > contents. But the code in RedCloth is quite compact, and doesn''t allow > for easily adding correct typographic behaviour depending on the lang > of the text. For instance, correct quoting uses round double quotes in > english and double carons ? ? in french; the spaces before punctuation > can be corrected too. I''d like to know if there is an effort somewhere > to clean up a bit the RedCloth code, and add an api to hook some > behaviours from ruby code. I dealt with a similar problem last summer while trying to devise a system that could export from Textile to HTML or plain text. What I ended up doing was writing my own object to do the Textile to whatever conversion which used Redcloth internally and repaired Redcloth output as it was generated. It''s not as clean as it could have been, but it worked really well. Composition may be your ticket. -- John Long http://wiseheartdesign.com