Closed
Bug 652007
Opened 14 years ago
Closed 14 years ago
Painting artifacts with RTL trees
Categories
(Core :: XUL, defect)
Core
XUL
Tracking
()
RESOLVED
FIXED
People
(Reporter: neil, Assigned: neil)
References
Details
Attachments
(1 file)
3.85 KB,
patch
|
roc
:
review+
|
Details | Diff | Splinter Review |
Bug 649840 uncovered a painting bug with RTL trees.
In researching this bug, I have discovered the following:
*GetCoordsForCellItem doesn't take column alignment into account at all
*If the text is overflowing, AdjustForCellText doesn't take column alignment into account, so for instance if all the cells in RTL or right-aligned column overflow then they will have a ragged right margin
*GetItemWithinCellAt and PaintText force the text to be right-aligned without any margin or padding when RTL is in effect (possibly to work around the above bug) although the border and background paints in the expected position allowing for column alignment.
*PaintText also miscalculates the width of the text when it has borders or padding so PaintRow makes PaintSeparator paints over the border or padding.
*PaintRow also gets the left separator wrong; it tries to use the indentation instead of the twisty rect to make a top-level separator span the tree.
Assignee | ||
Comment 1•14 years ago
|
||
Assignee | ||
Comment 2•14 years ago
|
||
Comment on attachment 527681 [details] [diff] [review]
Proposed patch
>@@ -1275,25 +1275,17 @@ nsTreeBodyFrame::GetCoordsForCellItem
*GetCoordsForCellItem doesn't take column alignment into account at all
>@@ -1464,32 +1456,32 @@ nsTreeBodyFrame::AdjustForCellText
*AdjustForCellText doesn't take column alignment into account
>@@ -1623,18 +1615,16 @@ nsTreeBodyFrame::GetItemWithinCellAt
*GetItemWithinCellAt forces the text to be right-aligned when RTL is in effect
>@@ -3578,30 +3568,26 @@ nsTreeBodyFrame::PaintText
*PaintText also miscalculates the width of the text (untested in RTL)
*PaintText forces the text to be right-aligned when RTL is in effect
Comment 3•14 years ago
|
||
Thanks Neil for your patch!
The other Neil will be on vacation for quite some time. Is there anybody else who can review this? roc maybe?
Comment on attachment 527681 [details] [diff] [review]
Proposed patch
Review of attachment 527681 [details] [diff] [review]:
Attachment #527681 -
Flags: review?(enndeakin) → review+
Assignee | ||
Comment 5•14 years ago
|
||
Pushed changeset 3bee3fefdec8 to mozilla-central.
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Comment 6•7 years ago
|
||
Moving to Core:XUL per https://bugzilla.mozilla.org/show_bug.cgi?id=1455336
Component: XP Toolkit/Widgets: XUL → XUL
You need to log in
before you can comment on or make changes to this bug.
Description
•