MCPcopy Index your code
hub / github.com/pymupdf/PyMuPDF / new_page

Function new_page

src_classic/utils.py:1843–1859  ·  view source on GitHub ↗

Create and return a new page object. Args: pno: (int) insert before this page. Default: after last page. width: (float) page width in points. Default: 595 (ISO A4 width). height: (float) page height in points. Default 842 (ISO A4 height). Returns: A Page obje

(
    doc: Document,
    pno: int = -1,
    width: float = 595,
    height: float = 842,
)

Source from the content-addressed store, hash-verified

1841
1842
1843def new_page(
1844 doc: Document,
1845 pno: int = -1,
1846 width: float = 595,
1847 height: float = 842,
1848) -> Page:
1849 """Create and return a new page object.
1850
1851 Args:
1852 pno: (int) insert before this page. Default: after last page.
1853 width: (float) page width in points. Default: 595 (ISO A4 width).
1854 height: (float) page height in points. Default 842 (ISO A4 height).
1855 Returns:
1856 A Page object.
1857 """
1858 doc._newPage(pno, width=width, height=height)
1859 return doc[pno]
1860
1861
1862def insert_page(

Callers

nothing calls this directly

Calls 1

_newPageMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…