Skip to main content

DiagramItem.StrokeDashArray Property

Gets or sets a collection of System.Double values that indicate the pattern of dashes and gaps that is used to outline diagram items. This is a dependency property.

Namespace: DevExpress.Xpf.Diagram

Assembly: DevExpress.Xpf.Diagram.v23.2.dll

NuGet Package: DevExpress.Wpf.Diagram

Declaration

[Browsable(false)]
public DoubleCollection StrokeDashArray { get; set; }

Property Value

Type Description
DoubleCollection

A collection of System.Double values that specify the pattern of dashes and gaps.

Remarks

The following code snippet illustrates how to create a shape with a dashed outline.

DiagramShape shape = new DiagramShape() { Height = 10, Width = 10, Shape = BasicShapes.Rectangle,
    StrokeDashArray = new DoubleCollection() { 3, 6 }, Stroke = Brushes.Red };
diagram.Items.Add(shape);

The image below shows the result.

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the StrokeDashArray property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also