SAVE_CTM

short Escape(hdc, SAVE_CTM, NULL, NULL, NULL)

The SAVE_CTM printer escape saves the current transformation matrix.

The current transformation matrix controls the manner in which coordinates are translated, rotated, and scaled by the device. By using matrices, an application can combine these operations in any order to produce the desired mapping for a particular picture.

An application can restore the matrix by using the RESTORE_CTM escape.

An application typically saves the current transformation matrix before changing it. This allows the application to restore the previous state upon completion of a particular operation.

Parameters

hdc

HDC Identifies the device context.

Return Value

The return value specifies the number of SAVE_CTM escape calls without a corresponding RESTORE_CTM call. The return value is zero if the escape is unsuccessful.

Comments

This escape is used only by PostScript printer drivers.

Applications should not make any assumptions about the initial contents of the current transformation matrix.

Applications are expected to restore the contents of the current transformation matrix.