Closed Bug 331562 Opened 15 years ago Closed 14 years ago

lost padding-left in overflowing scrollable RTL blocks


(Core :: Layout: Text and Fonts, defect)

Not set





(Reporter: hsaito54, Assigned: mkaply)


(Blocks 1 open bug)


(Keywords: rtl, testcase)


(2 files)

Padding-left is disregarded in overflowing scrollable RTL blocks, although padding-right is displayed in overflowing scrollable LTR blocks.
Attached file testcase
I think that padding-left on testcase should be displayed.
The reason is illustrated as follows.

If padding-left is |a|, content-width is |b| and available-width is |c|, |d| is overflowing-width.


Current reflowing is illustrated as follows, in the result, padding-left is lost.

I think that the reflowing should be done as follows.

Attached patch test patchSplinter Review
Keywords: testcase
What in the spec says this should work?  I can't find anything, although it does work for LTR.

The patch looks wrong.  You shouldn't need to add piles of code to fix this.
(Where is the code that makes this work for LTR?)
(In reply to comment #4)
> (Where is the code that makes this work for LTR?)

Following change removes padding-right in overflowing LTR blocks.

+++ nsBlockFrame.cpp	Sat Mar 25 22:28:46 2006
@@ -1260,17 +1260,17 @@ nsBlockFrame::ComputeFinalSize(const nsH
       if (NS_BLOCK_SPACE_MGR & mState) {
         // Include the space manager's state to properly account for the
         // extent of floated elements.
         nscoord xmost;
         if (aReflowState.mSpaceManager->XMost(xmost) &&
             computedWidth < xmost)
           computedWidth = xmost;
-      computedWidth += borderPadding.right;
+      //computedWidth += borderPadding.right;
       // Add in border and padding dimensions to already computed
       // max-element-width values.
       maxElementWidth = aState.mMaxElementWidth +
         borderPadding.left + borderPadding.right;
Blocks: 137995
Padding-right is not already displayed in overflowing scrollable LTR blocks by the fix for Bug 300030. I think this report should be closed.
Closed: 14 years ago
Resolution: --- → INVALID
Mass-assigning the new rtl keyword to RTL-related (see bug 349193).
Keywords: rtl
Component: Layout: BiDi Hebrew & Arabic → Layout: Text
QA Contact: zach → layout.fonts-and-text
You need to log in before you can comment on or make changes to this bug.