<?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>55619</bug_id>
          
          <creation_ts>2011-03-02 14:43:47 -0800</creation_ts>
          <short_desc>Stylesheet rule cssText is all lowercase</short_desc>
          <delta_ts>2011-09-16 00:39:49 -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>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>WONTFIX</resolution>
          
          
          <bug_file_loc>http://tinymce.moxiecode.com/safari/stylesheet_case.html</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P4</priority>
          <bug_severity>Major</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Moxiecode Systems">spam</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>ap</cc>
    
    <cc>eric</cc>
    
    <cc>hyatt</cc>
    
    <cc>k_bolisetty</cc>
    
    <cc>mustaf.here</cc>
    
    <cc>rniwa</cc>
    
    <cc>sarap.karthik</cc>
    
    <cc>simon.fraser</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>361089</commentid>
    <comment_count>0</comment_count>
    <who name="Moxiecode Systems">spam</who>
    <bug_when>2011-03-02 14:43:47 -0800</bug_when>
    <thetext>Description:
The stylesheet rules are forced into lowercase. It should retain the case that is specified in the CSS file.

Steps to reproduce:
1. Open the attached url.
2. Click the test button.
3. Observe that the CSS rule text is all lowercase instead of the original values.

Expected result:
The CSS rule should be the same case as the one inside the stylesheet.

Actual result:
The CSS rule is forced into lowercase it&apos;s not impossible to get the original case for a class.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>361256</commentid>
    <comment_count>1</comment_count>
    <who name="Ryosuke Niwa">rniwa</who>
    <bug_when>2011-03-02 17:44:43 -0800</bug_when>
    <thetext>I suspect that fixing this bug requires considerable amount of work.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>361264</commentid>
    <comment_count>2</comment_count>
    <who name="Simon Fraser (smfr)">simon.fraser</who>
    <bug_when>2011-03-02 17:51:48 -0800</bug_when>
    <thetext>I don&apos;t think any spec requires that case is round-tripped.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>432178</commentid>
    <comment_count>3</comment_count>
    <who name="Karthik Sarap">sarap.karthik</who>
    <bug_when>2011-07-05 03:08:38 -0700</bug_when>
    <thetext>This issue is because of the rule we have for class: in CSSGrammar.y in the following lines         
if (!p-&gt;m_strict)
	$2.lower();

While loading the page, the call flow is CSSStyleSheet::parseStringAtLine() =&gt; CSSParser::parseSheet()=&gt; cssyyparse(this); And while parsing as per the above logic, we convert the class string to lower case if the parser is running in NON-strict mode

We have verified that if we add DOCTYPE on top of my html (which makes the CSSParser in strict mode), the style class info is shown maintaining proper casing given in the html page.

Therefore,
Does any one know why do we have that logic(as mentioned above) of converting string to lowercase for non-strict mode in CSSGrammar.y? Based on this, we can decide whether or not to fix the issue</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>432317</commentid>
    <comment_count>4</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2011-07-05 10:28:21 -0700</bug_when>
    <thetext>It&apos;s a documented quirk of Mozilla&apos;s quirks mode:
https://developer.mozilla.org/en/mozilla_quirks_mode_behavior</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>432318</commentid>
    <comment_count>5</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2011-07-05 10:29:13 -0700</bug_when>
    <thetext>Or rather the case-insensitivity is:

In quirks mode css class names are case insensitive. In standards mode they are case sensitive.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>432321</commentid>
    <comment_count>6</comment_count>
    <who name="Ryosuke Niwa">rniwa</who>
    <bug_when>2011-07-05 10:31:26 -0700</bug_when>
    <thetext>class name is nothing to do with this bug.  This bug is about cssText being lower case.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>432633</commentid>
    <comment_count>7</comment_count>
    <who name="Mustafizur Rahaman (rahaman)">mustaf.here</who>
    <bug_when>2011-07-05 23:11:59 -0700</bug_when>
    <thetext>(In reply to comment #5)
&gt; Or rather the case-insensitivity is:
&gt; 
&gt; In quirks mode css class names are case insensitive. In standards mode they are case sensitive.

My interpretation is if a html page does not mention any DOCTYPE, then it is by default quirks mode, correct? Then does it mean Mozilla has an issue here because in quirks mode also FF is respecting the CSS class names, which it should not do as per link given above?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>468356</commentid>
    <comment_count>8</comment_count>
      <attachid>107614</attachid>
    <who name="Kishore Sri Venkata Ganesh Bolisetty">k_bolisetty</who>
    <bug_when>2011-09-16 00:13:46 -0700</bug_when>
    <thetext>Created attachment 107614
modifed test case

Attached the modifed test case . Just Added &lt;!DOCTYPE html&gt; to the actual test case.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>468358</commentid>
    <comment_count>9</comment_count>
    <who name="Kishore Sri Venkata Ganesh Bolisetty">k_bolisetty</who>
    <bug_when>2011-09-16 00:17:27 -0700</bug_when>
    <thetext>http://www.w3.org/TR/html5-diff/#doctype
In my opinion, the above link strengthens comments 5 &amp; 7. 
As per the spec, browser need not render the page in standars mode unless &lt;!DOCTYPE html&gt; is mentioned.
If I am correct, can some one move this to INVALID/WONTFIX state.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>107614</attachid>
            <date>2011-09-16 00:13:46 -0700</date>
            <delta_ts>2011-09-16 00:13:46 -0700</delta_ts>
            <desc>modifed test case</desc>
            <filename>doctype.html</filename>
            <type>text/html</type>
            <size>533</size>
            <attacher name="Kishore Sri Venkata Ganesh Bolisetty">k_bolisetty</attacher>
            
              <data encoding="base64">PCFET0NUWVBFIEhUTUw+CjxodG1sIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hodG1s
Ij4KPGhlYWQ+Cjx0aXRsZT5TdHlsZXNoZWV0IGJ1ZzwvdGl0bGU+CjxzdHlsZT4KLm15VXBwZXJD
YXNlQ2xhc3Mge2NvbG9yOiByZWR9Cjwvc3R5bGU+CjxzY3JpcHQ+CmZ1bmN0aW9uIHRlc3QoKSB7
CglhbGVydChkb2N1bWVudC5zdHlsZVNoZWV0c1swXS5jc3NSdWxlc1swXS5jc3NUZXh0KTsKfQo8
L3NjcmlwdD4KPC9oZWFkPgo8Ym9keT4KPGgxPkNzcyBydWxlIGxvd2VyY2FzZSBidWc8L2gxPgo8
b2w+Cgk8bGk+Q2xpY2sgdGhlIHRlc3QgYnV0dG9uIGJlbG93LjwvbGk+Cgk8bGk+T2JzZXJ2ZSB0
aGF0IHRoZSBjbGFzcyBuYW1lIGlzIGFsbCBsb3dlcmNhc2UgaW5zdGVhZCBvZiB0aGUgc3BlY2lm
aWVkIGNhc2UgaW4gdGhlIENTUy48L2xpPgoJPGxpPkNvbXBhcmUgaXQgdG8gb3RoZXIgR2Vja28g
b3IgT3BlcmEuPC9saT4KPC9vbD4KPGJ1dHRvbiBvbmNsaWNrPSJ0ZXN0KCkiPlRlc3Q8L2J1dHRv
bj4KCjwvYm9keT4KPC9odG1sPgo=
</data>

          </attachment>
      

    </bug>

</bugzilla>