summaryrefslogtreecommitdiffstats
path: root/src/main/java/com/kitfox/svg/animation
diff options
context:
space:
mode:
authorkitfox2013-03-19 06:20:37 +0100
committerkitfox2013-03-19 06:20:37 +0100
commit6776ed9f1a81e517139d85eb6d2e28911fd0fc35 (patch)
treee169f598f518670f5434d75d1b76ceb3c0765d32 /src/main/java/com/kitfox/svg/animation
parentError handling now sends warnings to Logger. (diff)
downloadsvg-salamander-core-6776ed9f1a81e517139d85eb6d2e28911fd0fc35.tar.gz
svg-salamander-core-6776ed9f1a81e517139d85eb6d2e28911fd0fc35.tar.xz
svg-salamander-core-6776ed9f1a81e517139d85eb6d2e28911fd0fc35.zip
Adding support for style sheets.
git-svn-id: https://svn.java.net/svn/svgsalamander~svn/trunk/svg-core@153 7dc7fa77-23fb-e6ad-8e2e-c86bd48ed22b
Diffstat (limited to 'src/main/java/com/kitfox/svg/animation')
-rw-r--r--src/main/java/com/kitfox/svg/animation/Animate.java9
-rw-r--r--src/main/java/com/kitfox/svg/animation/AnimateColor.java9
-rw-r--r--src/main/java/com/kitfox/svg/animation/AnimateMotion.java9
-rw-r--r--src/main/java/com/kitfox/svg/animation/AnimateTransform.java7
-rw-r--r--src/main/java/com/kitfox/svg/animation/SetSmil.java9
5 files changed, 39 insertions, 4 deletions
diff --git a/src/main/java/com/kitfox/svg/animation/Animate.java b/src/main/java/com/kitfox/svg/animation/Animate.java
index d65bdfc..3ef5287 100644
--- a/src/main/java/com/kitfox/svg/animation/Animate.java
+++ b/src/main/java/com/kitfox/svg/animation/Animate.java
@@ -60,6 +60,8 @@ import org.xml.sax.SAXException;
*/
public class Animate extends AnimateBase implements AnimateColorIface
{
+ public static final String TAG_NAME = "animate";
+
// StyleAttribute retAttrib = new StyleAttribute
public static final int DT_REAL = 0;
public static final int DT_COLOR = 1;
@@ -81,7 +83,12 @@ public class Animate extends AnimateBase implements AnimateColorIface
public Animate()
{
}
-
+
+ public String getTagName()
+ {
+ return TAG_NAME;
+ }
+
public int getDataType()
{
return dataType;
diff --git a/src/main/java/com/kitfox/svg/animation/AnimateColor.java b/src/main/java/com/kitfox/svg/animation/AnimateColor.java
index a5f59f8..a88bbdc 100644
--- a/src/main/java/com/kitfox/svg/animation/AnimateColor.java
+++ b/src/main/java/com/kitfox/svg/animation/AnimateColor.java
@@ -53,6 +53,8 @@ import org.xml.sax.SAXException;
*/
public class AnimateColor extends AnimateBase implements AnimateColorIface
{
+ public static final String TAG_NAME = "animateColor";
+
protected Color fromValue;
protected Color toValue;
@@ -61,7 +63,12 @@ public class AnimateColor extends AnimateBase implements AnimateColorIface
public AnimateColor()
{
}
-
+
+ public String getTagName()
+ {
+ return TAG_NAME;
+ }
+
public void loaderStartElement(SVGLoaderHelper helper, Attributes attrs, SVGElement parent) throws SAXException
{
//Load style string
diff --git a/src/main/java/com/kitfox/svg/animation/AnimateMotion.java b/src/main/java/com/kitfox/svg/animation/AnimateMotion.java
index 8d3fa3a..8b543d5 100644
--- a/src/main/java/com/kitfox/svg/animation/AnimateMotion.java
+++ b/src/main/java/com/kitfox/svg/animation/AnimateMotion.java
@@ -59,6 +59,8 @@ import org.xml.sax.SAXException;
*/
public class AnimateMotion extends AnimateXform
{
+ public static final String TAG_NAME = "animateMotion";
+
static final Matcher matchPoint = Pattern.compile("\\s*(\\d+)[^\\d]+(\\d+)\\s*").matcher("");
// protected double fromValue;
@@ -77,7 +79,12 @@ public class AnimateMotion extends AnimateXform
public AnimateMotion()
{
}
-
+
+ public String getTagName()
+ {
+ return TAG_NAME;
+ }
+
public void loaderStartElement(SVGLoaderHelper helper, Attributes attrs, SVGElement parent) throws SAXException
{
//Load style string
diff --git a/src/main/java/com/kitfox/svg/animation/AnimateTransform.java b/src/main/java/com/kitfox/svg/animation/AnimateTransform.java
index 1857f55..808ef54 100644
--- a/src/main/java/com/kitfox/svg/animation/AnimateTransform.java
+++ b/src/main/java/com/kitfox/svg/animation/AnimateTransform.java
@@ -54,6 +54,8 @@ import org.xml.sax.SAXException;
*/
public class AnimateTransform extends AnimateXform
{
+ public static final String TAG_NAME = "animateTransform";
+
// protected AffineTransform fromValue;
// protected AffineTransform toValue;
// protected double[] fromValue; //Transform parameters
@@ -80,6 +82,11 @@ public class AnimateTransform extends AnimateXform
{
}
+ public String getTagName()
+ {
+ return TAG_NAME;
+ }
+
public void loaderStartElement(SVGLoaderHelper helper, Attributes attrs, SVGElement parent) throws SAXException
{
//Load style string
diff --git a/src/main/java/com/kitfox/svg/animation/SetSmil.java b/src/main/java/com/kitfox/svg/animation/SetSmil.java
index 24a4bc0..2073456 100644
--- a/src/main/java/com/kitfox/svg/animation/SetSmil.java
+++ b/src/main/java/com/kitfox/svg/animation/SetSmil.java
@@ -53,13 +53,20 @@ import org.xml.sax.SAXException;
*/
public class SetSmil extends AnimationElement
{
+ public static final String TAG_NAME = "set";
+
String toValue;
/** Creates a new instance of Set */
public SetSmil()
{
}
-
+
+ public String getTagName()
+ {
+ return TAG_NAME;
+ }
+
public void loaderStartElement(SVGLoaderHelper helper, Attributes attrs, SVGElement parent) throws SAXException
{
//Load style string