Back to Devexpress

LineStyle.DashStyle Property

wpf-devexpress-dot-xpf-dot-charts-dot-linestyle-0583898f.md

latest3.9 KB
Original Source

LineStyle.DashStyle Property

Specifies the dash style used to paint the line.

Namespace : DevExpress.Xpf.Charts

Assembly : DevExpress.Xpf.Charts.v25.2.dll

NuGet Package : DevExpress.Wpf.Charts

Declaration

csharp
[DXDesignerSerializableProperty(XtraSerializationVisibility.Content)]
public DashStyle DashStyle { get; set; }
vb
<DXDesignerSerializableProperty(XtraSerializationVisibility.Content)>
Public Property DashStyle As DashStyle

Property Value

TypeDescription
DashStyle

A DashStyle object that represents the sequence of dashes and gaps for the line style.

|

The following code snippets (auto-collected from DevExpress Examples) contain references to the DashStyle 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.

wpf-charts-custom-draw-crosshair-cursor/CS/CrosshairCustomDraw/MainWindow.xaml.cs#L21

csharp
e.CrosshairLineElement.Brush = Brushes.Aqua;
e.CrosshairLineElement.LineStyle.DashStyle = DashStyles.DashDot;
e.CrosshairLineElement.LineStyle.Thickness = 3;

dashboard-constant-lines/CS/ConstantLineExtension.WPF/ConstantLinesConverter.cs#L42

csharp
line.LineStyle = new LineStyle();
line.LineStyle.DashStyle = new DashStyle(new double[] { 3, 4 }, 0);
line.LineStyle.Thickness = 2;

wpf-dashboard-custom-properties/CS/Wpf-Dashboard-Custom-Properties/Modules/ChartItemModule/ChartOptions/ConstantLine.cs#L53

csharp
line.LineStyle.Thickness = 2;
line.LineStyle.DashStyle = DashStyles.Dash;
line.Title = new ConstantLineTitle();

wpf-charts-custom-draw-crosshair-cursor/VB/CrosshairCustomDraw/MainWindow.xaml.vb#L25

vb
e.CrosshairLineElement.Brush = Brushes.Aqua
e.CrosshairLineElement.LineStyle.DashStyle = DashStyles.DashDot
e.CrosshairLineElement.LineStyle.Thickness = 3

wpf-dashboard-custom-properties/VB/Wpf-Dashboard-Custom-Properties/Modules/ChartItemModule/ChartOptions/ConstantLine.vb#L75

vb
line.LineStyle.Thickness = 2
line.LineStyle.DashStyle = DashStyles.Dash
line.Title = New ConstantLineTitle()

See Also

LineStyle Class

LineStyle Members

DevExpress.Xpf.Charts Namespace