[whatwg] HTML spec incorrectly suggests that <br> can have its rendering changed with CSS

Elliott Sprehn esprehn at gmail.com
Tue Jan 28 01:04:06 PST 2014


On Thu, Jan 23, 2014 at 10:54 AM, Daniel Holbert <dholbert at mozilla.com>wrote:

> On 01/23/2014 03:16 AM, Stewart Brodie wrote:
> >> [2] I only noticed one rendering difference -- IE11 honors "border" on
> >> <br>, unlike the other browsers that I tested. (It still doesn't honor
> >> e.g. "display"/"width"/"height", though.)
> >
> > I get different results on your test case for the bottom two tests.  In
> > Chrome 33 and Opera 12.16 (Linux), there is a line break; in Firefox 26
> > there isn't.
>
> Yeah -- sorry, I thought up those last two testcases (applying "float"
> and "position:absolute" to <br>) a bit later, after I sent my initial
> email. (which is why I didn't mention them as a rendering difference)
>
> So, the "position" & "float" properties do represent a little bit of
> style that Gecko honors on <br> (but not Blink/Presto; not sure about IE).
>
>
Blink treats <br> (conceptually) like a subclass of Text, there's nothing
to style because it's just a run of text with a forced break.

- E



More information about the whatwg mailing list