wpf-devexpress-dot-xpf-dot-diagram.md
Provides a canvas where you or your end-users can display, create and edit various diagrams.
Namespace : DevExpress.Xpf.Diagram
Assembly : DevExpress.Xpf.Diagram.v25.2.dll
NuGet Package : DevExpress.Wpf.Diagram
[DXLicenseWpf]
public class DiagramControl :
Control,
IDiagramControl
<DXLicenseWpf>
Public Class DiagramControl
Inherits Control
Implements IDiagramControl
The following members return DiagramControl objects:
See the Getting Started article to learn about capabilities of the Diagram Control.
The Examples section contains a variety of task-based examples.
The Diagram Designer Control represented by the DiagramDesignerControl class provides the complete visual interface. The End-User Interaction article describes end-user operations available in the Diagram Control and Diagram Designer Control.
The following code snippets (auto-collected from DevExpress Examples) contain references to the DiagramControl class.
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.
<Grid>
<dxdiag:DiagramControl ShowGrid="False" ShowRulers="False" ShowPageBreaks="False">
<dxmvvm:Interaction.Behaviors>
<Grid>
<dxdiag:DiagramControl ShowGrid="False" ShowRulers="False" ShowPageBreaks="False" CanvasSizeMode="Fill" >
<dxmvvm:Interaction.Behaviors>
wpf-generate-diagram-with-grouped-items/CS/DiagramNestedItemsExample/MainWindow.xaml#L34
<Grid>
<dxdiag:DiagramControl ConnectorsSeparationMode="AllLines" SelectedStencils="BasicShapes, BasicFlowchartShapes"
SugiyamaLayoutColumnSpacing="300"
wpf-diagram-bind-item-positions-to-source-objects/CS/dxSample/MainWindow.xaml#L26
<dxdiag:DiagramDataBindingBehavior.TemplateDiagram>
<dxdiag:DiagramControl
CanvasSizeMode="Fill"
wpf-diagram-mdi/CS/MainWindow.xaml#L33
<DataTemplate>
<dxdiag:DiagramControl
ActiveTool="{Binding Path=(dxdo:DockLayoutManager.DockLayoutManager).DataContext.ActiveTool, RelativeSource={RelativeSource Self}, Mode=TwoWay}"
Object DispatcherObject DependencyObject Visual UIElement FrameworkElement Control DiagramControl DiagramDesignerControl
See Also