diff options
author | kitfox | 2012-07-01 01:29:48 +0200 |
---|---|---|
committer | kitfox | 2012-07-01 01:29:48 +0200 |
commit | e849b75e104c123523209e51e332a37c337b5da3 (patch) | |
tree | d86993933a35b0b2997a94b6afa838c5021fd14b | |
parent | Support for non-scaling stroke added. (diff) | |
download | svg-salamander-core-e849b75e104c123523209e51e332a37c337b5da3.tar.gz svg-salamander-core-e849b75e104c123523209e51e332a37c337b5da3.tar.xz svg-salamander-core-e849b75e104c123523209e51e332a37c337b5da3.zip |
Can now safely update trees that contain embedded images.
git-svn-id: https://svn.java.net/svn/svgsalamander~svn/trunk/svg-core@114 7dc7fa77-23fb-e6ad-8e2e-c86bd48ed22b
-rw-r--r-- | src/main/java/com/kitfox/svg/ImageSVG.java | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/main/java/com/kitfox/svg/ImageSVG.java b/src/main/java/com/kitfox/svg/ImageSVG.java index eb25586..cfe3309 100644 --- a/src/main/java/com/kitfox/svg/ImageSVG.java +++ b/src/main/java/com/kitfox/svg/ImageSVG.java @@ -254,7 +254,16 @@ public class ImageSVG extends RenderableElement if (getPres(sty.setName("xlink:href")))
{
URI src = sty.getURIValue(getXMLBase());
- URL newVal = src.toURL();
+
+ URL newVal;
+ if ("data".equals(src.getScheme()))
+ {
+ newVal = new URL(null, src.toASCIIString(), new Handler());
+ }
+ else
+ {
+ newVal = src.toURL();
+ }
if (!newVal.equals(imageSrc))
{
|