MacroPackage: common-graphicsToCDocOverviewCGDocRelNotesIndexPermutedIndex
Allegro CL version 6.2
Minimally revised from 6.1

restoring-graphics-context

Arguments: (stream) &body body

Calls copy-graphics-context to save the current drawing style options of stream, then executes the body, and then calls set-graphics-context to restore the saved drawing style options. stream should be a cg-stream.

This allows the body code to arbitrarily set temporary drawing style options without explicitly setting each one back afterward. An unwind-protect is used to ensure that the final call to set-graphics-context is always performed (as long as the call to copy-graphics-context was completed successfully). Returns the values returned by the body.

See copy-graphics-context (where all the information in a graphics-context object is described), make-graphics-context, set-graphics-context, and graphics-context-p.


Copyright (c) 1998-2002, Franz Inc. Oakland, CA., USA. All rights reserved.
Documentation for Allegro CL version 6.2. This page has had minimal revisions compared to the 6.1 page.
Created 2002.2.26.

ToCDocOverviewCGDocRelNotesIndexPermutedIndex
Allegro CL version 6.2
Minimally revised from 6.1