pdf.add_page
result = pdf.add_page(src, index, [width=], [height=])
Input: src, index, width, height · Output: result
What it is
Inserts a blank page at index (numbered from 1; one past the last page appends). width/height are in PDF points, defaulting to A4 (595 × 842) when omitted -- no paper-size convention exists elsewhere in the engine, and this matches what this module's own test fixtures already use. The new page has a real, empty content stream (a legitimate blank page).
Overloads
One call shape — this function is not overloaded.
| Code | Input | Output | Description |
result = pdf.add_page(src, index, [width=], [height=]) | src —not documented yetindex —Inserts a blank page at index (numbered from 1.width optionalwidth/height are in PDF points, defaulting to A4 (595 × 842) when omitted -- no paper-size convention exists elsewhere in the engine, and this matches what this module's own test fixtures already use.height optionalwidth/height are in PDF points, defaulting to A4 (595 × 842) when omitted -- no paper-size convention exists elsewhere in the engine, and this matches what this module's own test fixtures already use. | result Vec | Returns a Vec of bytes, the new PDF. |
Examples
No documentation example calls this form yet. The File I/O chapter is where one belongs.