comp.lang.ada
 help / color / mirror / Atom feed
From: Simon Wright <simon@pushface.org>
Subject: Re: SVG Doctype using xmlada
Date: Wed, 01 May 2019 16:10:46 +0100
Date: 2019-05-01T16:10:46+01:00	[thread overview]
Message-ID: <ly1s1imcqx.fsf@pushface.org> (raw)
In-Reply-To: af7fbcf0-e0b5-4753-98e1-8176e55e1b61@googlegroups.com

Bob Goddard <1963bib@googlemail.com> writes:

> I think what it is, is that xmlada produces a null document type, as
> the meaningful header(s) are/is:
> <?xml version="1.0"?>
>
>
> whereas I need headers similar to:
> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN"
> "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
>
> I assume I have to copy & extend all the DOM core document files & mod
> the private type DOM_Implementation.

I'm using commit f4a8216 (the latest) from
https://github.com/AdaCore/xmlada.

Using

   DOM.Core.Nodes.Print (Doc,
                         Print_Comments => True,
                         Print_XML_PI   => True,
                         EOL_Sequence   => "");

I get <?xml version="1.0" encoding="utf-8"?>; output at
dom-core-nodes.adb:1436.

Are you sure you need standalone="no"?
https://www.quora.com/What-does-Xml-version-1-0-encoding-utf-8-standalone-yes-mean
says it could be left out with the same effect.

I think for the DOCTYPE you'd implement
DOM.Core.Document_Types.Create_Document_Type, which currently returns
null, and again you'd need to modify DOM.Core.Nodes.Write (:1450).

That's just a quick look ...


  reply	other threads:[~2019-05-01 15:10 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-01  9:34 SVG Doctype using xmlada Bob Goddard
2019-05-01 12:38 ` Simon Wright
2019-05-01 13:06   ` Bob Goddard
2019-05-01 15:10     ` Simon Wright [this message]
2019-05-01 17:48       ` Bob Goddard
2019-05-01 13:01 ` Olivier Henley
2019-05-01 13:07   ` Bob Goddard
2019-05-01 13:08 ` Shark8
2019-05-02  4:40 ` gautier_niouzes
2019-05-02 20:24   ` Bob Goddard
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox