This is the mail archive of the
docbook@lists.oasis-open.org
mailing list for the DocBook project.
Re: [docbook] Prosposed changes to Programlisting
- From: Tobias Reif <tobiasreif at pinkjuice dot com>
- To: Elliotte Rusty Harold <elharo at metalab dot unc dot edu>
- Cc: Steven Cogorno <steven dot cogorno at sun dot com>,docbook at lists dot oasis-open dot org
- Date: Sat, 21 Feb 2004 12:47:32 +0100
- Subject: Re: [docbook] Prosposed changes to Programlisting
- Organisation: Soul Computing for Fun and Freedom
- References: <200402181258.i1ICwDue001729@village.sfbay.sun.com> <p06010206bc5bc97ef522@[192.168.254.4]>
On Fri 2004-02-20 Elliotte Rusty Harold wrote:
> I do not find the idea of a "filecontent" element to be useful. It
> feels too generic.
It's less generic than literallayout, and conveys semantics.
> For instance, not all files contain content that should be processed
> as literallayout.
An attribute could be added allowing you to specify this, or xml:space
could perhaps be used.
> Hell, not all files can even be included in DocBook. I've recently
> been working with the XML conformance test suites and having a hell
> of a time with files that are deliberately broken by containing XML
> illegal characters such as null.
I fail to see how those two arguments counter the general usefulness
of an element "filecontent" (it's OK if it's not useful for everyone,
and does not fit in all scenarios: which XML element could possibly
make illegal characters be legal?).
programlisting and literallayout are not always appropriate:
Let's say I want to include a file snippet. It's not a program, so
programlisting is out. literallayout is an element which is
exclusively concerned with layout, which makes it a poor choice IMHO.
So we could go with something looking like one of those:
<filefragment xml:space="preserve">whitespace (WS) should probably
be preserved by default[...]
<filelisting layout="flow">WS/layout is not preserved now [...]
<documentfragment syntax="xml">[...]
<filecontent>foo[...]
Tobi
--
Vim users, don't forget to
http://iccf-holland.org/donate.html
To unsubscribe from this list, send a post to docbook-unsubscribe@lists.oasis-open.org, or visit http://www.oasis-open.org/mlmanage/.