Creates a new PostScript surface
Path to the PostScript file to write to
Width of the surface in points (1 point = 1/72 inch)
Height of the surface in points (1 point = 1/72 inch)
Finishes the surface and drops all references to external resources
Performs all pending drawing operations
Returns user data attached to the surface (C API: cairo_surface_get_user_data)
Key used when setting the data
The attached data or null
Gets the device offset of the surface
An array with [x, y] device offset
Gets the device scale of the surface
An array with [x, y] device scale
Attaches user data to the surface (C API: cairo_surface_set_user_data)
Key for the user data
Data to attach
Optionaldestroy: (data: unknown) => voidOptional callback when the surface is destroyed or data is replaced
Sets the device offset of the surface
X offset
Y offset
Sets the device scale of the surface
X scale factor
Y scale factor
A surface that produces output in the PostScript format