[Webkit-unassigned] [Bug 245927] New: font-size treats <number> as pixels in standard mode when previously specified on SVG/MathML

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sat Oct 1 00:59:32 PDT 2022


https://bugs.webkit.org/show_bug.cgi?id=245927

            Bug ID: 245927
           Summary: font-size treats <number> as pixels in standard mode
                    when previously specified on SVG/MathML
           Product: WebKit
           Version: WebKit Nightly Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: CSS
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: fred.wang at free.fr

Created attachment 462746

  --> https://bugs.webkit.org/attachment.cgi?id=462746&action=review

Testcase

See the attached test case. Document is in standard mode and has a font-size of 100px. The first div contains some HTML, MathML and SVG elements having <number> font-size values, respectively 50, 75 and 33.33333. The second div contains some <span>s with the same <number> font-size values. Those corresponding matching the ones previously specified on the MathML and SVG elements (75 and 33.33333) are interpreted as pixels rather than being treated as invalid (and so taking the inherited 100px value):

<!DOCTYPE html>
<body style="font-size: 100px">
  <div>
    <div style="font-size: 50"></div>
    <math style="font-size: 75"></math>
    <svg style="font-size: 33.33333"></svg>
  </div>
  <div>
    <span>100</span>
    <span style="font-size: 50">50</span>
    <span style="font-size: 75">75</span>
    <span style="font-size: 33.33333">33.33333</span>
  </div>
</body>

Chromium and WebKit behaves that way, but Firefox renders all the elements with a font-size of 100 pixels.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20221001/6527b69e/attachment.htm>


More information about the webkit-unassigned mailing list