<html>
<head>
<base href="https://bugs.webkit.org/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Previously loaded SVG with no intrinsic size scaled with the viewBox size when drawn on canvas"
href="https://bugs.webkit.org/show_bug.cgi?id=148845">148845</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Previously loaded SVG with no intrinsic size scaled with the viewBox size when drawn on canvas
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr>
<tr>
<th>Product</th>
<td>WebKit
</td>
</tr>
<tr>
<th>Version</th>
<td>WebKit Nightly Build
</td>
</tr>
<tr>
<th>Hardware</th>
<td>Unspecified
</td>
</tr>
<tr>
<th>OS</th>
<td>Unspecified
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>Normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P2
</td>
</tr>
<tr>
<th>Component</th>
<td>SVG
</td>
</tr>
<tr>
<th>Assignee</th>
<td>webkit-unassigned@lists.webkit.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>sabouhallawa@apple.com
</td>
</tr>
<tr>
<th>CC</th>
<td>zimmermann@kde.org
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=260645" name="attach_260645" title="test case">attachment 260645</a> <a href="attachment.cgi?id=260645&action=edit" title="test case">[details]</a></span>
test case
Open the attached test case.
Result: Two rectangles are drawn. The first one is 10x10 and the second one is 100x100.
Expected: The two rectangles should have size of 100x100.
Notes:
1. The first rectangle is an <img> tag. Its size is 100x100 and its src is set to a a data uri SVG.
3. The second rectangle is a canvas which loads the same data uri SVG and draws it to a rectangle of 100x100.
2. The SVG does not have an intrinsic size. But it has a viewBox of "0 0 1000 1000".
The bug does not happen with the same test case if any of the following happens:
1. The <img> tag is removed (so the canvas does not get the image resource from the cache).
2. The data uri SVG has an intrinsic size.
3. The viewBox is "0 0 100 100".</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>