9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: "Trickey, Howard W (Howard)" <trickey@lucent.com>
To: Fans of the OS Plan 9 from Bell Labs <9fans@cse.psu.edu>
Subject: RE: [9fans] libhtml vs. <pre> tags
Date: Fri, 21 Oct 2005 14:16:24 -0400	[thread overview]
Message-ID: <3BD3BB8D47F9DE4984C319EA325A006DC401C3@nj9620exch003u.mh.lucent.com> (raw)

>> Tables have always been a complete bitch in rendering HTML. Part  
>> of the problem is that it is easy to inconsistently overspecify a  
>> table (e.g., the whole table must have width 3in but there are  
>> only two columns each of which must have width 2 in), and you have  
>> to experiment with, say, Internet Explorer, to see how it resolves  
>> the problem.
>>
>
>> one would think that knuth had solved it for τεχ. any of it  
>> applicable to html?
>

> This is specified in CSS2, clearly and unambiguously. If the sum of  
> columns' widths is less than the table's width, one must increase the  
> column widths so that they fill the tables width. You don't have to  
> experiment with implementations to comply to the specification.  
> Unless you have to deal with multipage tables, formatting table, even  
> with auto-layout, is a relatively easy task.
>
> And you don't need Knuth and TEX for that.

I hadn't been following CSS2 closely, as I'm out of that business, but you raised my hopes that someone had finally thought out all these cases and set down rules.  But I just looked at the CSS2 spec and that doesn't seem to be true.  First, while an 'auto layout' algorithm is described, it says "UA's are not required to implement this algorithm; they can use any other algorithm". Also, I was just giving off the top of my head an overspecification, and you are right that it is covered by the CSS2 algorithm, but other cases of overspecification are left ambiguous: e.g.,

 "A percentage value for a column width is relative to the table width.
 If  the table has 'width: auto', a percentage represents a constraint
 on the   column's width, which a UA should try to satisfy. (Obviously,
 this is not always possible: if the column's width is '110%', the
 constraint cannot be satisfied.)"

It doesn't say what to do when you can't satisfy constraints (there are obvious guesses of course, and they are usually right).  However, I do think CSS2 now does a much better job than the original HTML specs that I had to work from at tying down layout questions.

This doesn't even get into the problems of ill-formed HTML.  I couldn't see anything in the spec about what to do about

	<TR> row stuff ... </TR>JUNK<TR> another row ... </TR>

Does one render the JUNK, and if so, how?

I do agree with Uriel, however, that my initial whine about the pain of tables ignores that HTML usage has marched on, and the new problems with CSS and javascript leave libhtml woefully unprepared.  Sorry.

Oh - and the comment about TEX: Knuth was a better designer of table specification - all the questions about how to apportion space in tables come down to simply applying the general rules re stretchable "glue".  So the algorithm isn't hard, and also doesn't help with the "bad HTML table specification" problem.

Sorry to ramble on.  I guess I'm indulging in nostalgia.

- Howard


             reply	other threads:[~2005-10-21 18:16 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-10-21 18:16 Trickey, Howard W (Howard) [this message]
  -- strict thread matches above, loose matches on Subject: below --
2005-10-21 14:37 Federico G. Benavento
2005-10-21 14:21 Federico G. Benavento
2005-10-21 14:40 ` C H Forsyth
2005-10-21 14:02 Federico G. Benavento
2005-10-21 14:16 ` rog
2005-10-21 14:20   ` LiteStar numnums
2005-10-21 15:09   ` Wes Kussmaul
2005-10-21 13:47 Trickey, Howard W (Howard)
2005-10-21 13:55 ` erik quanstrom
2005-10-21 14:06 ` Wes Kussmaul
2005-10-21 14:16 ` C H Forsyth
2005-10-21 15:04 ` Uriel
2005-10-21 18:45   ` Wes Kussmaul
2005-10-21 19:12     ` Uriel
2005-10-21 19:20       ` Wes Kussmaul
2005-10-21 17:35 ` Skip Tavakkolian
2005-10-21 17:51   ` David Tolpin
2005-10-21 13:40 Federico G. Benavento
2005-10-21 13:51 ` erik quanstrom
2005-10-21  4:34 Federico G. Benavento
2005-10-21  5:09 ` Federico Benavento
2005-10-21  9:49   ` Kenji Okamoto
2005-10-21  9:51     ` Kenji Okamoto
2005-10-21 13:19   ` erik quanstrom
2005-10-21 13:25   ` erik quanstrom
2005-10-20  1:56 erik quanstrom
2005-10-20  2:17 ` erik quanstrom
2005-10-20 17:04   ` Federico Benavento
2005-10-21  4:01     ` erik quanstrom

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=3BD3BB8D47F9DE4984C319EA325A006DC401C3@nj9620exch003u.mh.lucent.com \
    --to=trickey@lucent.com \
    --cc=9fans@cse.psu.edu \
    /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).