<?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>26984</bug_id>
          
          <creation_ts>2009-07-05 14:05:25 -0700</creation_ts>
          <short_desc>style properties depend on locale.</short_desc>
          <delta_ts>2009-07-06 04:39:22 -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>WebKitGTK</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>PC</rep_platform>
          <op_sys>OS X 10.5</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>18994</dup_id>
          
          <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>0</everconfirmed>
          <reporter name="arno.">a.renevier</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>jmalonzo</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>129882</commentid>
    <comment_count>0</comment_count>
    <who name="arno.">a.renevier</who>
    <bug_when>2009-07-05 14:05:25 -0700</bug_when>
    <thetext>Hi,
style properties (as read with javascript) depend on locale.
For example, following piece of code:

    p.style.width = &apos;100.5px&apos;;
    alert(p.style.width);

show 100,5px with  a french locale and 100.5px with an english locale (decimal separator is not the same).
That makes comparaison and parsing of those results nearly impossible in a cross-locale way.
Moreover, as parseFloat is not locale dependant, 

p.style.opacity = 0.5;
parseFloat(p.style.opacity);

shows 0 with a french locale and 0.5 with an english locale.
That&apos;s quite disturbing.

Setting to gtk component as I don&apos;t known if it happens with other backends.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>129883</commentid>
    <comment_count>1</comment_count>
      <attachid>32282</attachid>
    <who name="arno.">a.renevier</who>
    <bug_when>2009-07-05 14:07:00 -0700</bug_when>
    <thetext>Created attachment 32282
testcase</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>129927</commentid>
    <comment_count>2</comment_count>
    <who name="Jan Alonzo">jmalonzo</who>
    <bug_when>2009-07-06 04:39:22 -0700</bug_when>
    <thetext>(In reply to comment #0)
&gt; Hi,
&gt; style properties (as read with javascript) depend on locale.
&gt; For example, following piece of code:
&gt; 
&gt;     p.style.width = &apos;100.5px&apos;;
&gt;     alert(p.style.width);
&gt; 
&gt; show 100,5px with  a french locale and 100.5px with an english locale (decimal
&gt; separator is not the same).
&gt; That makes comparaison and parsing of those results nearly impossible in a
&gt; cross-locale way.
&gt; Moreover, as parseFloat is not locale dependant, 
&gt; 
&gt; p.style.opacity = 0.5;
&gt; parseFloat(p.style.opacity);
&gt; 
&gt; shows 0 with a french locale and 0.5 with an english locale.
&gt; That&apos;s quite disturbing.
&gt; 
&gt; Setting to gtk component as I don&apos;t known if it happens with other backends.

*** This bug has been marked as a duplicate of bug 18994 ***</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>32282</attachid>
            <date>2009-07-05 14:07:00 -0700</date>
            <delta_ts>2009-07-05 14:07:00 -0700</delta_ts>
            <desc>testcase</desc>
            <filename>webkit_style_properties_depend_on_locale.html</filename>
            <type>text/html</type>
            <size>476</size>
            <attacher name="arno.">a.renevier</attacher>
            
              <data encoding="base64">PGh0bWw+CjxoZWFkPgo8dGl0bGU+c3R5bGUgcHJvcGVydHkgZGVwZW5kIG9uIGxvY2FsZTwvdGl0
bGU+CjxzdHlsZSB0eXBlPSJ0ZXh0L2NzcyI+Cjwvc3R5bGU+CjxzY3JpcHQ+CmZ1bmN0aW9uIGlu
aXQoKSB7CiAgICB2YXIgcCA9IGRvY3VtZW50LmdldEVsZW1lbnRCeUlkKCdtYWluJyk7CiAgICBw
LnN0eWxlLm9wYWNpdHkgPSAwLjU7CiAgICBkb2N1bWVudC5nZXRFbGVtZW50QnlJZCgncmVzJyku
dGV4dENvbnRlbnQgPSBwYXJzZUZsb2F0KHAuc3R5bGUub3BhY2l0eSk7Cn0KPC9zY3JpcHQ+Cjwv
aGVhZD4KPGJvZHkgb25sb2FkPSJpbml0KCkiPgo8cCBpZD0ibWFpbiI+CjwvcD4KPHA+CkJlbG93
IGlzIHJlc3VsdCBvZiBvcGFjaXR5IGFzIGNoZWNrZWQgd2l0aCBlbGVtZW50LnN0eWxlLm9wYWNp
dHkuIEl0IHNob3VsZCBiZSA8c3Ryb25nPjAuNTwvc3Ryb25nPgo8L3A+CjxwIGlkPSJyZXMiPgo8
L3A+CjwvYm9keT4KPC9odG1sPgo=
</data>

          </attachment>
      

    </bug>

</bugzilla>