<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>15748</bug_id>
          
          <creation_ts>2012-01-27 18:40:37 +0000</creation_ts>
          <short_desc>top margin edge - hence static position - is not well-defined</short_desc>
          <delta_ts>2012-12-04 00:53:39 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>CSS</product>
          <component>CSS Level 2</component>
          <version>unspecified</version>
          <rep_platform>All</rep_platform>
          <op_sys>Windows 3.1</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Anton P">antonsforums</reporter>
          <assigned_to name="Bert Bos">bert</assigned_to>
          
          
          <qa_contact>public-css-bugzilla</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>63198</commentid>
    <comment_count>0</comment_count>
    <who name="Anton P">antonsforums</who>
    <bug_when>2012-01-27 18:40:37 +0000</bug_when>
    <thetext>Reported by Anton Prowse

10.6.4 concerning the height of absolutely positioned elements says:

   # [...] the static position for &apos;top&apos; is the distance from the top
   # edge of the containing block to the top margin edge of [...]

But vertical margin edges are not well-defined for elements whose 
margins participate in margin collapsing.  This is most noticeable for 
self-collapsing elements, such as in the following test case in which 
there is no sensible relationship between the border box position of the 
&quot;tricky&quot; element (as determined by 8.3.1) and its 20px bottom margin:

&lt;div style=&quot;border-bottom:1px solid&quot;&gt;&lt;/div&gt;
&lt;div id=&quot;tricky&quot; style=&quot;margin-bottom:20px&quot;&gt;
     &lt;div style=&quot;margin-top:10px&quot;&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div style=&quot;border-top:1px solid&quot;&gt;&lt;/div&gt;

For the most part this glitch doesn&apos;t cause us any problems since elsewhere the 
spec avoids (albeit probably unconsciously) identifying individual 
margin pieces from amongst a collapsed margin lump.  However, 10.6.4 
relies on identifying the top margin edge of a box which may very well 
participate in margin collapsing.  For example, where should the absolutely positioned element be drawn in the following test case, and why?

&lt;div style=&quot;border-bottom:1px solid; margin-bottom:20px&quot;&gt;&lt;/div&gt;
&lt;div style=&quot;position:absolute; width:100px; height:100px; background: 
yellow; margin-top:10px&quot;&gt;&lt;/div&gt;
&lt;div style=&quot;border-top:1px solid; margin-top:20px&quot;&gt;&lt;/div&gt;

There&apos;s no interop on this issue, but that&apos;s because Fx and IE don&apos;t 
perform tentative margin collapsing at all for abspos in order to 
determine their static position.  (Indeed, UAs are free to make a guess 
at static position.)  Op and Sf do perform tentative margin collapsing and they seem to first calculate the top border position when determining the static position and then add on the top margin width to represent the &quot;top margin edge position&quot;.

Conversation begins:
Bug description:
http://lists.w3.org/Archives/Public/www-style/2011Mar/0638.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>63199</commentid>
    <comment_count>1</comment_count>
    <who name="Anton P">antonsforums</who>
    <bug_when>2012-01-27 18:43:29 +0000</bug_when>
    <thetext>My proposal (incorporating Peter Moulder&apos;s comments):

Define static position in terms of top border edge instead of top margin edge.  I&apos;m not suggesting actually changing any behaviours, of course; so the definition would have to factor the top margin width back in to the calculation.  (I think this is the Op/Sf approach mentioned in the previous comment.)

http://lists.w3.org/Archives/Public/www-style/2011Apr/0016.html
http://lists.w3.org/Archives/Public/www-style/2011Apr/0038.html</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>