- From: Lennart Borgman <lennart.borgman@gmail.com>
- Date: Thu, 24 Jul 2014 00:09:40 +0200
- To: www-svg@w3.org
Received on Wednesday, 23 July 2014 22:10:48 UTC
Dear SVG working group! I just tried to access a sheet in a style added to an svg element: var theSvg = document.createElementNS("http://www.w3.org/2000/svg", "svg"); var theStyle = document.createElementNS("http://www.w3.org/2000/svg", "style"); theSvg.appendChild(theStyle); console.log("theStyle.sheet=", theStyle.sheet); // undefined, try adding svg to DOM document.body.appendChild(theSvg); console.log("theStyle.sheet=", theStyle.sheet); // still undefined As you can see this failed. I have little knowledge of this subject, but was directed here from my question here: http://stackoverflow.com/questions/24920186/how-do-i-create-a-style-sheet-for-an-svg-element I am not sure if a specification is lacking here or if this is a bug in the browsers implementation. However this must of course be a part of the specification for using CSS with SVG. Kind regards, L
Received on Wednesday, 23 July 2014 22:10:48 UTC