gecko/dom/svg/SVGContentUtils.cpp
Birunthan Mohanathas 1dcfd79ff9 Bug 946065 - Part 9: Move content/svg/ to dom/ and flatten subdirectories. r=jwatt
--HG--
rename : content/svg/content/src/DOMSVGAnimatedLengthList.cpp => dom/svg/DOMSVGAnimatedLengthList.cpp
rename : content/svg/content/src/DOMSVGAnimatedLengthList.h => dom/svg/DOMSVGAnimatedLengthList.h
rename : content/svg/content/src/DOMSVGAnimatedNumberList.cpp => dom/svg/DOMSVGAnimatedNumberList.cpp
rename : content/svg/content/src/DOMSVGAnimatedNumberList.h => dom/svg/DOMSVGAnimatedNumberList.h
rename : content/svg/content/src/DOMSVGLength.cpp => dom/svg/DOMSVGLength.cpp
rename : content/svg/content/src/DOMSVGLength.h => dom/svg/DOMSVGLength.h
rename : content/svg/content/src/DOMSVGLengthList.cpp => dom/svg/DOMSVGLengthList.cpp
rename : content/svg/content/src/DOMSVGLengthList.h => dom/svg/DOMSVGLengthList.h
rename : content/svg/content/src/DOMSVGNumber.cpp => dom/svg/DOMSVGNumber.cpp
rename : content/svg/content/src/DOMSVGNumber.h => dom/svg/DOMSVGNumber.h
rename : content/svg/content/src/DOMSVGNumberList.cpp => dom/svg/DOMSVGNumberList.cpp
rename : content/svg/content/src/DOMSVGNumberList.h => dom/svg/DOMSVGNumberList.h
rename : content/svg/content/src/DOMSVGPathSeg.cpp => dom/svg/DOMSVGPathSeg.cpp
rename : content/svg/content/src/DOMSVGPathSeg.h => dom/svg/DOMSVGPathSeg.h
rename : content/svg/content/src/DOMSVGPathSegList.cpp => dom/svg/DOMSVGPathSegList.cpp
rename : content/svg/content/src/DOMSVGPathSegList.h => dom/svg/DOMSVGPathSegList.h
rename : content/svg/content/src/DOMSVGPoint.cpp => dom/svg/DOMSVGPoint.cpp
rename : content/svg/content/src/DOMSVGPoint.h => dom/svg/DOMSVGPoint.h
rename : content/svg/content/src/DOMSVGPointList.cpp => dom/svg/DOMSVGPointList.cpp
rename : content/svg/content/src/DOMSVGPointList.h => dom/svg/DOMSVGPointList.h
rename : content/svg/content/src/DOMSVGStringList.cpp => dom/svg/DOMSVGStringList.cpp
rename : content/svg/content/src/DOMSVGStringList.h => dom/svg/DOMSVGStringList.h
rename : content/svg/content/src/DOMSVGTransformList.cpp => dom/svg/DOMSVGTransformList.cpp
rename : content/svg/content/src/DOMSVGTransformList.h => dom/svg/DOMSVGTransformList.h
rename : content/svg/content/src/SVGAElement.cpp => dom/svg/SVGAElement.cpp
rename : content/svg/content/src/SVGAElement.h => dom/svg/SVGAElement.h
rename : content/svg/content/src/SVGAltGlyphElement.cpp => dom/svg/SVGAltGlyphElement.cpp
rename : content/svg/content/src/SVGAltGlyphElement.h => dom/svg/SVGAltGlyphElement.h
rename : content/svg/content/src/SVGAngle.cpp => dom/svg/SVGAngle.cpp
rename : content/svg/content/src/SVGAngle.h => dom/svg/SVGAngle.h
rename : content/svg/content/src/SVGAnimateElement.cpp => dom/svg/SVGAnimateElement.cpp
rename : content/svg/content/src/SVGAnimateElement.h => dom/svg/SVGAnimateElement.h
rename : content/svg/content/src/SVGAnimateMotionElement.cpp => dom/svg/SVGAnimateMotionElement.cpp
rename : content/svg/content/src/SVGAnimateMotionElement.h => dom/svg/SVGAnimateMotionElement.h
rename : content/svg/content/src/SVGAnimateTransformElement.cpp => dom/svg/SVGAnimateTransformElement.cpp
rename : content/svg/content/src/SVGAnimateTransformElement.h => dom/svg/SVGAnimateTransformElement.h
rename : content/svg/content/src/SVGAnimatedAngle.cpp => dom/svg/SVGAnimatedAngle.cpp
rename : content/svg/content/src/SVGAnimatedAngle.h => dom/svg/SVGAnimatedAngle.h
rename : content/svg/content/src/SVGAnimatedBoolean.cpp => dom/svg/SVGAnimatedBoolean.cpp
rename : content/svg/content/src/SVGAnimatedBoolean.h => dom/svg/SVGAnimatedBoolean.h
rename : content/svg/content/src/SVGAnimatedEnumeration.cpp => dom/svg/SVGAnimatedEnumeration.cpp
rename : content/svg/content/src/SVGAnimatedEnumeration.h => dom/svg/SVGAnimatedEnumeration.h
rename : content/svg/content/src/SVGAnimatedInteger.cpp => dom/svg/SVGAnimatedInteger.cpp
rename : content/svg/content/src/SVGAnimatedInteger.h => dom/svg/SVGAnimatedInteger.h
rename : content/svg/content/src/SVGAnimatedLength.cpp => dom/svg/SVGAnimatedLength.cpp
rename : content/svg/content/src/SVGAnimatedLength.h => dom/svg/SVGAnimatedLength.h
rename : content/svg/content/src/SVGAnimatedLengthList.cpp => dom/svg/SVGAnimatedLengthList.cpp
rename : content/svg/content/src/SVGAnimatedLengthList.h => dom/svg/SVGAnimatedLengthList.h
rename : content/svg/content/src/SVGAnimatedNumber.cpp => dom/svg/SVGAnimatedNumber.cpp
rename : content/svg/content/src/SVGAnimatedNumber.h => dom/svg/SVGAnimatedNumber.h
rename : content/svg/content/src/SVGAnimatedNumberList.cpp => dom/svg/SVGAnimatedNumberList.cpp
rename : content/svg/content/src/SVGAnimatedNumberList.h => dom/svg/SVGAnimatedNumberList.h
rename : content/svg/content/src/SVGAnimatedPathSegList.cpp => dom/svg/SVGAnimatedPathSegList.cpp
rename : content/svg/content/src/SVGAnimatedPathSegList.h => dom/svg/SVGAnimatedPathSegList.h
rename : content/svg/content/src/SVGAnimatedPointList.cpp => dom/svg/SVGAnimatedPointList.cpp
rename : content/svg/content/src/SVGAnimatedPointList.h => dom/svg/SVGAnimatedPointList.h
rename : content/svg/content/src/SVGAnimatedPreserveAspectRatio.cpp => dom/svg/SVGAnimatedPreserveAspectRatio.cpp
rename : content/svg/content/src/SVGAnimatedPreserveAspectRatio.h => dom/svg/SVGAnimatedPreserveAspectRatio.h
rename : content/svg/content/src/SVGAnimatedRect.cpp => dom/svg/SVGAnimatedRect.cpp
rename : content/svg/content/src/SVGAnimatedRect.h => dom/svg/SVGAnimatedRect.h
rename : content/svg/content/src/SVGAnimatedString.cpp => dom/svg/SVGAnimatedString.cpp
rename : content/svg/content/src/SVGAnimatedString.h => dom/svg/SVGAnimatedString.h
rename : content/svg/content/src/SVGAnimatedTransformList.cpp => dom/svg/SVGAnimatedTransformList.cpp
rename : content/svg/content/src/SVGAnimatedTransformList.h => dom/svg/SVGAnimatedTransformList.h
rename : content/svg/content/src/SVGAnimationElement.cpp => dom/svg/SVGAnimationElement.cpp
rename : content/svg/content/src/SVGAnimationElement.h => dom/svg/SVGAnimationElement.h
rename : content/svg/content/src/SVGAttrValueWrapper.cpp => dom/svg/SVGAttrValueWrapper.cpp
rename : content/svg/content/src/SVGAttrValueWrapper.h => dom/svg/SVGAttrValueWrapper.h
rename : content/svg/content/src/SVGCircleElement.cpp => dom/svg/SVGCircleElement.cpp
rename : content/svg/content/src/SVGCircleElement.h => dom/svg/SVGCircleElement.h
rename : content/svg/content/src/SVGClipPathElement.cpp => dom/svg/SVGClipPathElement.cpp
rename : content/svg/content/src/SVGClipPathElement.h => dom/svg/SVGClipPathElement.h
rename : content/svg/content/src/SVGComponentTransferFunctionElement.h => dom/svg/SVGComponentTransferFunctionElement.h
rename : content/svg/content/src/SVGContentUtils.cpp => dom/svg/SVGContentUtils.cpp
rename : content/svg/content/src/SVGContentUtils.h => dom/svg/SVGContentUtils.h
rename : content/svg/content/src/SVGDefsElement.cpp => dom/svg/SVGDefsElement.cpp
rename : content/svg/content/src/SVGDefsElement.h => dom/svg/SVGDefsElement.h
rename : content/svg/content/src/SVGDescElement.cpp => dom/svg/SVGDescElement.cpp
rename : content/svg/content/src/SVGDescElement.h => dom/svg/SVGDescElement.h
rename : content/svg/document/src/SVGDocument.cpp => dom/svg/SVGDocument.cpp
rename : content/svg/document/src/SVGDocument.h => dom/svg/SVGDocument.h
rename : content/svg/content/src/SVGElementFactory.cpp => dom/svg/SVGElementFactory.cpp
rename : content/svg/content/src/SVGElementFactory.h => dom/svg/SVGElementFactory.h
rename : content/svg/content/src/SVGEllipseElement.cpp => dom/svg/SVGEllipseElement.cpp
rename : content/svg/content/src/SVGEllipseElement.h => dom/svg/SVGEllipseElement.h
rename : content/svg/content/src/SVGFEBlendElement.cpp => dom/svg/SVGFEBlendElement.cpp
rename : content/svg/content/src/SVGFEBlendElement.h => dom/svg/SVGFEBlendElement.h
rename : content/svg/content/src/SVGFEColorMatrixElement.cpp => dom/svg/SVGFEColorMatrixElement.cpp
rename : content/svg/content/src/SVGFEColorMatrixElement.h => dom/svg/SVGFEColorMatrixElement.h
rename : content/svg/content/src/SVGFEComponentTransferElement.cpp => dom/svg/SVGFEComponentTransferElement.cpp
rename : content/svg/content/src/SVGFEComponentTransferElement.h => dom/svg/SVGFEComponentTransferElement.h
rename : content/svg/content/src/SVGFECompositeElement.cpp => dom/svg/SVGFECompositeElement.cpp
rename : content/svg/content/src/SVGFECompositeElement.h => dom/svg/SVGFECompositeElement.h
rename : content/svg/content/src/SVGFEConvolveMatrixElement.cpp => dom/svg/SVGFEConvolveMatrixElement.cpp
rename : content/svg/content/src/SVGFEConvolveMatrixElement.h => dom/svg/SVGFEConvolveMatrixElement.h
rename : content/svg/content/src/SVGFEDiffuseLightingElement.cpp => dom/svg/SVGFEDiffuseLightingElement.cpp
rename : content/svg/content/src/SVGFEDiffuseLightingElement.h => dom/svg/SVGFEDiffuseLightingElement.h
rename : content/svg/content/src/SVGFEDisplacementMapElement.cpp => dom/svg/SVGFEDisplacementMapElement.cpp
rename : content/svg/content/src/SVGFEDisplacementMapElement.h => dom/svg/SVGFEDisplacementMapElement.h
rename : content/svg/content/src/SVGFEDistantLightElement.cpp => dom/svg/SVGFEDistantLightElement.cpp
rename : content/svg/content/src/SVGFEDistantLightElement.h => dom/svg/SVGFEDistantLightElement.h
rename : content/svg/content/src/SVGFEDropShadowElement.cpp => dom/svg/SVGFEDropShadowElement.cpp
rename : content/svg/content/src/SVGFEDropShadowElement.h => dom/svg/SVGFEDropShadowElement.h
rename : content/svg/content/src/SVGFEFloodElement.cpp => dom/svg/SVGFEFloodElement.cpp
rename : content/svg/content/src/SVGFEFloodElement.h => dom/svg/SVGFEFloodElement.h
rename : content/svg/content/src/SVGFEGaussianBlurElement.cpp => dom/svg/SVGFEGaussianBlurElement.cpp
rename : content/svg/content/src/SVGFEGaussianBlurElement.h => dom/svg/SVGFEGaussianBlurElement.h
rename : content/svg/content/src/SVGFEImageElement.cpp => dom/svg/SVGFEImageElement.cpp
rename : content/svg/content/src/SVGFEImageElement.h => dom/svg/SVGFEImageElement.h
rename : content/svg/content/src/SVGFEMergeElement.cpp => dom/svg/SVGFEMergeElement.cpp
rename : content/svg/content/src/SVGFEMergeElement.h => dom/svg/SVGFEMergeElement.h
rename : content/svg/content/src/SVGFEMergeNodeElement.cpp => dom/svg/SVGFEMergeNodeElement.cpp
rename : content/svg/content/src/SVGFEMergeNodeElement.h => dom/svg/SVGFEMergeNodeElement.h
rename : content/svg/content/src/SVGFEMorphologyElement.cpp => dom/svg/SVGFEMorphologyElement.cpp
rename : content/svg/content/src/SVGFEMorphologyElement.h => dom/svg/SVGFEMorphologyElement.h
rename : content/svg/content/src/SVGFEOffsetElement.cpp => dom/svg/SVGFEOffsetElement.cpp
rename : content/svg/content/src/SVGFEOffsetElement.h => dom/svg/SVGFEOffsetElement.h
rename : content/svg/content/src/SVGFEPointLightElement.cpp => dom/svg/SVGFEPointLightElement.cpp
rename : content/svg/content/src/SVGFEPointLightElement.h => dom/svg/SVGFEPointLightElement.h
rename : content/svg/content/src/SVGFESpecularLightingElement.cpp => dom/svg/SVGFESpecularLightingElement.cpp
rename : content/svg/content/src/SVGFESpecularLightingElement.h => dom/svg/SVGFESpecularLightingElement.h
rename : content/svg/content/src/SVGFESpotLightElement.cpp => dom/svg/SVGFESpotLightElement.cpp
rename : content/svg/content/src/SVGFESpotLightElement.h => dom/svg/SVGFESpotLightElement.h
rename : content/svg/content/src/SVGFETileElement.cpp => dom/svg/SVGFETileElement.cpp
rename : content/svg/content/src/SVGFETileElement.h => dom/svg/SVGFETileElement.h
rename : content/svg/content/src/SVGFETurbulenceElement.cpp => dom/svg/SVGFETurbulenceElement.cpp
rename : content/svg/content/src/SVGFETurbulenceElement.h => dom/svg/SVGFETurbulenceElement.h
rename : content/svg/content/src/SVGFilterElement.cpp => dom/svg/SVGFilterElement.cpp
rename : content/svg/content/src/SVGFilterElement.h => dom/svg/SVGFilterElement.h
rename : content/svg/content/src/SVGForeignObjectElement.cpp => dom/svg/SVGForeignObjectElement.cpp
rename : content/svg/content/src/SVGForeignObjectElement.h => dom/svg/SVGForeignObjectElement.h
rename : content/svg/content/src/SVGFragmentIdentifier.cpp => dom/svg/SVGFragmentIdentifier.cpp
rename : content/svg/content/src/SVGFragmentIdentifier.h => dom/svg/SVGFragmentIdentifier.h
rename : content/svg/content/src/SVGGElement.cpp => dom/svg/SVGGElement.cpp
rename : content/svg/content/src/SVGGElement.h => dom/svg/SVGGElement.h
rename : content/svg/content/src/SVGGradientElement.cpp => dom/svg/SVGGradientElement.cpp
rename : content/svg/content/src/SVGGradientElement.h => dom/svg/SVGGradientElement.h
rename : content/svg/content/src/SVGGraphicsElement.cpp => dom/svg/SVGGraphicsElement.cpp
rename : content/svg/content/src/SVGGraphicsElement.h => dom/svg/SVGGraphicsElement.h
rename : content/svg/content/src/SVGIFrameElement.cpp => dom/svg/SVGIFrameElement.cpp
rename : content/svg/content/src/SVGIFrameElement.h => dom/svg/SVGIFrameElement.h
rename : content/svg/content/src/SVGIRect.h => dom/svg/SVGIRect.h
rename : content/svg/content/src/SVGImageElement.cpp => dom/svg/SVGImageElement.cpp
rename : content/svg/content/src/SVGImageElement.h => dom/svg/SVGImageElement.h
rename : content/svg/content/src/SVGIntegerPairSMILType.cpp => dom/svg/SVGIntegerPairSMILType.cpp
rename : content/svg/content/src/SVGIntegerPairSMILType.h => dom/svg/SVGIntegerPairSMILType.h
rename : content/svg/content/src/SVGLength.cpp => dom/svg/SVGLength.cpp
rename : content/svg/content/src/SVGLength.h => dom/svg/SVGLength.h
rename : content/svg/content/src/SVGLengthList.cpp => dom/svg/SVGLengthList.cpp
rename : content/svg/content/src/SVGLengthList.h => dom/svg/SVGLengthList.h
rename : content/svg/content/src/SVGLengthListSMILType.cpp => dom/svg/SVGLengthListSMILType.cpp
rename : content/svg/content/src/SVGLengthListSMILType.h => dom/svg/SVGLengthListSMILType.h
rename : content/svg/content/src/SVGLineElement.cpp => dom/svg/SVGLineElement.cpp
rename : content/svg/content/src/SVGLineElement.h => dom/svg/SVGLineElement.h
rename : content/svg/content/src/SVGMPathElement.cpp => dom/svg/SVGMPathElement.cpp
rename : content/svg/content/src/SVGMPathElement.h => dom/svg/SVGMPathElement.h
rename : content/svg/content/src/SVGMarkerElement.cpp => dom/svg/SVGMarkerElement.cpp
rename : content/svg/content/src/SVGMarkerElement.h => dom/svg/SVGMarkerElement.h
rename : content/svg/content/src/SVGMaskElement.cpp => dom/svg/SVGMaskElement.cpp
rename : content/svg/content/src/SVGMaskElement.h => dom/svg/SVGMaskElement.h
rename : content/svg/content/src/SVGMatrix.cpp => dom/svg/SVGMatrix.cpp
rename : content/svg/content/src/SVGMatrix.h => dom/svg/SVGMatrix.h
rename : content/svg/content/src/SVGMetadataElement.cpp => dom/svg/SVGMetadataElement.cpp
rename : content/svg/content/src/SVGMetadataElement.h => dom/svg/SVGMetadataElement.h
rename : content/svg/content/src/SVGMotionSMILAnimationFunction.cpp => dom/svg/SVGMotionSMILAnimationFunction.cpp
rename : content/svg/content/src/SVGMotionSMILAnimationFunction.h => dom/svg/SVGMotionSMILAnimationFunction.h
rename : content/svg/content/src/SVGMotionSMILAttr.cpp => dom/svg/SVGMotionSMILAttr.cpp
rename : content/svg/content/src/SVGMotionSMILAttr.h => dom/svg/SVGMotionSMILAttr.h
rename : content/svg/content/src/SVGMotionSMILPathUtils.cpp => dom/svg/SVGMotionSMILPathUtils.cpp
rename : content/svg/content/src/SVGMotionSMILPathUtils.h => dom/svg/SVGMotionSMILPathUtils.h
rename : content/svg/content/src/SVGMotionSMILType.cpp => dom/svg/SVGMotionSMILType.cpp
rename : content/svg/content/src/SVGMotionSMILType.h => dom/svg/SVGMotionSMILType.h
rename : content/svg/content/src/SVGNumberList.cpp => dom/svg/SVGNumberList.cpp
rename : content/svg/content/src/SVGNumberList.h => dom/svg/SVGNumberList.h
rename : content/svg/content/src/SVGNumberListSMILType.cpp => dom/svg/SVGNumberListSMILType.cpp
rename : content/svg/content/src/SVGNumberListSMILType.h => dom/svg/SVGNumberListSMILType.h
rename : content/svg/content/src/SVGNumberPairSMILType.cpp => dom/svg/SVGNumberPairSMILType.cpp
rename : content/svg/content/src/SVGNumberPairSMILType.h => dom/svg/SVGNumberPairSMILType.h
rename : content/svg/content/src/SVGOrientSMILType.cpp => dom/svg/SVGOrientSMILType.cpp
rename : content/svg/content/src/SVGOrientSMILType.h => dom/svg/SVGOrientSMILType.h
rename : content/svg/content/src/SVGPathData.cpp => dom/svg/SVGPathData.cpp
rename : content/svg/content/src/SVGPathData.h => dom/svg/SVGPathData.h
rename : content/svg/content/src/SVGPathElement.cpp => dom/svg/SVGPathElement.cpp
rename : content/svg/content/src/SVGPathElement.h => dom/svg/SVGPathElement.h
rename : content/svg/content/src/SVGPathSegListSMILType.cpp => dom/svg/SVGPathSegListSMILType.cpp
rename : content/svg/content/src/SVGPathSegListSMILType.h => dom/svg/SVGPathSegListSMILType.h
rename : content/svg/content/src/SVGPathSegUtils.cpp => dom/svg/SVGPathSegUtils.cpp
rename : content/svg/content/src/SVGPathSegUtils.h => dom/svg/SVGPathSegUtils.h
rename : content/svg/content/src/SVGPatternElement.cpp => dom/svg/SVGPatternElement.cpp
rename : content/svg/content/src/SVGPatternElement.h => dom/svg/SVGPatternElement.h
rename : content/svg/content/src/SVGPoint.h => dom/svg/SVGPoint.h
rename : content/svg/content/src/SVGPointList.cpp => dom/svg/SVGPointList.cpp
rename : content/svg/content/src/SVGPointList.h => dom/svg/SVGPointList.h
rename : content/svg/content/src/SVGPointListSMILType.cpp => dom/svg/SVGPointListSMILType.cpp
rename : content/svg/content/src/SVGPointListSMILType.h => dom/svg/SVGPointListSMILType.h
rename : content/svg/content/src/SVGPolygonElement.cpp => dom/svg/SVGPolygonElement.cpp
rename : content/svg/content/src/SVGPolygonElement.h => dom/svg/SVGPolygonElement.h
rename : content/svg/content/src/SVGPolylineElement.cpp => dom/svg/SVGPolylineElement.cpp
rename : content/svg/content/src/SVGPolylineElement.h => dom/svg/SVGPolylineElement.h
rename : content/svg/content/src/SVGPreserveAspectRatio.cpp => dom/svg/SVGPreserveAspectRatio.cpp
rename : content/svg/content/src/SVGPreserveAspectRatio.h => dom/svg/SVGPreserveAspectRatio.h
rename : content/svg/content/src/SVGRect.cpp => dom/svg/SVGRect.cpp
rename : content/svg/content/src/SVGRect.h => dom/svg/SVGRect.h
rename : content/svg/content/src/SVGRectElement.cpp => dom/svg/SVGRectElement.cpp
rename : content/svg/content/src/SVGRectElement.h => dom/svg/SVGRectElement.h
rename : content/svg/content/src/SVGSVGElement.cpp => dom/svg/SVGSVGElement.cpp
rename : content/svg/content/src/SVGSVGElement.h => dom/svg/SVGSVGElement.h
rename : content/svg/content/src/SVGScriptElement.cpp => dom/svg/SVGScriptElement.cpp
rename : content/svg/content/src/SVGScriptElement.h => dom/svg/SVGScriptElement.h
rename : content/svg/content/src/SVGSetElement.cpp => dom/svg/SVGSetElement.cpp
rename : content/svg/content/src/SVGSetElement.h => dom/svg/SVGSetElement.h
rename : content/svg/content/src/SVGStopElement.cpp => dom/svg/SVGStopElement.cpp
rename : content/svg/content/src/SVGStopElement.h => dom/svg/SVGStopElement.h
rename : content/svg/content/src/SVGStringList.cpp => dom/svg/SVGStringList.cpp
rename : content/svg/content/src/SVGStringList.h => dom/svg/SVGStringList.h
rename : content/svg/content/src/SVGStyleElement.cpp => dom/svg/SVGStyleElement.cpp
rename : content/svg/content/src/SVGStyleElement.h => dom/svg/SVGStyleElement.h
rename : content/svg/content/src/SVGSwitchElement.cpp => dom/svg/SVGSwitchElement.cpp
rename : content/svg/content/src/SVGSwitchElement.h => dom/svg/SVGSwitchElement.h
rename : content/svg/content/src/SVGSymbolElement.cpp => dom/svg/SVGSymbolElement.cpp
rename : content/svg/content/src/SVGSymbolElement.h => dom/svg/SVGSymbolElement.h
rename : content/svg/content/src/SVGTSpanElement.cpp => dom/svg/SVGTSpanElement.cpp
rename : content/svg/content/src/SVGTSpanElement.h => dom/svg/SVGTSpanElement.h
rename : content/svg/content/src/SVGTagList.h => dom/svg/SVGTagList.h
rename : content/svg/content/src/SVGTests.cpp => dom/svg/SVGTests.cpp
rename : content/svg/content/src/SVGTests.h => dom/svg/SVGTests.h
rename : content/svg/content/src/SVGTextContentElement.cpp => dom/svg/SVGTextContentElement.cpp
rename : content/svg/content/src/SVGTextContentElement.h => dom/svg/SVGTextContentElement.h
rename : content/svg/content/src/SVGTextElement.cpp => dom/svg/SVGTextElement.cpp
rename : content/svg/content/src/SVGTextElement.h => dom/svg/SVGTextElement.h
rename : content/svg/content/src/SVGTextPathElement.cpp => dom/svg/SVGTextPathElement.cpp
rename : content/svg/content/src/SVGTextPathElement.h => dom/svg/SVGTextPathElement.h
rename : content/svg/content/src/SVGTextPositioningElement.cpp => dom/svg/SVGTextPositioningElement.cpp
rename : content/svg/content/src/SVGTextPositioningElement.h => dom/svg/SVGTextPositioningElement.h
rename : content/svg/content/src/SVGTitleElement.cpp => dom/svg/SVGTitleElement.cpp
rename : content/svg/content/src/SVGTitleElement.h => dom/svg/SVGTitleElement.h
rename : content/svg/content/src/SVGTransform.cpp => dom/svg/SVGTransform.cpp
rename : content/svg/content/src/SVGTransform.h => dom/svg/SVGTransform.h
rename : content/svg/content/src/SVGTransformList.cpp => dom/svg/SVGTransformList.cpp
rename : content/svg/content/src/SVGTransformList.h => dom/svg/SVGTransformList.h
rename : content/svg/content/src/SVGTransformListParser.cpp => dom/svg/SVGTransformListParser.cpp
rename : content/svg/content/src/SVGTransformListParser.h => dom/svg/SVGTransformListParser.h
rename : content/svg/content/src/SVGTransformListSMILType.cpp => dom/svg/SVGTransformListSMILType.cpp
rename : content/svg/content/src/SVGTransformListSMILType.h => dom/svg/SVGTransformListSMILType.h
rename : content/svg/content/src/SVGTransformableElement.cpp => dom/svg/SVGTransformableElement.cpp
rename : content/svg/content/src/SVGTransformableElement.h => dom/svg/SVGTransformableElement.h
rename : content/svg/content/src/SVGUseElement.cpp => dom/svg/SVGUseElement.cpp
rename : content/svg/content/src/SVGUseElement.h => dom/svg/SVGUseElement.h
rename : content/svg/content/src/SVGViewBoxSMILType.cpp => dom/svg/SVGViewBoxSMILType.cpp
rename : content/svg/content/src/SVGViewBoxSMILType.h => dom/svg/SVGViewBoxSMILType.h
rename : content/svg/content/src/SVGViewElement.cpp => dom/svg/SVGViewElement.cpp
rename : content/svg/content/src/SVGViewElement.h => dom/svg/SVGViewElement.h
rename : content/svg/content/src/SVGZoomEvent.cpp => dom/svg/SVGZoomEvent.cpp
rename : content/svg/content/src/SVGZoomEvent.h => dom/svg/SVGZoomEvent.h
rename : content/svg/content/src/crashtests/307322-1.svg => dom/svg/crashtests/307322-1.svg
rename : content/svg/content/src/crashtests/327705-1.svg => dom/svg/crashtests/327705-1.svg
rename : content/svg/content/src/crashtests/336994-1.html => dom/svg/crashtests/336994-1.html
rename : content/svg/content/src/crashtests/344888-1.svg => dom/svg/crashtests/344888-1.svg
rename : content/svg/content/src/crashtests/345445-1.svg => dom/svg/crashtests/345445-1.svg
rename : content/svg/content/src/crashtests/360836-1.svg => dom/svg/crashtests/360836-1.svg
rename : content/svg/content/src/crashtests/367357-1.xhtml => dom/svg/crashtests/367357-1.xhtml
rename : content/svg/content/src/crashtests/369051-1.svg => dom/svg/crashtests/369051-1.svg
rename : content/svg/content/src/crashtests/369249-1.svg => dom/svg/crashtests/369249-1.svg
rename : content/svg/content/src/crashtests/369291-1.svg => dom/svg/crashtests/369291-1.svg
rename : content/svg/content/src/crashtests/369291-2.svg => dom/svg/crashtests/369291-2.svg
rename : content/svg/content/src/crashtests/369568-1.svg => dom/svg/crashtests/369568-1.svg
rename : content/svg/content/src/crashtests/372046-1.svg => dom/svg/crashtests/372046-1.svg
rename : content/svg/content/src/crashtests/372046-2.svg => dom/svg/crashtests/372046-2.svg
rename : content/svg/content/src/crashtests/374882-1.svg => dom/svg/crashtests/374882-1.svg
rename : content/svg/content/src/crashtests/380101-1.svg => dom/svg/crashtests/380101-1.svg
rename : content/svg/content/src/crashtests/381777-1.svg => dom/svg/crashtests/381777-1.svg
rename : content/svg/content/src/crashtests/383685-1.svg => dom/svg/crashtests/383685-1.svg
rename : content/svg/content/src/crashtests/385096.html => dom/svg/crashtests/385096.html
rename : content/svg/content/src/crashtests/385554-1.html => dom/svg/crashtests/385554-1.html
rename : content/svg/content/src/crashtests/385554-2.xul => dom/svg/crashtests/385554-2.xul
rename : content/svg/content/src/crashtests/388712-1.svg => dom/svg/crashtests/388712-1.svg
rename : content/svg/content/src/crashtests/395616-1.html => dom/svg/crashtests/395616-1.html
rename : content/svg/content/src/crashtests/396618-1.html => dom/svg/crashtests/396618-1.html
rename : content/svg/content/src/crashtests/397017-1.html => dom/svg/crashtests/397017-1.html
rename : content/svg/content/src/crashtests/397551-1.svg => dom/svg/crashtests/397551-1.svg
rename : content/svg/content/src/crashtests/397704-1.svg => dom/svg/crashtests/397704-1.svg
rename : content/svg/content/src/crashtests/398926-both-different.svg => dom/svg/crashtests/398926-both-different.svg
rename : content/svg/content/src/crashtests/398926-both-same.svg => dom/svg/crashtests/398926-both-same.svg
rename : content/svg/content/src/crashtests/398926-fill.svg => dom/svg/crashtests/398926-fill.svg
rename : content/svg/content/src/crashtests/398926-stroke.svg => dom/svg/crashtests/398926-stroke.svg
rename : content/svg/content/src/crashtests/405639-1.svg => dom/svg/crashtests/405639-1.svg
rename : content/svg/content/src/crashtests/406361-1.html => dom/svg/crashtests/406361-1.html
rename : content/svg/content/src/crashtests/409811-1.html => dom/svg/crashtests/409811-1.html
rename : content/svg/content/src/crashtests/410659-1.svg => dom/svg/crashtests/410659-1.svg
rename : content/svg/content/src/crashtests/410659-2.svg => dom/svg/crashtests/410659-2.svg
rename : content/svg/content/src/crashtests/410659-3.svg => dom/svg/crashtests/410659-3.svg
rename : content/svg/content/src/crashtests/412104-1.svg => dom/svg/crashtests/412104-1.svg
rename : content/svg/content/src/crashtests/413174-1.svg => dom/svg/crashtests/413174-1.svg
rename : content/svg/content/src/crashtests/414188-1.svg => dom/svg/crashtests/414188-1.svg
rename : content/svg/content/src/crashtests/427325-1.svg => dom/svg/crashtests/427325-1.svg
rename : content/svg/content/src/crashtests/428228-1.svg => dom/svg/crashtests/428228-1.svg
rename : content/svg/content/src/crashtests/428841-1.svg => dom/svg/crashtests/428841-1.svg
rename : content/svg/content/src/crashtests/435209-1.svg => dom/svg/crashtests/435209-1.svg
rename : content/svg/content/src/crashtests/436418-mpathRoot-1.svg => dom/svg/crashtests/436418-mpathRoot-1.svg
rename : content/svg/content/src/crashtests/448244-1.svg => dom/svg/crashtests/448244-1.svg
rename : content/svg/content/src/crashtests/466576-1.xhtml => dom/svg/crashtests/466576-1.xhtml
rename : content/svg/content/src/crashtests/499879-1.svg => dom/svg/crashtests/499879-1.svg
rename : content/svg/content/src/crashtests/535691-1.svg => dom/svg/crashtests/535691-1.svg
rename : content/svg/content/src/crashtests/539167-1.svg => dom/svg/crashtests/539167-1.svg
rename : content/svg/content/src/crashtests/573316-1.svg => dom/svg/crashtests/573316-1.svg
rename : content/svg/content/src/crashtests/579356-1.svg => dom/svg/crashtests/579356-1.svg
rename : content/svg/content/src/crashtests/579356-2.svg => dom/svg/crashtests/579356-2.svg
rename : content/svg/content/src/crashtests/595608-1.svg => dom/svg/crashtests/595608-1.svg
rename : content/svg/content/src/crashtests/601251-1.html => dom/svg/crashtests/601251-1.html
rename : content/svg/content/src/crashtests/601406-1.svg => dom/svg/crashtests/601406-1.svg
rename : content/svg/content/src/crashtests/603145-1.svg => dom/svg/crashtests/603145-1.svg
rename : content/svg/content/src/crashtests/613899-1.svg => dom/svg/crashtests/613899-1.svg
rename : content/svg/content/src/crashtests/613899-2.svg => dom/svg/crashtests/613899-2.svg
rename : content/svg/content/src/crashtests/719779-1.svg => dom/svg/crashtests/719779-1.svg
rename : content/svg/content/src/crashtests/723441-1.html => dom/svg/crashtests/723441-1.html
rename : content/svg/content/src/crashtests/723441-resource.svg => dom/svg/crashtests/723441-resource.svg
rename : content/svg/content/src/crashtests/751515-1.svg => dom/svg/crashtests/751515-1.svg
rename : content/svg/content/src/crashtests/761507-1.svg => dom/svg/crashtests/761507-1.svg
rename : content/svg/content/src/crashtests/831561.html => dom/svg/crashtests/831561.html
rename : content/svg/content/src/crashtests/837450-1.svg => dom/svg/crashtests/837450-1.svg
rename : content/svg/content/src/crashtests/842463-1.html => dom/svg/crashtests/842463-1.html
rename : content/svg/content/src/crashtests/847138-1.svg => dom/svg/crashtests/847138-1.svg
rename : content/svg/content/src/crashtests/864509.svg => dom/svg/crashtests/864509.svg
rename : content/svg/content/src/crashtests/880544-1.svg => dom/svg/crashtests/880544-1.svg
rename : content/svg/content/src/crashtests/880544-2.svg => dom/svg/crashtests/880544-2.svg
rename : content/svg/content/src/crashtests/880544-3.svg => dom/svg/crashtests/880544-3.svg
rename : content/svg/content/src/crashtests/880544-4.svg => dom/svg/crashtests/880544-4.svg
rename : content/svg/content/src/crashtests/880544-5.svg => dom/svg/crashtests/880544-5.svg
rename : content/svg/content/src/crashtests/898915-1.svg => dom/svg/crashtests/898915-1.svg
rename : content/svg/content/src/crashtests/crashtests.list => dom/svg/crashtests/crashtests.list
rename : content/svg/content/src/crashtests/zero-size-image.svg => dom/svg/crashtests/zero-size-image.svg
rename : content/svg/moz.build => dom/svg/moz.build
rename : content/svg/content/src/nsISVGPoint.cpp => dom/svg/nsISVGPoint.cpp
rename : content/svg/content/src/nsISVGPoint.h => dom/svg/nsISVGPoint.h
rename : content/svg/content/src/nsSVGAngle.cpp => dom/svg/nsSVGAngle.cpp
rename : content/svg/content/src/nsSVGAngle.h => dom/svg/nsSVGAngle.h
rename : content/svg/content/src/nsSVGAnimatedTransformList.cpp => dom/svg/nsSVGAnimatedTransformList.cpp
rename : content/svg/content/src/nsSVGAnimatedTransformList.h => dom/svg/nsSVGAnimatedTransformList.h
rename : content/svg/content/src/nsSVGAttrTearoffTable.h => dom/svg/nsSVGAttrTearoffTable.h
rename : content/svg/content/src/nsSVGBoolean.cpp => dom/svg/nsSVGBoolean.cpp
rename : content/svg/content/src/nsSVGBoolean.h => dom/svg/nsSVGBoolean.h
rename : content/svg/content/src/nsSVGClass.cpp => dom/svg/nsSVGClass.cpp
rename : content/svg/content/src/nsSVGClass.h => dom/svg/nsSVGClass.h
rename : content/svg/content/src/nsSVGDataParser.cpp => dom/svg/nsSVGDataParser.cpp
rename : content/svg/content/src/nsSVGDataParser.h => dom/svg/nsSVGDataParser.h
rename : content/svg/content/src/nsSVGElement.cpp => dom/svg/nsSVGElement.cpp
rename : content/svg/content/src/nsSVGElement.h => dom/svg/nsSVGElement.h
rename : content/svg/content/src/nsSVGEnum.cpp => dom/svg/nsSVGEnum.cpp
rename : content/svg/content/src/nsSVGEnum.h => dom/svg/nsSVGEnum.h
rename : content/svg/content/src/nsSVGFeatures.cpp => dom/svg/nsSVGFeatures.cpp
rename : content/svg/content/src/nsSVGFeatures.h => dom/svg/nsSVGFeatures.h
rename : content/svg/content/src/nsSVGFeaturesList.h => dom/svg/nsSVGFeaturesList.h
rename : content/svg/content/src/nsSVGFilters.cpp => dom/svg/nsSVGFilters.cpp
rename : content/svg/content/src/nsSVGFilters.h => dom/svg/nsSVGFilters.h
rename : content/svg/content/src/nsSVGInteger.cpp => dom/svg/nsSVGInteger.cpp
rename : content/svg/content/src/nsSVGInteger.h => dom/svg/nsSVGInteger.h
rename : content/svg/content/src/nsSVGIntegerPair.cpp => dom/svg/nsSVGIntegerPair.cpp
rename : content/svg/content/src/nsSVGIntegerPair.h => dom/svg/nsSVGIntegerPair.h
rename : content/svg/content/src/nsSVGLength2.cpp => dom/svg/nsSVGLength2.cpp
rename : content/svg/content/src/nsSVGLength2.h => dom/svg/nsSVGLength2.h
rename : content/svg/content/src/nsSVGNumber2.cpp => dom/svg/nsSVGNumber2.cpp
rename : content/svg/content/src/nsSVGNumber2.h => dom/svg/nsSVGNumber2.h
rename : content/svg/content/src/nsSVGNumberPair.cpp => dom/svg/nsSVGNumberPair.cpp
rename : content/svg/content/src/nsSVGNumberPair.h => dom/svg/nsSVGNumberPair.h
rename : content/svg/content/src/nsSVGPathDataParser.cpp => dom/svg/nsSVGPathDataParser.cpp
rename : content/svg/content/src/nsSVGPathDataParser.h => dom/svg/nsSVGPathDataParser.h
rename : content/svg/content/src/nsSVGPathGeometryElement.cpp => dom/svg/nsSVGPathGeometryElement.cpp
rename : content/svg/content/src/nsSVGPathGeometryElement.h => dom/svg/nsSVGPathGeometryElement.h
rename : content/svg/content/src/nsSVGPolyElement.cpp => dom/svg/nsSVGPolyElement.cpp
rename : content/svg/content/src/nsSVGPolyElement.h => dom/svg/nsSVGPolyElement.h
rename : content/svg/content/src/nsSVGString.cpp => dom/svg/nsSVGString.cpp
rename : content/svg/content/src/nsSVGString.h => dom/svg/nsSVGString.h
rename : content/svg/content/src/nsSVGTransform.cpp => dom/svg/nsSVGTransform.cpp
rename : content/svg/content/src/nsSVGTransform.h => dom/svg/nsSVGTransform.h
rename : content/svg/content/src/nsSVGViewBox.cpp => dom/svg/nsSVGViewBox.cpp
rename : content/svg/content/src/nsSVGViewBox.h => dom/svg/nsSVGViewBox.h
rename : content/svg/content/test/MutationEventChecker.js => dom/svg/test/MutationEventChecker.js
rename : content/svg/content/test/a_href_destination.svg => dom/svg/test/a_href_destination.svg
rename : content/svg/content/test/a_href_helper_01.svg => dom/svg/test/a_href_helper_01.svg
rename : content/svg/content/test/a_href_helper_02_03.svg => dom/svg/test/a_href_helper_02_03.svg
rename : content/svg/content/test/a_href_helper_04.svg => dom/svg/test/a_href_helper_04.svg
rename : content/svg/content/test/animated-svg-image-helper.html => dom/svg/test/animated-svg-image-helper.html
rename : content/svg/content/test/animated-svg-image-helper.svg => dom/svg/test/animated-svg-image-helper.svg
rename : content/svg/content/test/bbox-helper.svg => dom/svg/test/bbox-helper.svg
rename : content/svg/content/test/bounds-helper.svg => dom/svg/test/bounds-helper.svg
rename : content/svg/content/test/dataTypes-helper.svg => dom/svg/test/dataTypes-helper.svg
rename : content/svg/content/test/fragments-helper.svg => dom/svg/test/fragments-helper.svg
rename : content/svg/content/test/getBBox-method-helper.svg => dom/svg/test/getBBox-method-helper.svg
rename : content/svg/content/test/getCTM-helper.svg => dom/svg/test/getCTM-helper.svg
rename : content/svg/content/test/getSubStringLength-helper.svg => dom/svg/test/getSubStringLength-helper.svg
rename : content/svg/content/test/matrixUtils.js => dom/svg/test/matrixUtils.js
rename : content/svg/content/test/mochitest.ini => dom/svg/test/mochitest.ini
rename : content/svg/content/test/object-delayed-intrinsic-size.sjs => dom/svg/test/object-delayed-intrinsic-size.sjs
rename : content/svg/content/test/pointer-events.js => dom/svg/test/pointer-events.js
rename : content/svg/content/test/scientific-helper.svg => dom/svg/test/scientific-helper.svg
rename : content/svg/content/test/selectSubString-helper.svg => dom/svg/test/selectSubString-helper.svg
rename : content/svg/content/test/switch-helper.svg => dom/svg/test/switch-helper.svg
rename : content/svg/content/test/test_SVGLengthList-2.xhtml => dom/svg/test/test_SVGLengthList-2.xhtml
rename : content/svg/content/test/test_SVGLengthList.xhtml => dom/svg/test/test_SVGLengthList.xhtml
rename : content/svg/content/test/test_SVGMatrix.xhtml => dom/svg/test/test_SVGMatrix.xhtml
rename : content/svg/content/test/test_SVGNumberList.xhtml => dom/svg/test/test_SVGNumberList.xhtml
rename : content/svg/content/test/test_SVGPathSegList.xhtml => dom/svg/test/test_SVGPathSegList.xhtml
rename : content/svg/content/test/test_SVGPointList.xhtml => dom/svg/test/test_SVGPointList.xhtml
rename : content/svg/content/test/test_SVGStringList.xhtml => dom/svg/test/test_SVGStringList.xhtml
rename : content/svg/content/test/test_SVGStyleElement.xhtml => dom/svg/test/test_SVGStyleElement.xhtml
rename : content/svg/content/test/test_SVGTransformList.xhtml => dom/svg/test/test_SVGTransformList.xhtml
rename : content/svg/content/test/test_SVGTransformListAddition.xhtml => dom/svg/test/test_SVGTransformListAddition.xhtml
rename : content/svg/content/test/test_SVGUnitTypes.html => dom/svg/test/test_SVGUnitTypes.html
rename : content/svg/content/test/test_SVG_namespace_ids.html => dom/svg/test/test_SVG_namespace_ids.html
rename : content/svg/content/test/test_SVGxxxList.xhtml => dom/svg/test/test_SVGxxxList.xhtml
rename : content/svg/content/test/test_SVGxxxListIndexing.xhtml => dom/svg/test/test_SVGxxxListIndexing.xhtml
rename : content/svg/content/test/test_a_href_01.xhtml => dom/svg/test/test_a_href_01.xhtml
rename : content/svg/content/test/test_a_href_02.xhtml => dom/svg/test/test_a_href_02.xhtml
rename : content/svg/content/test/test_animLengthObjectIdentity.xhtml => dom/svg/test/test_animLengthObjectIdentity.xhtml
rename : content/svg/content/test/test_animLengthReadonly.xhtml => dom/svg/test/test_animLengthReadonly.xhtml
rename : content/svg/content/test/test_animLengthUnits.xhtml => dom/svg/test/test_animLengthUnits.xhtml
rename : content/svg/content/test/test_bbox-with-invalid-viewBox.xhtml => dom/svg/test/test_bbox-with-invalid-viewBox.xhtml
rename : content/svg/content/test/test_bbox.xhtml => dom/svg/test/test_bbox.xhtml
rename : content/svg/content/test/test_bounds.html => dom/svg/test/test_bounds.html
rename : content/svg/content/test/test_bug872812.html => dom/svg/test/test_bug872812.html
rename : content/svg/content/test/test_dataTypes.html => dom/svg/test/test_dataTypes.html
rename : content/svg/content/test/test_dataTypesModEvents.html => dom/svg/test/test_dataTypesModEvents.html
rename : content/svg/content/test/test_fragments.html => dom/svg/test/test_fragments.html
rename : content/svg/content/test/test_getBBox-method.html => dom/svg/test/test_getBBox-method.html
rename : content/svg/content/test/test_getCTM.html => dom/svg/test/test_getCTM.html
rename : content/svg/content/test/test_getElementById.xhtml => dom/svg/test/test_getElementById.xhtml
rename : content/svg/content/test/test_getSubStringLength.xhtml => dom/svg/test/test_getSubStringLength.xhtml
rename : content/svg/content/test/test_hasFeature.xhtml => dom/svg/test/test_hasFeature.xhtml
rename : content/svg/content/test/test_lang.xhtml => dom/svg/test/test_lang.xhtml
rename : content/svg/content/test/test_length.xhtml => dom/svg/test/test_length.xhtml
rename : content/svg/content/test/test_lengthParsing.html => dom/svg/test/test_lengthParsing.html
rename : content/svg/content/test/test_non-scaling-stroke.html => dom/svg/test/test_non-scaling-stroke.html
rename : content/svg/content/test/test_nonAnimStrings.xhtml => dom/svg/test/test_nonAnimStrings.xhtml
rename : content/svg/content/test/test_object-delayed-intrinsic-size.html => dom/svg/test/test_object-delayed-intrinsic-size.html
rename : content/svg/content/test/test_onerror.xhtml => dom/svg/test/test_onerror.xhtml
rename : content/svg/content/test/test_pathAnimInterpolation.xhtml => dom/svg/test/test_pathAnimInterpolation.xhtml
rename : content/svg/content/test/test_pathLength.html => dom/svg/test/test_pathLength.html
rename : content/svg/content/test/test_pathSeg.xhtml => dom/svg/test/test_pathSeg.xhtml
rename : content/svg/content/test/test_pointAtLength.xhtml => dom/svg/test/test_pointAtLength.xhtml
rename : content/svg/content/test/test_pointer-events-1a.xhtml => dom/svg/test/test_pointer-events-1a.xhtml
rename : content/svg/content/test/test_pointer-events-1b.xhtml => dom/svg/test/test_pointer-events-1b.xhtml
rename : content/svg/content/test/test_pointer-events-2.xhtml => dom/svg/test/test_pointer-events-2.xhtml
rename : content/svg/content/test/test_pointer-events-3.xhtml => dom/svg/test/test_pointer-events-3.xhtml
rename : content/svg/content/test/test_pointer-events-4.xhtml => dom/svg/test/test_pointer-events-4.xhtml
rename : content/svg/content/test/test_pointer-events-5.xhtml => dom/svg/test/test_pointer-events-5.xhtml
rename : content/svg/content/test/test_pointer-events-6.xhtml => dom/svg/test/test_pointer-events-6.xhtml
rename : content/svg/content/test/test_scientific.html => dom/svg/test/test_scientific.html
rename : content/svg/content/test/test_selectSubString.xhtml => dom/svg/test/test_selectSubString.xhtml
rename : content/svg/content/test/test_stroke-linecap-hit-testing.xhtml => dom/svg/test/test_stroke-linecap-hit-testing.xhtml
rename : content/svg/content/test/test_switch.xhtml => dom/svg/test/test_switch.xhtml
rename : content/svg/content/test/test_text.html => dom/svg/test/test_text.html
rename : content/svg/content/test/test_text_2.html => dom/svg/test/test_text_2.html
rename : content/svg/content/test/test_text_dirty.html => dom/svg/test/test_text_dirty.html
rename : content/svg/content/test/test_text_lengthAdjust.html => dom/svg/test/test_text_lengthAdjust.html
rename : content/svg/content/test/test_text_scaled.html => dom/svg/test/test_text_scaled.html
rename : content/svg/content/test/test_text_selection.html => dom/svg/test/test_text_selection.html
rename : content/svg/content/test/test_text_update.html => dom/svg/test/test_text_update.html
rename : content/svg/content/test/test_transform.xhtml => dom/svg/test/test_transform.xhtml
rename : content/svg/content/test/test_transformParsing.html => dom/svg/test/test_transformParsing.html
rename : content/svg/content/test/test_valueAsString.xhtml => dom/svg/test/test_valueAsString.xhtml
rename : content/svg/content/test/test_valueLeaks.xhtml => dom/svg/test/test_valueLeaks.xhtml
rename : content/svg/content/test/test_viewport.html => dom/svg/test/test_viewport.html
rename : content/svg/content/test/test_zoom.xhtml => dom/svg/test/test_zoom.xhtml
rename : content/svg/content/test/text-helper-scaled.svg => dom/svg/test/text-helper-scaled.svg
rename : content/svg/content/test/text-helper-selection.svg => dom/svg/test/text-helper-selection.svg
rename : content/svg/content/test/text-helper.svg => dom/svg/test/text-helper.svg
rename : content/svg/content/test/viewport-helper.svg => dom/svg/test/viewport-helper.svg
rename : content/svg/content/test/zoom-helper.svg => dom/svg/test/zoom-helper.svg
2014-10-25 20:21:12 +03:00

