HPDFCMapEnterDepthLimit

Enter a thread-local CMap inheritance depth scope and hand back the previous limit

Declaration

function HPDFCMapEnterDepthLimit(MaxDepth: Integer): Integer;

Unit

HPDFCMapReader

Usage notes

A positive MaxDepth caps the zero-based parent depth; root depth zero and one parent at depth one are admitted by a limit of one

A nonpositive value keeps the structural ceiling of 32 CMap streams, whose last admitted depth is 31; a larger requested limit cannot lift that ceiling

Save the returned value and call HPDFCMapLeaveDepthLimit from a finally block, nested calls, exceptions and cancellation included; the scope leaves THPDFCMapBounds layout alone

See Native Cairo rendering for aggregate rendering budgets and cancellation