Re: Is this a known bug?

"Sebastian Geerken" <[email protected]>
Newsgroups gmane.comp.web.dillo.devel
Message-ID <[email protected]>
On Mo, Mär 14, 2016, John Found wrote:
> In the following html:
> 
> <html>
> <head>
> </head>
> <body style="text-align: left;">
>   <div style="width: 50%; text-align: right; background: #f0f060;">
>     <span style="display:inline-block; text-align: left; height: 32px; width: 150px; background: #60f0f0;">Some text!</span>
>   </div>
> </body>
> </html>
> 
> Dillo aligns the div to the right and the span to the left of the div, while all other browsers align the div to the left and the span to the right. Something like (B-body, D-div, S-span):
> 
> Dillo:
> BBBBBBBBBBBBBBBBBBBBB
>           DDDDDDDDDDD
>           SSSSS
> 
> Others:
> BBBBBBBBBBBBBBBBBBBBB
> DDDDDDDDDDD
>       SSSSS

I haven't looked at it in detail, but it looks like dillo is referring
'text-align' to the element where it is defined, so positioning the
<div> on the right, and <span> on the left side. As specified in [1],
this is incorrect behaviour:

   'text-align' 
      [...]
      Applies to:  block containers
      [...]

   This property describes how *inline-level content* of a block
   container is aligned. Values have the following meanings: [...]

(Emphasis mine.)

Probably the simplest approach is that dw::Textblock simply uses
widget style, not word style for alignment. I'm not sure whether there
is already one dw::Textblock for each block element.

Sebastian

[1] https://www.w3.org/TR/CSS2/text.html#propdef-text-align

_______________________________________________
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

iQEcBAEBAgAGBQJW5ySOAAoJEAw7+YHB+ZL6++EH/34HMh9CEhlm5vxS6jVbjHiY
c2q6pOkZNRdiXMhIOVWQgSgJq41tMUqITnAHnJd65tscSJoU4VV2yYtOgxPiAwr9
Jecta4qe/XxebAP91LhbK3w7gvSjnLT1xa+bGdpL2aOhvO/QWeC9wC6XhIli4FI4
deQ+VVT4bHI6tqTbaxjXTRGtAVGo29epguMJRwtVt5pItoK8KAoDcqESwrCDhDRj
NE8nELskkg7C58weedHE6cveqkEFC1HFEj5aj7NIb+5nSay+pFM9TtM1vSRqm5/y
PQu6eHQ8KR4Sq+cdtq22Zuw7X7xBjazCNyGDb6fDLma3tg93zIg+lxXYFB9peKQ=
=7cCd
-----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.