Closed Bug 908706 Opened 8 years ago Closed 2 months ago
Percentage text-indent handled incorrectly in overflow:hidden block
Per spec, percentage text-indent refers to the containing block width. We do this right usually, but if the block has a scrollframe, we seem to make it refer to the scrollframe width, which is wrong. In the attached testcase the "CANTSEEME" text should not be visible.
nsLineLayout uses nsHTMLReflowState::GetContainingBlockContentWidth(mBlockReflowState) to compute the percentage basis.... would that return the reflow state for the scrollframe?
It seems <fieldset> is wrong too (and like other cases with anon block wrappers).
Attachment #794719 - Attachment is obsolete: true
Webkit seems to use the table, Presto the <div> as containing block. Gecko uses the TableCellFrame maybe?
Fwiw, skipping reflow states for anon pseudo frames fixes the scroll frame and <fieldset> cases. Should we skip other types of pseudos too?
Comment 2: s/like/likely/
Things tohink about: * can we benefit from nsIFrame::GetContainingBlock()? (I also keep wanting an IsContainingBlock() function.) * should the walking be through parentReflowState or mCBReflowState? * is mCBReflowState even being set correctly in this case for other uses of mCBReflowState? Maybe it's just set wrong here?
Mats, are you still planning to drive this in?
Bug 1453298 makes this invalid.
Status: NEW → RESOLVED
Closed: 2 months ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.