Table of Contents

Property MaxPagesLimit

Namespace
DocWright.Layout
Assembly
DocWright.Layout.dll

MaxPagesLimit

Gets or sets an optional ceiling on the pages layout may start. Null means no cap.

public int? MaxPagesLimit { get; set; }

Property Value

int?

Remarks

This is the caller's ResourceLimits.MaxPages, checked as each page is started: starting the page past the cap throws ResourceLimitExceededException with LimitName MaxPages and the number of that page as the observed value. Until Phase 72 the facade compared the count only after layout had finished, so the cap bounded what was rendered and not what was laid out: a kilobyte of input can ask for a hundred thousand pages, and every one of them was composed before the refusal.

Layout may compose a document more than once (field results that depend on the page count, column balancing), and the cap applies to every pass: a page any pass starts is a page laid out.

Exceptions

ArgumentOutOfRangeException

The value is not positive.