org.apache.batik.dom.anim

Interface AnimationTarget

public interface AnimationTarget

An interface for targets of animation to provide context information.
Field Summary
shortPERCENTAGE_FONT_SIZE
shortPERCENTAGE_VIEWPORT_HEIGHT
shortPERCENTAGE_VIEWPORT_SIZE
shortPERCENTAGE_VIEWPORT_WIDTH
Method Summary
voidaddTargetListener(String ns, String an, boolean isCSS, AnimationTargetListener l)
Adds a listener for changes to the given attribute value.
ElementgetElement()
Returns the element.
shortgetPercentageInterpretation(String ns, String an, boolean isCSS)
Gets how percentage values are interpreted by the given attribute or property.
AnimatableValuegetUnderlyingValue(String ns, String ln)
Returns the underlying value of an animatable XML attribute.
voidremoveTargetListener(String ns, String an, boolean isCSS, AnimationTargetListener l)
Removes a listener for changes to the given attribute value.
floatsvgToUserSpace(float v, short type, short pcInterp)
Converts the given SVG length into user units.
voidupdateAttributeValue(String ns, String ln, AnimatableValue val)
Updates an attribute value in this target.
voidupdateOtherValue(String type, AnimatableValue val)
Updates a 'other' animation value in this target.
voidupdatePropertyValue(String pn, AnimatableValue val)
Updates a property value in this target.
booleanuseLinearRGBColorInterpolation()
Returns whether color interpolations should be done in linear RGB color space rather than sRGB.

Field Detail

PERCENTAGE_FONT_SIZE

public short PERCENTAGE_FONT_SIZE

PERCENTAGE_VIEWPORT_HEIGHT

public short PERCENTAGE_VIEWPORT_HEIGHT

PERCENTAGE_VIEWPORT_SIZE

public short PERCENTAGE_VIEWPORT_SIZE

PERCENTAGE_VIEWPORT_WIDTH

public short PERCENTAGE_VIEWPORT_WIDTH

Method Detail

addTargetListener

public void addTargetListener(String ns, String an, boolean isCSS, AnimationTargetListener l)
Adds a listener for changes to the given attribute value.

getElement

public Element getElement()
Returns the element.

getPercentageInterpretation

public short getPercentageInterpretation(String ns, String an, boolean isCSS)
Gets how percentage values are interpreted by the given attribute or property.

getUnderlyingValue

public AnimatableValue getUnderlyingValue(String ns, String ln)
Returns the underlying value of an animatable XML attribute.

removeTargetListener

public void removeTargetListener(String ns, String an, boolean isCSS, AnimationTargetListener l)
Removes a listener for changes to the given attribute value.

svgToUserSpace

public float svgToUserSpace(float v, short type, short pcInterp)
Converts the given SVG length into user units.

Parameters: v the SVG length value type the SVG length units (one of the SVGLength.SVG_LENGTH_* constants) pcInterp how to interpretet percentage values (one of the AnimationTarget.PERCENTAGE_* constants)

Returns: the SVG value in user units

updateAttributeValue

public void updateAttributeValue(String ns, String ln, AnimatableValue val)
Updates an attribute value in this target.

updateOtherValue

public void updateOtherValue(String type, AnimatableValue val)
Updates a 'other' animation value in this target.

updatePropertyValue

public void updatePropertyValue(String pn, AnimatableValue val)
Updates a property value in this target.

useLinearRGBColorInterpolation

public boolean useLinearRGBColorInterpolation()
Returns whether color interpolations should be done in linear RGB color space rather than sRGB.
Copyright B) 2008 Apache Software Foundation. All Rights Reserved.