Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(153)

Unified Diff: LayoutTests/fast/css/abs-pos-child-inside-rel-pos-inline-offset-001.html

Issue 423173003: Incorrect Static Position of Absolute Positioned Elements inside Rel-Positioned Containers (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Updated Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: LayoutTests/fast/css/abs-pos-child-inside-rel-pos-inline-offset-001.html
diff --git a/LayoutTests/fast/css/abs-pos-child-inside-rel-pos-inline-offset-001.html b/LayoutTests/fast/css/abs-pos-child-inside-rel-pos-inline-offset-001.html
new file mode 100644
index 0000000000000000000000000000000000000000..a45bcffbd247b6cb2b6a0e6c4eccfc2b8255dd69
--- /dev/null
+++ b/LayoutTests/fast/css/abs-pos-child-inside-rel-pos-inline-offset-001.html
@@ -0,0 +1,46 @@
+<!DOCTYPE HTML>
+<link rel="help" href="http://www.w3.org/TR/CSS21/visudet.html#containing-block-details">
+<link rel="help" href="http://www.w3.org/TR/CSS21/visudet.html#abs-non-replaced-width">
+<link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#relative-positioning">
+<link rel="author" title="Alan Gresley" href="alan[at]css-class.com">
+<link rel="author" title="Boris Zbarsky" href="bzbarsky[at]MIT.EDU">
+<link rel="author" title="Greg Whitworth" href="gwhit[at]microsoft.com">
+<link rel="author" title="GĂ©rard Talbot" href="www-style[at]gtalbot.org">
+<meta content="If the element has 'position: absolute' and in the case that the ancestor is an inline element, the containing block is the bounding box around the padding boxes of the first and the last inline boxes generated for that element. For relatively positioned elements, 'left' and 'right' move the box(es) horizontally, without changing their size. 'Left' moves the boxes to the right, and 'right' moves them to the left." name="assert">
+<meta content="ahem" name="flags">
+
+<style>
+ div#wrapper
+ {
+ font: 100px/1 Ahem;
+ }
+ span#first-inline
+ {
+ color: green;
+ border-bottom: 100px solid green;
+ }
+ span#second-inline
+ {
+ color: green;
+ border-bottom: 100px solid red;
+ }
+ div#rel-pos-inline
+ {
+ display: inline;
+ position: relative;
+ left: 100px;
+ }
+ div#abs-pos
+ {
+ color: green; /* change color to see what happens with position static */
+ position: absolute; /* If I'm position static, then a reference file is of no use */
+ height: 100px;
+ width: 100px;
+ }
+</style>
+<p>Test passes if there is no red.</p>
+<div id="wrapper"><span id="first-inline">X</span><span id="second-inline">X</span>
+ <div id="rel-pos-inline">
+ <div id="abs-pos">x</div>
+ </div>
+</div>

Powered by Google App Engine
This is Rietveld 408576698