Prev: is there a lightweight markup language rendering engine using textwidget
Next: Help! Teacup ate my TDBC installation
From: Arndt Roger Schneider on 9 Jun 2010 05:30 Zhang Weiwu schrieb: >In some part of the program I am writing I need to display a >content-rich text by reading it from a file. By content-rich, I mean it >have title level 1 to 3, uses oblique, bold style for some text. The >original purpose is to display product description and welcome text, but >later my user make much more use of this and display a lot other text, >like, board of directors introduction. > >asciidoc would work well for my case, so does any lightweight markup >language like bbcode. HTML is a bit too complicated because my "novice" >users want to update it by themselves. So I think what I need is a >rendering engine written in tcl for a lightweight markup language. Is >there such a tool and how mature is it? > >Thanks in advance! > >P.S. My homework including reading this article which didn't give any >read-to-use products or tools but only mostly ideas, or code that was >said to be done but not published: > >A wiki-like markup language for the text widget ><http://wiki.tcl.tk/_/ref?N=3084> > >Also I checked syntax highlight library offered by tkoutline but found >two problems. > > 1. it doesn't work on tk8.5 (is okay with tk8.4), while my exiting > application made too much use of tcl/k8.5 > 2. It take some work to customize the library to display headline > etc, and not sure in case *bold* can it hide the asterisk when > making "bold" bold > >However it has the potential to be improved to an asciidoc rendering >engine, out side of my project's time scope though. > >Another homework I did is to check lightweight markup language comparison >http://en.wikipedia.org/wiki/Lightweight_markup_language >only to find none are supported by tcl. > >I checked there exist a basic HTML rendering engine: scrolledhtml ><http://wiki.tcl.tk/_/ref?N=2306> and htext ><http://wiki.tcl.tk/_/ref?N=1848> > > Your conclusion seems correct so-far. + The gridplus package appears to have some htmlish markup, too http://www.satisoft.com/tcltk/gridplus/text.html + Jeszra's code generation could also being extended to handle asciidoc import, but than the text-code generation is trivial --it hardly warrants the effort... Are you planning to use asciidoc as the front-end for a docbook toolchain? -roger |