This is the mail archive of the
docbook-apps@lists.oasis-open.org
mailing list .
Re: pernicious mixed content
- From: Bob Stayton <bobs at caldera dot com>
- To: docbook-apps at lists dot oasis-open dot org
- Date: Sat, 20 Apr 2002 18:42:12 -0700
- Subject: Re: DOCBOOK-APPS: pernicious mixed content
- References: <20020420110140.GA2581@gantek.com>
On Sat, Apr 20, 2002 at 02:01:59PM +0300, Baurjan Ismagulov wrote:
> Hello,
>
> I've encountered a listitem indentation problem discussed in TDG
> (html/entry.html) and the following threads:
>
> http://sources.redhat.com/ml/docbook-apps/2001-q3/msg00858.html
> http://sources.redhat.com/ml/docbook-apps/2001-q4/msg00041.html
>
> I understand that any block element should immediately follow listitem,
> otherwise the parser would treat the listitem contents as inline.
>
> I use para within listitem. What I can't understand is, why white space
> in para is significant within listitem, and not significant otherwise.
> In other words, why the following construction produces leading space
> on the first line:
>
> <listitem><para>
> Text.
> </para></listitem>
>
> and the following do not:
>
> <listitem><para>
> Text.
> </para></listitem>
>
> <para>
> Text.
> </para>
>
The content model for <para> includes #PCDATA, which means
any white space is significant. The stylesheet should pass
any white space through to the output.
What happens to the white space then depends on the
viewing application. How are you processing your
content? HTML browsers have their own
idea of how to display whitespace. If you are generating
HTML, can you tell if the whitespace is getting through
in both cases 1 and 3 above? I don't see either
of those spaces in my browser when I process your example
but the white space is in the HTML.
--
Bob Stayton 400 Encinal Street
Publications Architect Santa Cruz, CA 95060
Technical Publications voice: (831) 427-7796
Caldera International, Inc. fax: (831) 429-1887
email: bobs@caldera.com