save method
Saves the state of the current context.
![]() ![]() |
Syntax
CanvasRenderingContext2D.save();Parameters
This method has no parameters.
Return value
This method does not return a value.
Standards information
- HTML Canvas 2D Context, Section 2
Remarks
The save and restore methods preserve and restore the state of a context, but not specific paths or graphics. The following attributes and states are affected:
- The current transformation matrix
- The current clipping region
- The current values of the following attributes:
Attribute
See also
Show:

