Files
HandyControl/Net35/HandyControl_Net35/Expression/Drawing/PathGeometryHelper.cs
T
2019-01-21 00:43:10 +08:00

25 lines
681 B
C#

using System.Windows.Media;
namespace HandyControl.Expression.Drawing
{
internal static class PathGeometryHelper
{
public static bool IsStroked(this PathSegment pathSegment) => pathSegment.IsStroked;
public static PathGeometry AsPathGeometry(this Geometry original)
{
if (original == null)
{
return null;
}
if (!(original is PathGeometry geometry))
{
return PathGeometry.CreateFromGeometry(original);
}
return geometry;
}
internal static Geometry FixPathGeometryBoundary(Geometry geometry) => geometry;
}
}