In This Article

PrinterPageNumberMargin Class

Represents a default implementation of a page number margin for an IPrinterView.

public class PrinterPageNumberMargin : PrinterViewMarginBase, IPrinterViewMargin, ITextViewMargin, IOrderable, IKeyedObject
Inheritance:
object Visual UIElement FrameworkElement Control PrinterViewMarginBase object
Implements:
IPrinterViewMargin ITextViewMargin IOrderable IKeyedObject

Constructors

PrinterPageNumberMargin(IPrinterView)

Initializes an instance of the class.

public PrinterPageNumberMargin(IPrinterView view)
Parameter Type Description
view IPrinterView

The IPrinterView that will host the margin.

Properties

PageNumberText

The pages number text.

public string PageNumberText { get; }

Property Value

string

Methods

Draw(TextViewDrawContext)

Draws the margin and its content.

public override void Draw(TextViewDrawContext context)
Parameter Type Description
context TextViewDrawContext

The TextViewDrawContext to use for rendering.

MeasureOverride(Size)

Called to remeasure a control.

protected override Size MeasureOverride(Size availableSize)
Parameter Type Description
availableSize Size

Returns

Size:

The size of the control, up to the maximum specified by constraint.

UpdateVisibility()

Updates the visibility of the margin.

public override void UpdateVisibility()

Inherited Members

Extension Methods