Search
Printing and Print Preview

You can print a Diagram using the standard WPF printing facilities. The DocumentPaginator property lets you print a multiple-page diagram. The following example shows how to use it:

C#  Copy Code

PrintDialog pd = new PrintDialog();

if (pd.ShowDialog())
    pd.PrintDocument(diagram.DocumentPaginator, "my diagram");

As a shortcut, WpfDiagram provides the Print and PrintPreview methods, which use DocumentPaginator internally to print the diagram content, or to preview how it would look when printed.