Problem related to generated content

"Sebastian Geerken" <[email protected]>
Newsgroups gmane.comp.web.dillo.devel
Message-ID <[email protected]>
Hi!

I've come upon an interesting problem. Consider this HTML (stripped
down from a real world example):

    <head>
        <style>
            .fc:after {
                content: "";
                display: block;
                clear: both;
            }
        </style>            
    </head>
    <body>
        <div class="fc">
            <div style="float: left">main</div>
        </div>
        <div style="background:#404040; color:#ffffff">footer</div>
    </body>

Firefox (and probably other browsers) renders black text "main" on
white background above white text "footer" on dark gray background.
Dillo 3.0.5 does the same, for the simple reason that it does not
support floats. Dillo 3.1-dev, however, renders black text "main" and
white text "footer" side by side on dark gray background, because
"main" is within a float. (Which is, of course, difficult to read.)

The reason why Firefox renders this as it does: the definition within
<style> generates something like a block element before the text
containing "footer", with "clear: both" as CSS attributes; something
like:

    <body>
        <div class="fc">
            <div style="float: left">main</div>
        </div>
        <div style="clear:both"></div>
        <div style="background:#404040; color:#ffffff">footer</div>
    </body>

Aside from the fact that dillo has still problems with this ("footer"
is too much to the right; I'll investigate this independently), this
shows that dillo's limited capabilities regarding generated content,
together with floats, causes some unpleasing rendering errors, which
are furthermore laborious to analyse (and thus not so simple to
be ignored). Has someone a feasible idea to deal with this?

Sebastian

_______________________________________________
Dillo-dev mailing list
[email protected]
http://lists.dillo.org/cgi-bin/mailman/listinfo/dillo-dev
signature.asc (application/pgp-signature, 473 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQEcBAEBAgAGBQJXfBMoAAoJEAw7+YHB+ZL6U2oH/3cikqEFJ8BJHkz/icjjpa4O
Xu1PtomQpiu8ITso6Y5QxTOp21/2+VUxzm6yGYU8+DNvfWhLhwPruZ5YEDMUUuF6
M6yEEY+TLync+AYfNUNG3bHQfnqAGHo+YyZkluUZrT2iBHLc4Ix7w6brbtHngijk
8kd2MJIqz4zjiFekIIaEv8BJGVeKgH9dJjr6IJk2F5AKGNce1lxtazO6WXdCBxfQ
X5OJWiCT0tw4Mw/fBDLzXK1W4qXJnzaW5p69PRTIy0yWnaayHpxbwJOz9zRmoQ/l
/PWNIgXhB0g/qMK2rHC1cSss2gJ6T6SsFlJBBtpIjSqvkw5FSGm3lm8owMpfcaQ=
=ayMk
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.