PpGetCanvas()

Get the size of the current drawing area of a print context

Synopsis:

PhDim_t PpGetCanvas( PpPrintContext_t *pc );

Arguments:

pc
The pointer to a PpPrintContext_t structure that was returned by PpCreatePC().

Library:

ph

Description:

This function gets the size of the current drawing area associated with the given print context, taking into account the nonprintable area, margins, scale, and either the current source resolution or size.

If neither a source resolution nor source size has been set, 100 dpi is used, and PpGetCanvas() fills in the Pp_PC_SOURCE_RESOLUTION member of the print context.

Returns:

A PhDim_t structure that defines the dimensions of the rectangle, or (0, 0) if pc is invalid.

Classification:

Photon

Safety:
Interrupt handler No
Signal handler No
Thread No

See also:

PhDim_t, PpCreatePC(), PpGetPC(), PpPrintContext_t, PpReleasePC(), PpSetCanvas(), PpSetPC()

Printing chapter of the Programmer's Guide