ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Simon Pepping <spepping@scaprea.hobby.nl>
Subject: Re: XML and empty line (DocBook)
Date: Sat, 3 Aug 2002 17:22:13 +0200	[thread overview]
Message-ID: <20020803172213.A751@scaprea> (raw)
In-Reply-To: <20020731214300.A13643@scaprea>; from spepping@scaprea.hobby.nl on Wed, Jul 31, 2002 at 09:43:00PM +0200

On Wed, Jul 31, 2002 at 09:43:00PM +0200, Simon Pepping wrote:
> On Mon, Jul 29, 2002 at 09:58:35PM +0200, Tobias Burnus wrote:
> > Hi,
> > 
> > Using 2002.7.12 I found the problem that
> > 
> >      <title>Apache
> >      <filename>mod_rewrite</filename>
> > 
> >      magic</title>
> > 
> > causes the problem with the empty line ( = \par ) any idea how to prevent
> > this problem (except by editing the XML source)?
> >   ! Paragraph ended before \XMLDBdotitle was complete.
> >   <to be read again>
> >                      \par
> 
> Even in XML mode two blank lines generate a \par. I cannot solve this;
> perhaps Hans knows a way out.
> 
> Both this and your previous problem (and Michael's answer to it) show
> that TeX has no knowledge of ignorable white space. It cannot, because
> it does not know the DTD. (Ignorable white space is all white space in
> elements that do not have mixed content.)
> 
> > Addionally I get frequently a ']¿' at the beginning of my documents.
> 
> I believe this is another parsing problem with the internal DTD
> set. (AFAIK you should get '¿]' from '>]' in the document.

Perhaps it is better not to require that an XML parser in TeX can do
all these features right. It must be possible to rewrite the XML file
as a 'normalized' file and submit that to the TeX parser. For example,
it is possible to write a ContentHandler for a validating SAX parser
that removes ignorable white space. Perhaps the same is possible with
an XSLT script, but I am not sure if any XSLT processor does a
validating parse. Such a procedure would get rid of ignorable white
space, and it would resolve entities, thus making the work of a TeX
parser much easier.

Regards, Simon

-- 
Simon Pepping
email: spepping@scaprea.hobby.nl


  parent reply	other threads:[~2002-08-03 15:22 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-07-29 19:58 Tobias Burnus
2002-07-31 19:43 ` Simon Pepping
2002-07-31 21:21   ` Michael Wiedmann
2002-08-01  7:14     ` Hans Hagen
2002-08-01 19:07       ` Simon Pepping
2002-08-03 15:22   ` Simon Pepping [this message]
2002-08-04 21:59     ` Hans Hagen
     [not found] <Pine.LNX.4.44.0207292143240.13525-100000@warp9.physik.fu-b erlin.de>
2002-07-30  9:26 ` Hans Hagen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20020803172213.A751@scaprea \
    --to=spepping@scaprea.hobby.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).