caption element widths

A short demo is included to illustrate another box width calculate
issue.  This one has a caption that should widen the nesting table
block to prevent word wrap!!  Amaya bases the table width only on
 cell widths but not the caption width ;-[  ;-[   
However it does a much better job than any of the main browsers !!!!
At least it makes the caption part of the table for styling

None of the major browsers use the caption width to calculate table
width....  msie/opera at least centers the caption....
mozilla group does not even center the caption  ugh .....

Browser diversity on simple concepts makes it difficult for designers
to express their vision in simple html/css markup.  More and more
are moving to pdfs and flash, and concentrating on the browser from
the evil empire, simply cuz it has such a huge market share.  
CAN YOU SENSE THE SMELL OF FRUSTRATION HERE ?

--
john russell ve3ll@rac.ca [those are L's as in LLAMA]
http://home.cogeco.ca/~ve3ll
http://home.cogeco.ca/~trains
http://home.cogeco.ca/~cipher
<?xml version="1.0"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><title>Table Captions - VE3LL@RAC.CA</title>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<style type="text/css">
div {text-align:center}
table {margin:auto; background:yellow;border:1px solid red}
caption {font:bold 14pt sans-serif}
</style></head>
<body><h1>Table Captions - VE3LL@RAC.CA</h1>
<div><table summary="the first column gives the year and the second,
the revenue for that year">
<caption>Projected Sales</caption>
<tr><th>Year</th><th>Sales</th></tr>
<tr><td>2000</td><td>$18 Million</td></tr>
<tr><td>2001</td><td>$25 Million</td></tr>
<tr><td>2002</td><td>$36 Million</td></tr></table></div>
<p>The markup for this example is:</p>
<pre>&lt;table summary="the first column gives the year and the second,
       the revenue for that year"&gt;
&lt;caption&gt;Projected Sales&lt;/caption&gt;
&lt;tr&gt;&lt;th&gt;Year&lt;/th&gt;&lt;th&gt;Sales&lt;/th&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;2000&lt;/td&gt;&lt;td&gt;$18 Million&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;2001&lt;/td&gt;&lt;td&gt;$25 Million&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;2002&lt;/td&gt;&lt;td&gt;$36 Million&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;
</pre></body></html>

Received on Tuesday, 13 April 2004 09:08:28 UTC