Returns a tibble with one row per page covering the cheap
per-page facts: width, height (both in PDF user-space points,
pre-rotation), rotation in degrees, and the page label (if any).
The per-page values come from the existing single-page readers
pdf_page_size() (fast FPDF_GetPageSizeByIndexF path),
pdf_page_rotation(), and pdf_page_labels(); no per-page
pdf_page_load() is required for any of them, so the function
is efficient on long documents.
Arguments
- doc
A
pdfium_docfrompdf_doc_open(), or a character path.- password
Optional password for encrypted PDFs when
docis a path. Ignored whendocis an openpdfium_doc.
Value
A tibble with columns:
page_num— integer, 1-based.width,height— numeric, PDF user-space points.rotation— integer,0/90/180/270.label— character; the page's/PageLabelsentry, orNAwhen the document has no labels.
Details
For deeper per-page facts (annotation count, object count, text
content, …) load each page individually with pdf_page_load()
and call the per-page readers.
See also
pdf_doc_summary() for the doc-level companion;
pdf_page_size(), pdf_page_rotation(), pdf_page_labels()
for the per-row readers.
Examples
fixture <- system.file("extdata", "fixtures", "minimal.pdf",
package = "pdfium"
)
if (nzchar(fixture)) pdf_pages_summary(fixture)
#> # A tibble: 1 × 5
#> page_num width height rotation label
#> <int> <dbl> <dbl> <int> <chr>
#> 1 1 288 216 0 NA