From: Sebastian G. <sge...@st...> - 2001-08-13 17:01:21
|
On Wed, Aug 01, 2001 at 06:14:20PM +0200, Sebastian Geerken wrote: > On Wed, Aug 01, 2001 at 05:34:28PM +0200, Ulrich Schwarz wrote: > > Hi, > > > > since a month or so, the cvs version (including the latest 0.6 release) of > > dillo doesn't wrap the text on http://futurezone.orf.at but instead > > extends the page width to the longest text paragraph of that page so > > that no word wrapping is done and each text paragraph is displayed in > > a single (extremely long) text line. > > > > Is this due to buggy html code on that page or due to a suboptimal > > page width calculation of dillo? > > I've looked at the page, and found > > <TD WIDTH="380" ROWSPAN="2" NOWRAP> > > nearly directly before the text. I'm not quite sure about the > specification (or if it is even clear in this case), but at least, > this is quite ambiguous. Dillo's current behavior is to use WIDTH > attributes only as hints; if the cell is wider (in this case due to > the NOWRAP argument), it is (more or less) ignored, As far as I've understood, this is not quite conforming to the specifications, but I haven't found anything about word-wrap, only about clipping. However, since IMHO, this HTML code does not make any sense, I thought of a workaround, which ignores the NOWRAP in this case, in Html_tag_open_table_cell: /* text style */ old_style = html->stack[html->stack_top].style; style_attrs = *old_style; - if (Html_get_attr(tag, tagsize, "nowrap", attrbuf, sizeof(attrbuf))) + if (Html_get_attr(tag, tagsize, "nowrap", attrbuf, sizeof(attrbuf)) && + !Html_get_attr(tag, tagsize, "width", attrbuf, sizeof(attrbuf))) style_attrs.nowrap = TRUE; else style_attrs.nowrap = FALSE; Intended as a subject of further discussions. Sebastian |