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

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>21588</bug_id>
          
          <creation_ts>2008-10-14 06:26:11 -0700</creation_ts>
          <short_desc>Calculation of column width with CSS-pseudo-class first-line</short_desc>
          <delta_ts>2011-10-22 11:28:33 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>CSS</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>Mac</rep_platform>
          <op_sys>OS X 10.4</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>WONTFIX</resolution>
          
          
          <bug_file_loc>https://macshot.de/php-aquarium</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P1</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>0</everconfirmed>
          <reporter name="Rüdiger Cordes">rc</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>tabatkins</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>95286</commentid>
    <comment_count>0</comment_count>
    <who name="Rüdiger Cordes">rc</who>
    <bug_when>2008-10-14 06:26:11 -0700</bug_when>
    <thetext>Tip for you to quick and comfortable testing: my program PHP-Aquarium

&lt;HTML&gt;
&lt;HEAD&gt;
 &lt;STYLE type=&quot;text/css&quot;&gt;
  td            { font-size:12px }
  td:first-line { font-size:24px }
 &lt;/STYLE&gt;
&lt;/HEAD&gt;
&lt;BODY&gt;
&lt;H3&gt;Calculation of column width with CCS-pseudo-class first-line.&lt;/H3&gt;
&lt;P&gt;Column width seems to be calculated before the first-line attributes are applied - wrong?&lt;/P&gt;
&lt;TABLE cellspacing=0 border=1&gt;
 &lt;TR&gt;
  &lt;TD&gt;erste Zeile&lt;br&gt;zweite Zeile&lt;/TD&gt;
 &lt;/TR&gt;
&lt;/TABLE&gt;
&lt;P&gt;Awaited:&lt;/P&gt;
&lt;TABLE cellspacing=0 border=1&gt;
 &lt;TR&gt;
  &lt;TD&gt;erste Zeile&lt;br&gt;zweite breitererere Zeile&lt;/TD&gt;
 &lt;/TR&gt;
&lt;/TABLE&gt;
&lt;/BODY&gt;
&lt;/HTML&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>95287</commentid>
    <comment_count>1</comment_count>
    <who name="Rüdiger Cordes">rc</who>
    <bug_when>2008-10-14 06:39:13 -0700</bug_when>
    <thetext>Priority P1 because I guess its an organizational thing (order) inside the webkit engine which will effect other problems too. So its a good bug to understand and test the problem. I am happy that I have not to do this ;-)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>95288</commentid>
    <comment_count>2</comment_count>
    <who name="Rüdiger Cordes">rc</who>
    <bug_when>2008-10-14 06:48:46 -0700</bug_when>
    <thetext>Firefox 3.0.3 doesnt break the first line but calculates the width of the column if second line has the font-size of the first line. Different but not better ;-) </thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>95303</commentid>
    <comment_count>3</comment_count>
    <who name="Rüdiger Cordes">rc</who>
    <bug_when>2008-10-14 09:47:59 -0700</bug_when>
    <thetext>More variations:

&lt;HTML&gt;
&lt;HEAD&gt;
 &lt;STYLE type=&quot;text/css&quot;&gt;
  td            { font-size:12px }
  td:first-line { font-size:24px }
  td.no:first-line { font-size:12px }
 &lt;/STYLE&gt;
&lt;/HEAD&gt;
&lt;BODY&gt;
&lt;H3&gt;Calculation of column width with CCS-pseudo-class first-line.&lt;/H3&gt;
&lt;P&gt;Column width seems to be calculated before the first-line attributes are
applied - wrong?&lt;/P&gt;
&lt;TABLE cellspacing=0 border=1&gt;
 &lt;TR&gt;
  &lt;TD&gt;erste Zeile&lt;br&gt;zweite Zeile&lt;/TD&gt;
 &lt;/TR&gt;
&lt;/TABLE&gt;
&lt;P&gt;Awaited:&lt;/P&gt;
&lt;TABLE cellspacing=0 border=1&gt;
 &lt;TR&gt;
  &lt;TD&gt;erste Zeile&lt;br&gt;zweite breitererere Zeile&lt;/TD&gt;
 &lt;/TR&gt;
