Class ShapeFactory
Shape factory.
Inheritance
Namespace: Telerik.Windows.Controls.Diagrams
Assembly: Telerik.Windows.Controls.Diagrams.dll
Syntax
public static class ShapeFactory : Object
Properties
ArrowGeometries
Gets the arrow geometries.
Declaration
public static Dictionary<ArrowShapeType, Geometry> ArrowGeometries { get; }
Property Value
System.Collections.Generic.Dictionary<ArrowShapeType, System.Windows.Media.Geometry>
|
Remarks
See also the example in the CommonGeometries.
See Also
CommonGeometries
Gets the common geometries.
Declaration
public static Dictionary<CommonShapeType, Geometry> CommonGeometries { get; }
Property Value
System.Collections.Generic.Dictionary<CommonShapeType, System.Windows.Media.Geometry>
|
Examples
The following snippet of XAML binds this source of geometries to a ListBox;
<ListBox x:Name="ShapeList" >
<ListBox.ItemTemplate>
<DataTemplate>
<Path Data="{Binding Path=Value}" Tag="{Binding Path=Key}" Stroke="Orange" StrokeThickness="1" Margin="2" />
</DataTemplate>
</ListBox.ItemTemplate>
<ListBox.ItemsPanel>
<ItemsPanelTemplate>
<WrapPanel Width="300" />
</ItemsPanelTemplate>
</ListBox.ItemsPanel>
</ListBox>
See Also
FlowchartGeometries
Gets the flowchart geometries.
Declaration
public static Dictionary<FlowChartShapeType, Geometry> FlowchartGeometries { get; }
Property Value
System.Collections.Generic.Dictionary<FlowChartShapeType, System.Windows.Media.Geometry>
|
Remarks
See also the example in the CommonGeometries.
See Also
Methods
CreateCircle(Double, Double, Point)
Declaration
public static RadDiagramShape CreateCircle(double radiusX, double radiusY, Point center)
Parameters
System.Double
radiusX
|
System.Double
radiusY
|
System.Windows.Point
center
|
Returns
RadDiagramShape
|
CreateRectangle(Rect)
Declaration
public static RadDiagramShape CreateRectangle(Rect rect)
Parameters
System.Windows.Rect
rect
|
Returns
RadDiagramShape
|
GetShapeGeometry(ArrowShapeType)
Gets a geometry of a specified arrow shape type.
Declaration
public static Geometry GetShapeGeometry(ArrowShapeType shapeType)
Parameters
ArrowShapeType
shapeType
|
Returns
System.Windows.Media.Geometry
|
GetShapeGeometry(CommonShapeType)
Gets a geometry of a specified common shape type.
Declaration
public static Geometry GetShapeGeometry(CommonShapeType shapeType)
Parameters
CommonShapeType
shapeType
|
Returns
System.Windows.Media.Geometry
|
GetShapeGeometry(FlowChartShapeType)
Gets a geometry of a specified flow chart shape type.
Declaration
public static Geometry GetShapeGeometry(FlowChartShapeType shapeType)
Parameters
FlowChartShapeType
shapeType
|
Returns
System.Windows.Media.Geometry
|