<!DOCTYPE html>
<html>
<body style="width: 0">
<span style="border-style: solid; border-width: 0 0 0 1px;">
<div style="display: inline-block; width: 100px"></div>
</span>
next
</body>
</html>
In Gecko that shows a blank line between the vertical bar and the text
"next", because the continuation of the span has IsSelfEmpty() false,
and hence isEmpty ends up false in nsLineLayout::ReflowFrame.
In Opera and Webkit, the blank line is not present.
It seems to me that we should perhaps be taking the GetSkipSides for the
frame into account when determining self-emptiness... The problem is
that this state isn't really reliable until after bidi reordering and
the like, right?
-Boris
On the other hand, bidi reordering might change the outcome of
IsSelfEmpty() in some rare cases, but should never change IsEmpty(),
right? So maybe it's safe to just set a bit during reflow if we end up
in a situation where we skip both start and end sides, and return
IsSelfEmpty() == true in those cases?
-Boris
Actually I'm not sure whether bidi reordering should change GetSkipSides
... I'd have to reread the CSS 2.1 spec and our code.
Rob
It certainly does in our code, and I'd hope the spec matches that.
That's the only behavior that can possibly make sense. Otherwise you
get borders halfway through the text.
That said, for the frames I care about (those somewhere in the middle of
an {ib} split), bidi reordering can't change the fact that both start
and end are skipped. I could just hack knowledge of ib splits into
nsInlineFrame::IsSelfEmpty if people are ok with that.
-Boris