[Top][All Lists]

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

Re: texi2html output validity

From: Yuri Khan
Subject: Re: texi2html output validity
Date: Wed, 24 Dec 2014 00:59:32 +0700

On Tue, Dec 23, 2014 at 10:49 PM, Patrice Dumas <address@hidden> wrote:

> First of all it is a bit unclear where this html comes from.  In
> general, both texi2html and texi2any/makeinfo, especially for makeinfo
> starting at version 5 render properly nested html tags.

I haven’t checked. David Kastrup posted it as an example of how image
size is not declared, and I just assumed it was real Texinfo output.

>> @key should be rendered as <kbd>, possibly with an additional class.
>> Yes, even when inside @kbd — HTML allows and encourages nesting <kbd>.
> I am not convinced.  @key is semantically very diferent from @kbd which
> is the same as <kbd>.  Indeed <kbd> is not for a keyboard key in HTML,
> but for typed keyboard input.

http://www.w3.org/TR/html5/text-level-semantics.html#the-kbd-element says:

> When the kbd element is nested inside another kbd element, it represents an 
> actual key or other single unit of input as appropriate for the input 
> mechanism.

> @t and other non-semantic commands are already discouraged in the manual.
> But I see no point in not using <tt> for @t, as long as browser support
> it (which is likely to be until the end of times). CSS is not supported
> by every browser.

What browsers are there that do not support CSS *and* at the same time
have the capability of displaying proportional fonts?

Anyway this point is moot because the current HTML specification makes
CSS the only supported way of specifying presentation. Browsers that
do not yet support CSS had better keep up.

> I may have missed something, but in the specification of 4.01
> Transitional all the element you describe as needing to be dropped
> are accepted?  I see them all in
> http://www.w3.org/TR/html401/sgml/loosedtd.html

Yes, 4.01 Transitional allowed all that. That’s why it was named
Transitional — to provide backward compatibility for the transition

As of this past October, that transition period is over. HTML 3.2 is
obsolete and so is 4.01 Transitional. 4.01 Strict remains an
almost-compatible subset of the current standing Recommendation, HTML

>> * tables should be generally avoided unless actually representing tabular 
>> data;
> Agreed, but sometime we want to do some non-semantic formatting, for
> instance for node lines, or indices.  <table> is very practical in that
> case.

Non-semantic formatting is bad. Please do not want to do it.

I do not understand what node lines are. I thought a node is a whole
section of a document?

Indices would look much better as definition lists, possibly styled
for compact presentation on viewports wider than a certain threshold,
and possibly using multicolumn layout on even wider viewports. I
tested the Emacs manual index[1] in the Responsive Design View mode in
Firefox: it fits the 320×480 screen very poorly and under-utilizes the
1920×1200 screen.

[1]: http://www.gnu.org/software/emacs/manual/html_node/emacs/index.html

>> * the encoding declaration <meta> should be the first thing in <head>;
> What would be the reason for that?

Because the HTML specification says[2] the encoding declaration must
appear within the first 1024 bytes of the document, and including any
kind of document-provided content before the encoding declaration
might cause a violation of this rule.

[2]: http://www.w3.org/TR/html5/document-metadata.html#charset1024

And the reason for HTML spec saying so is that if the parser does not
know the encoding beforehand, it then has to perform a preliminary
scanning of the document in search of an encoding declaration. After
it finds one, it has to restart at the beginning. Restarting the
parsing could be very inefficient if the document is being streamed
from the network.

reply via email to

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