&lt;/TABLE&gt;
&lt;P&gt;No work around: nowrap&lt;/P&gt;
&lt;TABLE cellspacing=0 border=1&gt;
 &lt;TR&gt;
  &lt;TD nowrap &gt;erste Zeile&lt;br&gt;zweite Zeile&lt;/TD&gt;
 &lt;/TR&gt;
&lt;/TABLE&gt;
&lt;P&gt;Same with CSS: white-space:nowrap&lt;/P&gt;
&lt;TABLE cellspacing=0 border=1&gt;
 &lt;TR&gt;
  &lt;TD style=&quot;white-space:nowrap&quot;&gt;erste Zeile&lt;br&gt;zweite Zeile&lt;/TD&gt;
 &lt;/TR&gt;
&lt;/TABLE&gt;
&lt;P&gt;So what about &amp;amp;nbsp; ?&lt;/P&gt;
&lt;TABLE cellspacing=0 border=1&gt;
 &lt;TR&gt;
  &lt;TD style=&quot;white-space:nowrap&quot;&gt;erste&amp;nbsp;Zeile&lt;br&gt;zweite Zeile&lt;/TD&gt;
 &lt;/TR&gt;
&lt;/TABLE&gt;
&lt;P&gt;Seems my theory is true:&lt;/P&gt;
&lt;TABLE cellspacing=0 border=1&gt;
 &lt;TR&gt;
  &lt;TD&gt;ersteextrabreite&amp;nbsp;Zeile&lt;br&gt;zweite Zeile&lt;/TD&gt;
 &lt;/TR&gt;
&lt;/TABLE&gt;
&lt;TABLE cellspacing=0 border=1&gt;
 &lt;TR&gt;
  &lt;TD class=no&gt;ersteextrabreite&amp;nbsp;Zeile&lt;/TD&gt;
 &lt;/TR&gt;
&lt;/TABLE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;TABLE cellspacing=0 border=1&gt;
 &lt;TR&gt;
  &lt;TD&gt;erste extrabreite&amp;nbsp;Zeile&lt;br&gt;zweite Zeile&lt;/TD&gt;
 &lt;/TR&gt;
&lt;/TABLE&gt;
&lt;TABLE cellspacing=0 border=1&gt;
 &lt;TR&gt;
  &lt;TD class=no&gt;erste extrabreite Zeile&lt;/TD&gt;
 &lt;/TR&gt;
&lt;/TABLE&gt;
&lt;/BODY&gt;
&lt;/HTML&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>218781</commentid>
    <comment_count>4</comment_count>
    <who name="Rüdiger Cordes">rc</who>
    <bug_when>2010-04-28 20:44:11 -0700</bug_when>
    <thetext>Isnt solved up to r58391.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>488695</commentid>
    <comment_count>5</comment_count>
    <who name="Tab Atkins">tabatkins</who>
    <bug_when>2011-10-21 15:04:12 -0700</bug_when>
    <thetext>Not a bug.  This is undefined in the specs, and I believe our behavior is reasonable.  You have to determine what size something is before you can determine what the first line is.  You may then have to adjust what is actually on the first line, based on the ::first-line styles, but ideally you want to minimize the amount of layout changes based on that.

If the spec ever specifies what to do here, we should ensure that we match it.  Until then, I&apos;m marking this as WONTFIX.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>488948</commentid>
    <comment_count>6</comment_count>
      <attachid>112092</attachid>
    <who name="Rüdiger Cordes">rc</who>
    <bug_when>2011-10-22 11:28:33 -0700</bug_when>
    <thetext>Created attachment 112092
Two unsuccessful attempts in trying to get control over line break.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>112092</attachid>
            <date>2011-10-22 11:28:33 -0700</date>
            <delta_ts>2011-10-22 11:28:33 -0700</delta_ts>
            <desc>Two unsuccessful attempts in trying to get control over line break.</desc>
            <filename>Safari Bug 21588-1.html</filename>
            <type>text/html</type>
            <size>1197</size>
            <attacher name="Rüdiger Cordes">rc</attacher>
            
              <data encoding="base64">PEhUTUw+DTxIRUFEPg0gPFNUWUxFIHR5cGU9InRleHQvY3NzIj4NICB0ZCAgIC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