Commit 8f779fcb authored by cyril andreichuk's avatar cyril andreichuk
Browse files

If the focal point isn't given at all, its assumed to be at the same place as the center point.

http://www.w3.org/TR/SVG/pservers.html#RadialGradientElementFXAttribute
parent 39f3a940
......@@ -33,14 +33,36 @@ namespace Svg
[SvgAttribute("fx")]
public SvgUnit FocalX
{
get { return this.Attributes.GetAttribute<SvgUnit>("fx"); }
get
{
var value = this.Attributes.GetAttribute<SvgUnit>("fx");
if (value.IsEmpty || value.IsNone)
{
value = this.CenterX;
}
return value;
}
set { this.Attributes["fx"] = value; }
}
[SvgAttribute("fy")]
public SvgUnit FocalY
{
get { return this.Attributes.GetAttribute<SvgUnit>("fy"); }
get
{
var value = this.Attributes.GetAttribute<SvgUnit>("fy");
if (value.IsEmpty || value.IsNone)
{
value = this.CenterY;
}
return value;
}
set { this.Attributes["fy"] = value; }
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment