[Webkit-unassigned] [Bug 16305] New: Width of svg elements not applied to container elements

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Dec 5 02:37:22 PST 2007


http://bugs.webkit.org/show_bug.cgi?id=16305

           Summary: Width of svg elements not applied to container elements
           Product: WebKit
           Version: 523.x (Safari 3)
          Platform: PC
        OS/Version: Windows XP
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: SVG
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: yoah at google.com


When adding svg element into the dom, the width of the element is not applied
to the width of it's parent (the height is properly applied). Included is a
simple example where an svg element is added into a table cell. Note that the
row height is correctly set, but the cell width is not.

<!DOCTYPE HTML>
<html>
<head>
  <title>WebKit SVG Bug</title>
  <script type="text/javascript">
    function draw() {
      var NS = "http://www.w3.org/2000/svg";
      var s = document.createElementNS(NS, "svg");
      s.setAttribute("width", 400);
      s.setAttribute("height", 200);

      var rect = document.createElementNS(NS, "rect");
      rect.setAttribute("x", "0");
      rect.setAttribute("y", "0");
      rect.setAttribute("width", "400");
      rect.setAttribute("height", "200");
      rect.setAttribute("fill", "yellow");

      s.appendChild(rect);
      document.getElementById("d").appendChild(s);
   }
  </script>

</head>

<body onload="draw()">
<table border="1">
  <tr>
    <td>X</td>
    <td id="d"></td>
  </tr>
</table>
</body>
</html>


-- 
Configure bugmail: http://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list