PrintManager

StockSharp.Xaml.Diagram.GXDiagram

This class is responsible for printing a diagram.

Inherits: FrameworkElement

Implements: IDocumentPaginatorSource

Constructors

PrintManager
public PrintManager()
printManager = PrintManager()

Create a default PrintManager.

Properties

BackgroundTemplate
public DataTemplate BackgroundTemplate { get; set; }
value = printManager.BackgroundTemplate
printManager.BackgroundTemplate = value

Gets or sets the DataTemplate printed as the background for each page.

Bounds
public Rect Bounds { get; set; }
value = printManager.Bounds
printManager.Bounds = value

Gets or sets the area of the model to be printed, in model coordinates.

Diagram
public Diagram Diagram { get; internal set; }
value = printManager.Diagram
printManager.Diagram = value

Gets the Diagram for which this PrintManager performs printing.

DocumentPaginator
public virtual DocumentPaginator DocumentPaginator { get; }
value = printManager.DocumentPaginator

Do not use this property, but call DocumentPaginator}) to use a DocumentPaginator safely.

ForegroundTemplate
public DataTemplate ForegroundTemplate { get; set; }
value = printManager.ForegroundTemplate
printManager.ForegroundTemplate = value

Gets or sets the DataTemplate printed as the foreground for each page.

Margin
public Thickness Margin { get; set; }
value = printManager.Margin
printManager.Margin = value

Gets or sets the margins inside the page size, around the printed area.

PageOptions
public PrintPageOptions PageOptions { get; set; }
value = printManager.PageOptions
printManager.PageOptions = value

Gets or sets how printing fills each page.

Parts
public IEnumerable<Part> Parts { get; set; }
value = printManager.Parts
printManager.Parts = value

Gets or sets the collection of Parts to be printed.

Scale
public double Scale { get; set; }
value = printManager.Scale
printManager.Scale = value

Gets or sets the scale factor at which everything is printed.

Methods

OnCompleted
protected virtual void OnCompleted()
printManager.OnCompleted()

This is called after the print operation has completed.

Paginate
public void Paginate(Action<DocumentPaginator> act)
printManager.Paginate(act)

Use a DocumentPaginator in a safe manner.

act
an Action<DocumentPaginator> that is called with a DocumentPaginator with initialization work beforehand and cleanup work afterwards.
Print
public void Print(PrintDialog dlg)
printManager.Print(dlg)

Print the diagram using the choices made in the given PrintDialog.

dlg

Events

Completed
public event RoutedEventHandler Completed
printManager.Completed += handler

This RoutedEvent occurs when printing is completed.

Fields

BackgroundTemplateProperty
public static readonly DependencyProperty BackgroundTemplateProperty
value = PrintManager.BackgroundTemplateProperty

Identifies the BackgroundTemplate dependency property.

BoundsProperty
public static readonly DependencyProperty BoundsProperty
value = PrintManager.BoundsProperty

Identifies the Bounds dependency property.

CompletedEvent
public static readonly RoutedEvent CompletedEvent
value = PrintManager.CompletedEvent

Identifies the Completed routed event.

ForegroundTemplateProperty
public static readonly DependencyProperty ForegroundTemplateProperty
value = PrintManager.ForegroundTemplateProperty

Identifies the ForegroundTemplate dependency property.

MarginProperty
public static readonly DependencyProperty MarginProperty
value = PrintManager.MarginProperty

Identifies the Margin dependency property

PageOptionsProperty
public static readonly DependencyProperty PageOptionsProperty
value = PrintManager.PageOptionsProperty

Identifies the PageOptions dependency property.

PartsProperty
public static readonly DependencyProperty PartsProperty
value = PrintManager.PartsProperty

Identifies the Parts dependency property.

ScaleProperty
public static readonly DependencyProperty ScaleProperty
value = PrintManager.ScaleProperty

Identifies the Scale dependency property.