<?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>11089</bug_id>
          
          <creation_ts>2006-09-29 09:44:53 -0700</creation_ts>
          <short_desc>GoogleDocs: Subscript/Superscript text isn&apos;t the correct font size</short_desc>
          <delta_ts>2017-07-18 08:30:31 -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>HTML Editing</component>
          <version>420+</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>GoogleBug, InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>7712</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Chris Petersen">c.petersen87</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>abob</cc>
    
    <cc>enrica</cc>
    
    <cc>jparent</cc>
    
    <cc>justin.garcia</cc>
    
    <cc>mjs</cc>
    
    <cc>rniwa</cc>
    
    <cc>tony</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>56786</commentid>
    <comment_count>0</comment_count>
    <who name="Chris Petersen">c.petersen87</who>
    <bug_when>2006-09-29 09:44:53 -0700</bug_when>
    <thetext>Summary:

After applying Superscript or SubScript styling to text, the text doesn&apos;t have the correct font size applied. The text should appear in a smaller font size but still has the original font size applied.


Steps to Reproduce:

1) With TOT Webkit r16622, login into writely.com
2) Create a new document ( Click New link)
3) Type some text in the document body and select a portion of this text
4) From the writely toolbar, select SuperScript or Subscript
5) Style is applied but text size is wrong


Expected Results:

Subscript or Superscript text should be displayed in a smaller font size but isn&apos;t.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>56802</commentid>
    <comment_count>1</comment_count>
    <who name="Chris Petersen">c.petersen87</who>
    <bug_when>2006-09-29 11:29:11 -0700</bug_when>
    <thetext>This is covered in &lt;rdar://problem/4757693&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>285590</commentid>
    <comment_count>2</comment_count>
    <who name="Ryosuke Niwa">rniwa</who>
    <bug_when>2010-09-27 11:12:29 -0700</bug_when>
    <thetext>I think this bug is due to the fact we just add vertical-align: sub or vertical-align: up when applying subscript or superscript.  Firefox adds sub/sup even when StyleWithCSS=true to avoid this problem.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>285633</commentid>
    <comment_count>3</comment_count>
    <who name="Ryosuke Niwa">rniwa</who>
    <bug_when>2010-09-27 11:41:06 -0700</bug_when>
    <thetext>Sorry my comment wasn&apos;t clear.  Firefox adds sub/sup elements as supposed to adding vertical-align: sub or vertical-align: super, which is what WebKit currently does.

I think Firefox&apos;s behavior is the best we can do because if we were to add font-size: small with vertical-align, we cannot tell whether the font-size is user-specified or the one assigned along with vertical-align.  We could introduce yet-another-class like WebKit-vertical-align-span to deal with this kind of situation but font-size could easily be pushed to other styles, and I don&apos;t think we can track all possible ways in which font-size can be propagated.

Modifying WebKit to always use sub/sup elements is an easy fix because we can just modify StyleChange to always extract vertical-align property regardless of the value of styleWithCSS.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>285756</commentid>
    <comment_count>4</comment_count>
    <who name="Julie Parent">jparent</who>
    <bug_when>2010-09-27 14:42:05 -0700</bug_when>
    <thetext>IE also uses sup/sub, so changing WebKit to be consistent with both IE and FF sounds reasonable.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>291334</commentid>
    <comment_count>5</comment_count>
    <who name="Ryosuke Niwa">rniwa</who>
    <bug_when>2010-10-07 17:01:59 -0700</bug_when>
    <thetext>(In reply to comment #3)
&gt; Modifying WebKit to always use sub/sup elements is an easy fix because we can just modify StyleChange to always extract vertical-align property regardless of the value of styleWithCSS.

Maybe this is not as simple as I initially thought.  It&apos;s quite possible that vertical-align is specified by itself and passed to ApplyStyleCommand for style preservation purposes.  If I make the above change, then we&apos;ll end up converting all of that to sub/sup, which seems wrong.  We could applyElement(sub/sup) to work-around this but then we&apos;ll fail to remove existing styles.  The only possible work-around I can think of right now is to pass both vertical-align and sub/sup element but I don&apos;t think this has never done before and it might have weird bugs.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>