Bug 12037 - For relatively positioned boxes in an RTL block, 'right' should win over 'left' if both are not 'auto'
Summary: For relatively positioned boxes in an RTL block, 'right' should win over 'lef...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: 420+
Hardware: Mac OS X 10.4
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-12-30 10:56 PST by mitz
Modified: 2006-12-31 06:15 PST (History)
0 users

See Also:


Attachments
Implement the spec (10.53 KB, patch)
2006-12-30 11:24 PST, mitz
sam: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description mitz 2006-12-30 10:56:39 PST
According to <http://www.w3.org/TR/CSS21/visuren.html#relative-positioning>, "If neither 'left' nor 'right' is 'auto', the position is over-constrained, and one of them has to be ignored. If the 'direction' property of the containing block is 'ltr, the value of 'left' wins and 'right' becomes -'left'. If 'direction' of the containing block is 'rtl', 'right' wins and 'left' is ignored".

Currently in WebKit, 'left' always wins.
Comment 1 mitz 2006-12-30 11:24:16 PST
Created attachment 12124 [details]
Implement the spec

No layout test regressions. Implemented this way to avoid checking the containing block's direction unless necessary (it's cheaper to check both offsets than to check the direction and an offset).
Comment 2 Sam Weinig 2006-12-30 16:45:08 PST
Comment on attachment 12124 [details]
Implement the spec

r=me!
Comment 3 David Kilzer (:ddkilzer) 2006-12-31 06:15:52 PST
Committed revision 18490.