[Webkit-unassigned] [Bug 266826] New: SVG in an iframe is incorrectly scaled instead of allowing scrolling

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Dec 22 16:14:04 PST 2023


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

            Bug ID: 266826
           Summary: SVG in an iframe is incorrectly scaled instead of
                    allowing scrolling
           Product: WebKit
           Version: Safari 17
          Hardware: All
                OS: All
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: SVG
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: tarquinwj at gmail.com
                CC: sabouhallawa at apple.com, zimmermann at kde.org

Created attachment 469181

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

HTML part of the testcase

Make a very wide SVG .svg file (eg. 10000px). Use height and width attributes, and viewbox to make it big.
Make a HTML page, and use an <iframe> to embed the SVG in the HTML page.
Use whatever approaches you can to try to make the SVG display in its native resolution.

Safari (tested 15-17 on Sonoma-Monterey, and 15 on iOS) is the only browser that scales the image so small that it is unusable, and refuses to allow it to display in its native size. All others show it at the correct size, and you scroll to see the rest.

I have tried using xhtml:meta viewport in the SVG, which has no effect. I have tried setting object-fit:none; which is ignored. I have tried using CSS to explicitly set the size. Nothing seems to work. It appears to be impossible to make the iframe scrollable when it is displaying an SVG file.

http://www.howtocreate.co.uk/working/svgscaling.html

-- 
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/20231223/6b8b9acf/attachment.htm>


More information about the webkit-unassigned mailing list