DynamicDocumentPaginator Class

Provides an abstract base class that supports automatic background pagination and tracking content positions across repaginations in addition to the methods and properties of its own base class.

System.Object
  System.Windows.Documents.DocumentPaginator
    System.Windows.Documents.DynamicDocumentPaginator

Namespace:  System.Windows.Documents
Assembly:  PresentationCore (in PresentationCore.dll)

[<AbstractClass>]
type DynamicDocumentPaginator =  
    class 
        inherit DocumentPaginator 
    end

The DynamicDocumentPaginator type exposes the following members.

  NameDescription
Protected methodDynamicDocumentPaginatorInitializes a new instance of the DynamicDocumentPaginator class.
Top

  NameDescription
Public propertyIsBackgroundPaginationEnabledGets or sets a value indicating whether pagination is performed automatically in the background in response to certain events, such as a change in page size.
Public propertyIsPageCountValidWhen overridden in a derived class, gets a value indicating whether PageCount is the total number of pages. (Inherited from DocumentPaginator.)
Public propertyPageCountWhen overridden in a derived class, gets a count of the number of pages currently formatted (Inherited from DocumentPaginator.)
Public propertyPageSizeWhen overridden in a derived class, gets or sets the suggested width and height of each page. (Inherited from DocumentPaginator.)
Public propertySourceWhen overridden in a derived class, returns the element being paginated. (Inherited from DocumentPaginator.)
Top

  NameDescription
Public methodCancelAsyncCancels a previous GetPageAsync or DynamicDocumentPaginator.GetPageNumberAsync operation. (Inherited from DocumentPaginator.)
Public methodComputePageCountForces a pagination of the content, updates PageCount with the new total, and sets IsPageCountValid to true. (Inherited from DocumentPaginator.)
Public methodComputePageCountAsync()Asynchronously, forces a pagination of the content, updates PageCount with the new total, and sets IsPageCountValid to true. (Inherited from DocumentPaginator.)
Public methodComputePageCountAsync(Object)Asynchronously, forces a pagination of the content, updates PageCount with the new total, sets IsPageCountValid to true. (Inherited from DocumentPaginator.)
Public methodEquals(Object)Determines whether the specified object is equal to the current object. (Inherited from Object.)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public methodGetHashCodeServes as the default hash function. (Inherited from Object.)
Public methodGetObjectPositionWhen overridden in a derived class, returns a ContentPosition for the specified Object.
Public methodGetPageWhen overridden in a derived class, gets the DocumentPage for the specified page number. (Inherited from DocumentPaginator.)
Public methodGetPageAsync(Int32)Asynchronously returns (through the GetPageCompleted event) the DocumentPage for the specified page number. (Inherited from DocumentPaginator.)
Public methodGetPageAsync(Int32, Object)Asynchronously returns (through the GetPageCompleted event) the DocumentPage for the specified page number and assigns the specified ID to the asynchronous task. (Inherited from DocumentPaginator.)
Public methodGetPageNumberWhen overridden in a derived class, returns the zero-based page number of the specified ContentPosition.
Public methodGetPageNumberAsync(ContentPosition)Asynchronously, returns (through the This method raises the GetPageNumberCompleted event) the zero-based page number of the specified ContentPosition.
Public methodGetPageNumberAsync(ContentPosition, Object)Asynchronously, returns (through the This method raises the GetPageNumberCompleted event) the zero-based page number of the specified ContentPosition.
Public methodGetPagePositionWhen overridden in a derived class, gets the position of the specified page in the document's content.
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object. (Inherited from Object.)
Protected methodOnComputePageCountCompletedRaises the ComputePageCountCompleted event. (Inherited from DocumentPaginator.)
Protected methodOnGetPageCompletedRaises the GetPageCompleted event. (Inherited from DocumentPaginator.)
Protected methodOnGetPageNumberCompletedRaises the GetPageNumberCompleted event.
Protected methodOnPagesChangedRaises the PagesChanged event. (Inherited from DocumentPaginator.)
Protected methodOnPaginationCompletedRaises the PaginationCompleted event.
Protected methodOnPaginationProgressRaises the PaginationProgress event.
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)
Top

  NameDescription
Public eventComputePageCountCompletedOccurs when a ComputePageCountAsync operation has finished. (Inherited from DocumentPaginator.)
Public eventGetPageCompletedOccurs when GetPageAsync has completed. (Inherited from DocumentPaginator.)
Public eventGetPageNumberCompletedOccurs when GetPageNumberAsync has completed.
Public eventPagesChangedOccurs when the document content is changed. (Inherited from DocumentPaginator.)
Public eventPaginationCompletedOccurs when all document content has been paginated.
Public eventPaginationProgressOccurs when one or more content pages have been paginated.
Top

By default, a DynamicDocumentPaginator will automatically pre-paginate content in the background (this process begins when IsBackgroundPaginationEnabled is true, which is the default setting).

When IsBackgroundPaginationEnabled is true, the layout will also be repaginated due to changes in content or changes in PageSize.

The PaginationProgress event occurs upon completion of pagination (or repagination) of one or more pages, such as in the following situations:

A PaginationCompleted event also occurs when background pagination is disabled. For example, if there is only one page of content and IsBackgroundPaginationEnabled = false), calling GetPage with an argument of 0 will result in two events:

  1. A PaginationProgress event with PaginationProgressEventArgs settings of Start = 0 and Count = 1.

  2. A PaginationCompleted event.

.NET Framework

Supported in: 4.5, 4, 3.5, 3.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft