On Sun, 2009-11-29 at 18:28 +0100, Mario Blättermann wrote: > Am Sonntag, den 29.11.2009, 17:12 +0100 schrieb Matteo Settenvini: > > Il giorno dom, 29/11/2009 alle 16.42 +0100, Mario Blättermann ha > > scritto: > > > Hi, > > > I'm currently working on an upcoming manual for Kupfer. I have tried to > > > use a code block with the following content: > > > > > > <code> > > > [Kupfer] > > > keybinding = <Control>space > > > magickeybinding = <Ctrl><Alt>space > > > </code> > > > > > > But Mallard doesn't accept this construction, I get the following error > > > message: > > > > AFAIK it's not a Mallard problem, but a XML one. You've to escape the > > '<' and '>' entities when you use them literally, that is when you use > > them outside of the scope of opening and closing tags. > > > > http://www.htmlescape.net/escape_common.html > > > > Else, the parser thinks you're opening a <Control> tag, and thus checks > > for a </Control> closing tag before the </code> tag. Since it's not > > there, it bails out because that XML is malformed. > > > Thanks for pointing this out. Now it works fine, with the < and > > in place of the < and >. > > But I remember of DocBook, there we have a <![CDATA[<control><shift>]]> > construct to prevent DocBook from detecting this as native XML tags. > Shouldn't Mallard handle this similarly? Mallard aimed to be more simple > than DocBook, and should't require any HTML based stuff. The < and > > inside a code block should be correctly processed by the XSLT > stylesheet.
It doesn't require any HTML stuff. All of this is standard XML stuff. You can escape with < and >, or you can use <![CDATA[...]]>. Both are mechanisms common to XML, and both are handled by the XML parser (libxml2) before any Mallard tools even see the page contents. -- Shaun _______________________________________________ gnome-doc-list mailing list [email protected] http://mail.gnome.org/mailman/listinfo/gnome-doc-list
