GetPageContentLayerCount
Page manipulation
Description
Returns the number of content layers on the selected page. A page whose /Contents entry is a single stream reports one layer; an array-valued /Contents entry reports one layer per array element
Syntax
Delphi
Function TPDFlib.GetPageContentLayerCount: Integer;
Return values
| >= 1 | The number of content layers on the selected page |
|---|---|
| 0 | No document is loaded, or the selected page has no content |
Remarks
Layer indexes for ParsePageContentLayer and WritePageContentLayer are 1-based, so valid layer numbers run from 1 up to the returned count. Layers are edited independently; a single layer may legitimately begin or end inside an open graphics object, so unbalanced q/Q or BT/ET within one layer is tolerated. The function takes no parameters and always works on the currently selected page
See also
ParsePageContentLayer, WritePageContentLayer, GetPageContentBox, GetPageContentToString