801 lines
25 KiB
C++

/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
// Main header first:
// This is also necessary to ensure our definition of M_SQRT1_2 is picked up
#include "SVGContentUtils.h"
// Keep others in (case-insensitive) order:
#include "gfx2DGlue.h"
#include "gfxMatrix.h"
#include "gfxPlatform.h"
#include "gfxSVGGlyphs.h"
#include "mozilla/gfx/2D.h"
#include "mozilla/dom/SVGSVGElement.h"
#include "mozilla/RefPtr.h"
#include "nsComputedDOMStyle.h"
#include "nsFontMetrics.h"
#include "nsIFrame.h"
#include "nsIScriptError.h"
#include "nsLayoutUtils.h"
#include "SVGAnimationElement.h"
#include "SVGAnimatedPreserveAspectRatio.h"
#include "nsContentUtils.h"
#include "mozilla/gfx/2D.h"
#include "mozilla/gfx/Types.h"
#include "mozilla/FloatingPoint.h"
#include "nsStyleContext.h"
#include "nsSVGPathDataParser.h"
#include "SVGPathData.h"
#include "SVGPathElement.h"
using namespace mozilla;
using namespace mozilla::dom;
using namespace mozilla::gfx;
SVGSVGElement*
SVGContentUtils::GetOuterSVGElement(nsSVGElement *aSVGElement)
{
nsIContent *element = nullptr;
nsIContent *ancestor = aSVGElement->GetFlattenedTreeParent();
while (ancestor && ancestor->IsSVG() &&
ancestor->Tag() != nsGkAtoms::foreignObject) {
element = ancestor;
ancestor = element->GetFlattenedTreeParent();
}
if (element && element->Tag() == nsGkAtoms::svg) {
return static_cast<SVGSVGElement*>(element);
}
return nullptr;
}
void
SVGContentUtils::ActivateByHyperlink(nsIContent *aContent)
{
NS_ABORT_IF_FALSE(aContent->IsNodeOfType(nsINode::eANIMATION),
"Expecting an animation element");
static_cast<SVGAnimationElement*>(aContent)->ActivateByHyperlink();
}
enum DashState {
eDashedStroke,
eContinuousStroke, //< all dashes, no gaps
eNoStroke //< all gaps, no dashes
};
static DashState
GetStrokeDashData(SVGContentUtils::AutoStrokeOptions* aStrokeOptions,
nsSVGElement* aElement,
const nsStyleSVG* aStyleSVG,
gfxTextContextPaint *aContextPaint)
{
size_t dashArrayLength;
Float totalLengthOfDashes = 0.0, totalLengthOfGaps = 0.0;
if (aContextPaint && aStyleSVG->mStrokeDasharrayFromObject) {
const FallibleTArray<gfxFloat>& dashSrc = aContextPaint->GetStrokeDashArray();
dashArrayLength = dashSrc.Length();
if (dashArrayLength <= 0) {
return eContinuousStroke;
}
Float* dashPattern = aStrokeOptions->InitDashPattern(dashArrayLength);
if (!dashPattern) {
return eContinuousStroke;
}
for (size_t i = 0; i < dashArrayLength; i++) {
if (dashSrc[i] < 0.0) {
return eContinuousStroke; // invalid
}
dashPattern[i] = Float(dashSrc[i]);
(i % 2 ? totalLengthOfGaps : totalLengthOfDashes) += dashSrc[i];
}
} else {
const nsStyleCoord *dasharray = aStyleSVG->mStrokeDasharray;
dashArrayLength = aStyleSVG->mStrokeDasharrayLength;
if (dashArrayLength <= 0) {
return eContinuousStroke;
}
Float pathScale = 1.0;
if (aElement->Tag() == nsGkAtoms::path) {
pathScale = static_cast<SVGPathElement*>(aElement)->
GetPathLengthScale(SVGPathElement::eForStroking);
if (pathScale <= 0) {
return eContinuousStroke;
}
}
Float* dashPattern = aStrokeOptions->InitDashPattern(dashArrayLength);
if (!dashPattern) {
return eContinuousStroke;
}
for (uint32_t i = 0; i < dashArrayLength; i++) {
Float dashLength =
SVGContentUtils::CoordToFloat(aElement, dasharray[i]) * pathScale;
if (dashLength < 0.0) {
return eContinuousStroke; // invalid
}
dashPattern[i] = dashLength;
(i % 2 ? totalLengthOfGaps : totalLengthOfDashes) += dashLength;
}
}
// Now that aStrokeOptions.mDashPattern is fully initialized (we didn't
// return early above) we can safely set mDashLength:
aStrokeOptions->mDashLength = dashArrayLength;
if ((dashArrayLength % 2) == 1) {
// If we have a dash pattern with an odd number of lengths the pattern
// repeats a second time, per the SVG spec., and as implemented by Moz2D.
// When deciding whether to return eNoStroke or eContinuousStroke below we
// need to take into account that in the repeat pattern the dashes become
// gaps, and the gaps become dashes.
Float origTotalLengthOfDashes = totalLengthOfDashes;
totalLengthOfDashes += totalLengthOfGaps;
totalLengthOfGaps += origTotalLengthOfDashes;
}
if (totalLengthOfDashes <= 0 || totalLengthOfGaps <= 0) {
if (totalLengthOfGaps > 0 && totalLengthOfDashes <= 0) {
return eNoStroke;
}
return eContinuousStroke;
}
if (aContextPaint && aStyleSVG->mStrokeDashoffsetFromObject) {
aStrokeOptions->mDashOffset = Float(aContextPaint->GetStrokeDashOffset());
} else {
aStrokeOptions->mDashOffset =
SVGContentUtils::CoordToFloat(aElement, aStyleSVG->mStrokeDashoffset);
}
return eDashedStroke;
}
void
SVGContentUtils::GetStrokeOptions(AutoStrokeOptions* aStrokeOptions,
nsSVGElement* aElement,
nsStyleContext* aStyleContext,
gfxTextContextPaint *aContextPaint,
StrokeOptionFlags aFlags)
{
nsRefPtr<nsStyleContext> styleContext;
if (aStyleContext) {
styleContext = aStyleContext;
} else {
styleContext =
nsComputedDOMStyle::GetStyleContextForElementNoFlush(aElement, nullptr,
nullptr);
}
if (!styleContext) {
return;
}
const nsStyleSVG* styleSVG = styleContext->StyleSVG();
if (aFlags != eIgnoreStrokeDashing) {
DashState dashState =
GetStrokeDashData(aStrokeOptions, aElement, styleSVG, aContextPaint);
if (dashState == eNoStroke) {
// Hopefully this will shortcircuit any stroke operations:
aStrokeOptions->mLineWidth = 0;
return;
}
if (dashState == eContinuousStroke && aStrokeOptions->mDashPattern) {
// Prevent our caller from wasting time looking at a pattern without gaps:
aStrokeOptions->DiscardDashPattern();
}
}
aStrokeOptions->mLineWidth =
GetStrokeWidth(aElement, styleContext, aContextPaint);
aStrokeOptions->mMiterLimit = Float(styleSVG->mStrokeMiterlimit);
switch (styleSVG->mStrokeLinejoin) {
case NS_STYLE_STROKE_LINEJOIN_MITER:
aStrokeOptions->mLineJoin = JoinStyle::MITER;
break;
case NS_STYLE_STROKE_LINEJOIN_ROUND:
aStrokeOptions->mLineJoin = JoinStyle::ROUND;
break;
case NS_STYLE_STROKE_LINEJOIN_BEVEL:
aStrokeOptions->mLineJoin = JoinStyle::BEVEL;
break;
}
switch (styleSVG->mStrokeLinecap) {
case NS_STYLE_STROKE_LINECAP_BUTT:
aStrokeOptions->mLineCap = CapStyle::BUTT;
break;
case NS_STYLE_STROKE_LINECAP_ROUND:
aStrokeOptions->mLineCap = CapStyle::ROUND;
break;
case NS_STYLE_STROKE_LINECAP_SQUARE:
aStrokeOptions->mLineCap = CapStyle::SQUARE;
break;
}
}
Float
SVGContentUtils::GetStrokeWidth(nsSVGElement* aElement,
nsStyleContext* aStyleContext,
gfxTextContextPaint *aContextPaint)
{
nsRefPtr<nsStyleContext> styleContext;
if (aStyleContext) {
styleContext = aStyleContext;
} else {
styleContext =
nsComputedDOMStyle::GetStyleContextForElementNoFlush(aElement, nullptr,
nullptr);
}
if (!styleContext) {
return 0.0f;
}
const nsStyleSVG* styleSVG = styleContext->StyleSVG();
if (aContextPaint && styleSVG->mStrokeWidthFromObject) {
return aContextPaint->GetStrokeWidth();
}
return SVGContentUtils::CoordToFloat(aElement, styleSVG->mStrokeWidth);
}
float
SVGContentUtils::GetFontSize(Element *aElement)
{
if (!aElement)
return 1.0f;
nsRefPtr<nsStyleContext> styleContext =
nsComputedDOMStyle::GetStyleContextForElementNoFlush(aElement,
nullptr, nullptr);
if (!styleContext) {
// ReportToConsole
NS_WARNING("Couldn't get style context for content in GetFontStyle");
return 1.0f;
}
return GetFontSize(styleContext);
}
float
SVGContentUtils::GetFontSize(nsIFrame *aFrame)
{
NS_ABORT_IF_FALSE(aFrame, "NULL frame in GetFontSize");
return GetFontSize(aFrame->StyleContext());
}
float
SVGContentUtils::GetFontSize(nsStyleContext *aStyleContext)
{
NS_ABORT_IF_FALSE(aStyleContext, "NULL style context in GetFontSize");
nsPresContext *presContext = aStyleContext->PresContext();
NS_ABORT_IF_FALSE(presContext, "NULL pres context in GetFontSize");
nscoord fontSize = aStyleContext->StyleFont()->mSize;
return nsPresContext::AppUnitsToFloatCSSPixels(fontSize) /
presContext->TextZoom();
}
float
SVGContentUtils::GetFontXHeight(Element *aElement)
{
if (!aElement)
return 1.0f;
nsRefPtr<nsStyleContext> styleContext =
nsComputedDOMStyle::GetStyleContextForElementNoFlush(aElement,
nullptr, nullptr);
if (!styleContext) {
// ReportToConsole
NS_WARNING("Couldn't get style context for content in GetFontStyle");
return 1.0f;
}
return GetFontXHeight(styleContext);
}
float
SVGContentUtils::GetFontXHeight(nsIFrame *aFrame)
{
NS_ABORT_IF_FALSE(aFrame, "NULL frame in GetFontXHeight");
return GetFontXHeight(aFrame->StyleContext());
}
float
SVGContentUtils::GetFontXHeight(nsStyleContext *aStyleContext)
{
NS_ABORT_IF_FALSE(aStyleContext, "NULL style context in GetFontXHeight");
nsPresContext *presContext = aStyleContext->PresContext();
NS_ABORT_IF_FALSE(presContext, "NULL pres context in GetFontXHeight");
nsRefPtr<nsFontMetrics> fontMetrics;
nsLayoutUtils::GetFontMetricsForStyleContext(aStyleContext,
getter_AddRefs(fontMetrics));
if (!fontMetrics) {
// ReportToConsole
NS_WARNING("no FontMetrics in GetFontXHeight()");
return 1.0f;
}
nscoord xHeight = fontMetrics->XHeight();
return nsPresContext::AppUnitsToFloatCSSPixels(xHeight) /
presContext->TextZoom();
}
nsresult
SVGContentUtils::ReportToConsole(nsIDocument* doc,
const char* aWarning,
const char16_t **aParams,
uint32_t aParamsLength)
{
return nsContentUtils::ReportToConsole(nsIScriptError::warningFlag,
NS_LITERAL_CSTRING("SVG"), doc,
nsContentUtils::eSVG_PROPERTIES,
aWarning,
aParams, aParamsLength);
}
bool
SVGContentUtils::EstablishesViewport(nsIContent *aContent)
{
// Although SVG 1.1 states that <image> is an element that establishes a
// viewport, this is really only for the document it references, not
// for any child content, which is what this function is used for.
return aContent && aContent->IsSVG() &&
(aContent->Tag() == nsGkAtoms::svg ||
aContent->Tag() == nsGkAtoms::foreignObject ||
aContent->Tag() == nsGkAtoms::symbol);
}
nsSVGElement*
SVGContentUtils::GetNearestViewportElement(nsIContent *aContent)
{
nsIContent *element = aContent->GetFlattenedTreeParent();
while (element && element->IsSVG()) {
if (EstablishesViewport(element)) {
if (element->Tag() == nsGkAtoms::foreignObject) {
return nullptr;
}
return static_cast<nsSVGElement*>(element);
}
element = element->GetFlattenedTreeParent();
}
return nullptr;
}
static gfx::Matrix
GetCTMInternal(nsSVGElement *aElement, bool aScreenCTM, bool aHaveRecursed)
{
gfxMatrix matrix = aElement->PrependLocalTransformsTo(gfxMatrix(),
aHaveRecursed ? nsSVGElement::eAllTransforms : nsSVGElement::eUserSpaceToParent);
nsSVGElement *element = aElement;
nsIContent *ancestor = aElement->GetFlattenedTreeParent();
while (ancestor && ancestor->IsSVG() &&
ancestor->Tag() != nsGkAtoms::foreignObject) {
element = static_cast<nsSVGElement*>(ancestor);
matrix *= element->PrependLocalTransformsTo(gfxMatrix()); // i.e. *A*ppend
if (!aScreenCTM && SVGContentUtils::EstablishesViewport(element)) {
if (!element->NodeInfo()->Equals(nsGkAtoms::svg, kNameSpaceID_SVG) &&
!element->NodeInfo()->Equals(nsGkAtoms::symbol, kNameSpaceID_SVG)) {
NS_ERROR("New (SVG > 1.1) SVG viewport establishing element?");
return gfx::Matrix(0.0, 0.0, 0.0, 0.0, 0.0, 0.0); // singular
}
// XXX spec seems to say x,y translation should be undone for IsInnerSVG
return gfx::ToMatrix(matrix);
}
ancestor = ancestor->GetFlattenedTreeParent();
}
if (!aScreenCTM) {
// didn't find a nearestViewportElement
return gfx::Matrix(0.0, 0.0, 0.0, 0.0, 0.0, 0.0); // singular
}
if (element->Tag() != nsGkAtoms::svg) {
// Not a valid SVG fragment
return gfx::Matrix(0.0, 0.0, 0.0, 0.0, 0.0, 0.0); // singular
}
if (element == aElement && !aHaveRecursed) {
// We get here when getScreenCTM() is called on an outer-<svg>.
// Consistency with other elements would have us include only the
// eFromUserSpace transforms, but we include the eAllTransforms
// transforms in this case since that's what we've been doing for
// a while, and it keeps us consistent with WebKit and Opera (if not
// really with the ambiguous spec).
matrix = aElement->PrependLocalTransformsTo(gfxMatrix());
}
if (!ancestor || !ancestor->IsElement()) {
return gfx::ToMatrix(matrix);
}
if (ancestor->IsSVG()) {
return
gfx::ToMatrix(matrix) * GetCTMInternal(static_cast<nsSVGElement*>(ancestor), true, true);
}
// XXX this does not take into account CSS transform, or that the non-SVG
// content that we've hit may itself be inside an SVG foreignObject higher up
nsIDocument* currentDoc = aElement->GetComposedDoc();
float x = 0.0f, y = 0.0f;
if (currentDoc && element->NodeInfo()->Equals(nsGkAtoms::svg, kNameSpaceID_SVG)) {
nsIPresShell *presShell = currentDoc->GetShell();
if (presShell) {
nsIFrame* frame = element->GetPrimaryFrame();
nsIFrame* ancestorFrame = presShell->GetRootFrame();
if (frame && ancestorFrame) {
nsPoint point = frame->GetOffsetTo(ancestorFrame);
x = nsPresContext::AppUnitsToFloatCSSPixels(point.x);
y = nsPresContext::AppUnitsToFloatCSSPixels(point.y);
}
}
}
return ToMatrix(matrix).PostTranslate(x, y);
}
gfx::Matrix
SVGContentUtils::GetCTM(nsSVGElement *aElement, bool aScreenCTM)
{
return GetCTMInternal(aElement, aScreenCTM, false);
}
double
SVGContentUtils::ComputeNormalizedHypotenuse(double aWidth, double aHeight)
{
return sqrt((aWidth*aWidth + aHeight*aHeight)/2);
}
float
SVGContentUtils::AngleBisect(float a1, float a2)
{
float delta = fmod(a2 - a1, static_cast<float>(2*M_PI));
if (delta < 0) {
delta += static_cast<float>(2*M_PI);
}
/* delta is now the angle from a1 around to a2, in the range [0, 2*M_PI) */
float r = a1 + delta/2;
if (delta >= M_PI) {
/* the arc from a2 to a1 is smaller, so use the ray on that side */
r += static_cast<float>(M_PI);
}
return r;
}
gfx::Matrix
SVGContentUtils::GetViewBoxTransform(float aViewportWidth, float aViewportHeight,
float aViewboxX, float aViewboxY,
float aViewboxWidth, float aViewboxHeight,
const SVGAnimatedPreserveAspectRatio &aPreserveAspectRatio)
{
return GetViewBoxTransform(aViewportWidth, aViewportHeight,
aViewboxX, aViewboxY,
aViewboxWidth, aViewboxHeight,
aPreserveAspectRatio.GetAnimValue());
}
gfx::Matrix
SVGContentUtils::GetViewBoxTransform(float aViewportWidth, float aViewportHeight,
float aViewboxX, float aViewboxY,
float aViewboxWidth, float aViewboxHeight,
const SVGPreserveAspectRatio &aPreserveAspectRatio)
{
NS_ASSERTION(aViewportWidth >= 0, "viewport width must be nonnegative!");
NS_ASSERTION(aViewportHeight >= 0, "viewport height must be nonnegative!");
NS_ASSERTION(aViewboxWidth > 0, "viewBox width must be greater than zero!");
NS_ASSERTION(aViewboxHeight > 0, "viewBox height must be greater than zero!");
SVGAlign align = aPreserveAspectRatio.GetAlign();
SVGMeetOrSlice meetOrSlice = aPreserveAspectRatio.GetMeetOrSlice();
// default to the defaults
if (align == SVG_PRESERVEASPECTRATIO_UNKNOWN)
align = SVG_PRESERVEASPECTRATIO_XMIDYMID;
if (meetOrSlice == SVG_MEETORSLICE_UNKNOWN)
meetOrSlice = SVG_MEETORSLICE_MEET;
float a, d, e, f;
a = aViewportWidth / aViewboxWidth;
d = aViewportHeight / aViewboxHeight;
e = 0.0f;
f = 0.0f;
if (align != SVG_PRESERVEASPECTRATIO_NONE &&
a != d) {
if ((meetOrSlice == SVG_MEETORSLICE_MEET && a < d) ||
(meetOrSlice == SVG_MEETORSLICE_SLICE && d < a)) {
d = a;
switch (align) {
case SVG_PRESERVEASPECTRATIO_XMINYMIN:
case SVG_PRESERVEASPECTRATIO_XMIDYMIN:
case SVG_PRESERVEASPECTRATIO_XMAXYMIN:
break;
case SVG_PRESERVEASPECTRATIO_XMINYMID:
case SVG_PRESERVEASPECTRATIO_XMIDYMID:
case SVG_PRESERVEASPECTRATIO_XMAXYMID:
f = (aViewportHeight - a * aViewboxHeight) / 2.0f;
break;
case SVG_PRESERVEASPECTRATIO_XMINYMAX:
case SVG_PRESERVEASPECTRATIO_XMIDYMAX:
case SVG_PRESERVEASPECTRATIO_XMAXYMAX:
f = aViewportHeight - a * aViewboxHeight;
break;
default:
NS_NOTREACHED("Unknown value for align");
}
}
else if (
(meetOrSlice == SVG_MEETORSLICE_MEET &&
d < a) ||
(meetOrSlice == SVG_MEETORSLICE_SLICE &&
a < d)) {
a = d;
switch (align) {
case SVG_PRESERVEASPECTRATIO_XMINYMIN:
case SVG_PRESERVEASPECTRATIO_XMINYMID:
case SVG_PRESERVEASPECTRATIO_XMINYMAX:
break;
case SVG_PRESERVEASPECTRATIO_XMIDYMIN:
case SVG_PRESERVEASPECTRATIO_XMIDYMID:
case SVG_PRESERVEASPECTRATIO_XMIDYMAX:
e = (aViewportWidth - a * aViewboxWidth) / 2.0f;
break;
case SVG_PRESERVEASPECTRATIO_XMAXYMIN:
case SVG_PRESERVEASPECTRATIO_XMAXYMID:
case SVG_PRESERVEASPECTRATIO_XMAXYMAX:
e = aViewportWidth - a * aViewboxWidth;
break;
default:
NS_NOTREACHED("Unknown value for align");
}
}
else NS_NOTREACHED("Unknown value for meetOrSlice");
}
if (aViewboxX) e += -a * aViewboxX;
if (aViewboxY) f += -d * aViewboxY;
return gfx::Matrix(a, 0.0f, 0.0f, d, e, f);
}
static bool
ParseNumber(RangedPtr<const char16_t>& aIter,
const RangedPtr<const char16_t>& aEnd,
double& aValue)
{
int32_t sign;
if (!SVGContentUtils::ParseOptionalSign(aIter, aEnd, sign)) {
return false;
}
// Absolute value of the integer part of the mantissa.
double intPart = 0.0;
bool gotDot = *aIter == '.';
if (!gotDot) {
if (!SVGContentUtils::IsDigit(*aIter)) {
return false;
}
do {
intPart = 10.0 * intPart + SVGContentUtils::DecimalDigitValue(*aIter);
++aIter;
} while (aIter != aEnd && SVGContentUtils::IsDigit(*aIter));
if (aIter != aEnd) {
gotDot = *aIter == '.';
}
}
// Fractional part of the mantissa.
double fracPart = 0.0;
if (gotDot) {
++aIter;
if (aIter == aEnd || !SVGContentUtils::IsDigit(*aIter)) {
return false;
}
// Power of ten by which we need to divide the fraction
double divisor = 1.0;
do {
fracPart = 10.0 * fracPart + SVGContentUtils::DecimalDigitValue(*aIter);
divisor *= 10.0;
++aIter;
} while (aIter != aEnd && SVGContentUtils::IsDigit(*aIter));
fracPart /= divisor;
}
bool gotE = false;
int32_t exponent = 0;
int32_t expSign;
if (aIter != aEnd && (*aIter == 'e' || *aIter == 'E')) {
RangedPtr<const char16_t> expIter(aIter);
++expIter;
if (expIter != aEnd) {
expSign = *expIter == '-' ? -1 : 1;
if (*expIter == '-' || *expIter == '+') {
++expIter;
}
if (expIter != aEnd && SVGContentUtils::IsDigit(*expIter)) {
// At this point we're sure this is an exponent
// and not the start of a unit such as em or ex.
gotE = true;
}
}
if (gotE) {
aIter = expIter;
do {
exponent = 10.0 * exponent + SVGContentUtils::DecimalDigitValue(*aIter);
++aIter;
} while (aIter != aEnd && SVGContentUtils::IsDigit(*aIter));
}
}
// Assemble the number
aValue = sign * (intPart + fracPart);
if (gotE) {
aValue *= pow(10.0, expSign * exponent);
}
return true;
}
template<class floatType>
bool
SVGContentUtils::ParseNumber(RangedPtr<const char16_t>& aIter,
const RangedPtr<const char16_t>& aEnd,
floatType& aValue)
{
RangedPtr<const char16_t> iter(aIter);
double value;
if (!::ParseNumber(iter, aEnd, value)) {
return false;
}
floatType floatValue = floatType(value);
if (!IsFinite(floatValue)) {
return false;
}
aValue = floatValue;
aIter = iter;
return true;
}
template bool
SVGContentUtils::ParseNumber<float>(RangedPtr<const char16_t>& aIter,
const RangedPtr<const char16_t>& aEnd,
float& aValue);
template bool
SVGContentUtils::ParseNumber<double>(RangedPtr<const char16_t>& aIter,
const RangedPtr<const char16_t>& aEnd,
double& aValue);
RangedPtr<const char16_t>
SVGContentUtils::GetStartRangedPtr(const nsAString& aString)
{
return RangedPtr<const char16_t>(aString.Data(), aString.Length());
}
RangedPtr<const char16_t>
SVGContentUtils::GetEndRangedPtr(const nsAString& aString)
{
return RangedPtr<const char16_t>(aString.Data() + aString.Length(),
aString.Data(), aString.Length());
}
template<class floatType>
bool
SVGContentUtils::ParseNumber(const nsAString& aString,
floatType& aValue)
{
RangedPtr<const char16_t> iter = GetStartRangedPtr(aString);
const RangedPtr<const char16_t> end = GetEndRangedPtr(aString);
return ParseNumber(iter, end, aValue) && iter == end;
}
template bool
SVGContentUtils::ParseNumber<float>(const nsAString& aString,
float& aValue);
template bool
SVGContentUtils::ParseNumber<double>(const nsAString& aString,
double& aValue);
/* static */
bool
SVGContentUtils::ParseInteger(RangedPtr<const char16_t>& aIter,
const RangedPtr<const char16_t>& aEnd,
int32_t& aValue)
{
RangedPtr<const char16_t> iter(aIter);
int32_t sign;
if (!ParseOptionalSign(iter, aEnd, sign)) {
return false;
}
if (!IsDigit(*iter)) {
return false;
}
int64_t value = 0;
do {
if (value <= std::numeric_limits<int32_t>::max()) {
value = 10 * value + DecimalDigitValue(*iter);
}
++iter;
} while (iter != aEnd && IsDigit(*iter));
aIter = iter;
aValue = int32_t(clamped(sign * value,
int64_t(std::numeric_limits<int32_t>::min()),
int64_t(std::numeric_limits<int32_t>::max())));
return true;
}
/* static */
bool
SVGContentUtils::ParseInteger(const nsAString& aString,
int32_t& aValue)
{
RangedPtr<const char16_t> iter = GetStartRangedPtr(aString);
const RangedPtr<const char16_t> end = GetEndRangedPtr(aString);
return ParseInteger(iter, end, aValue) && iter == end;
}
float
SVGContentUtils::CoordToFloat(nsSVGElement *aContent,
const nsStyleCoord &aCoord)
{
switch (aCoord.GetUnit()) {
case eStyleUnit_Factor:
// user units
return aCoord.GetFactorValue();
case eStyleUnit_Coord:
return nsPresContext::AppUnitsToFloatCSSPixels(aCoord.GetCoordValue());
case eStyleUnit_Percent: {
SVGSVGElement* ctx = aContent->GetCtx();
return ctx ? aCoord.GetPercentValue() * ctx->GetLength(SVGContentUtils::XY) : 0.0f;
}
default:
return 0.0f;
}
}
TemporaryRef<gfx::Path>
SVGContentUtils::GetPath(const nsAString& aPathString)
{
SVGPathData pathData;
nsSVGPathDataParser parser(aPathString, &pathData);
if (!parser.Parse()) {
return NULL;
}
RefPtr<DrawTarget> drawTarget =
gfxPlatform::GetPlatform()->ScreenReferenceDrawTarget();
RefPtr<PathBuilder> builder =
drawTarget->CreatePathBuilder(FillRule::FILL_WINDING);
return pathData.BuildPath(builder, NS_STYLE_STROKE_LINECAP_BUTT, 1);
}