bug-texinfo
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: XML output and &latex; entity undefined


From: Per Bothner
Subject: Re: XML output and &latex; entity undefined
Date: Fri, 5 Feb 2016 17:30:38 -0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0



On 02/05/2016 04:50 PM, Karl Berry wrote:
     I believe that it does not follow the uri in the document DOCTYPE
     definition

Well, evidently not, since
http://www.gnu.org/software/texinfo/dtd/6.0/texinfo.dtd is found just
fine when visited directly.  Unless there is an error in the dtd
preventing it from being applied, which is certainly possible.

     but rather looks in the system catalog for DTDs, but
     that's a wild guess.

Hmm, I just don't get it.  Then no document could ever specify its own
dtd, but that's the whole point of having dtd's in the first place!

In any event, the full line being output is, as we've always done:
<!DOCTYPE texinfo PUBLIC "-//GNU//DTD TexinfoML V6.0//EN" 
"http://www.gnu.org/software/texinfo/dtd/6.0/texinfo.dtd";>

Maybe there is some other magical stuff that needs to go in there to
make it be effective.  Too many standards ... -k

Depending on an external dtd seems a bad idea.
See the note here about XHTML:
https://www.w3.org/TR/html5/the-xhtml-syntax.html#the-xhtml-syntax

Loading an external DTD is also a performance loser, not to mention
risking timeouts.  Which is why I suspect browsers don't do it.

What is the use case for --xml format?  I'd drop it in favor of --xhtml,
where --xhtml is the same as --html except strictly XML compatible - with
no required DTDs or entity definitions.

For @TeX{} and @LaTeX{}, we could generate something information-preserving,
such as:
<span special="LaTeX">L<sup>a</sup>T<sub>e</sub>X</span>
and
<span special="TeX">T<sub>e</sub>X</span>

An XML post-processor for texinfo can look for the XSL/XPath pattern 
/address@hidden"TeX"]
or the CSS pattern span[special="LaTeX"].

A style based on:
http://stackoverflow.com/questions/8160514/is-there-css-for-typesetting-the-latex-logo-in-html

span[special="TeX"] sub, span[special="LaTeX"] sub, span[special="LaTeX"] sup {
  text-transform: uppercase;
}

span[special="TeX"] sub, span[special="LaTeX"] sub {
  vertical-align: -0.5ex;
  margin-left: -0.1667em;
  margin-right: -0.125em;
}

span[special="TeX"], span[special="LaTeX"] , span[special="TeX"] sub, 
span[special="LaTeX"] sub {
  font-size: 1em;
}

span[special="LaTeX"] sup {
  font-size: 0.85em;
  vertical-align: 0.15em;
  margin-left: -0.36em;
  margin-right: -0.15em;
  }
--
        --Per Bothner
address@hidden   http://per.bothner.com/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]