Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Imaging With QuickDraw /
Chapter 4 - Color QuickDraw / Color QuickDraw Reference
Color QuickDraw Routines / Reporting Data Structure Changes to QuickDraw


PortChanged

If you modify the content of a GrafPort record (described in the chapter "Basic QuickDraw" in this book) or CGrafPort record (described on page 4-39), including any of the data structures specified by handles within the record, use the PortChanged procedure.

PROCEDURE PortChanged (port: GrafPtr);
port
A pointer to the GrafPort record that you have changed.
DESCRIPTION
The PortChanged procedure notifies QuickDraw that your application has changed the graphics port specified in the port parameter. If your application has changed a CGrafPort record, it must coerce its pointer (that is, its CGrafPtr) to a pointer to a GrafPort record (that is, to a GrafPtr) before passing the pointer in the port parameter.

You generally should not directly change any of the PixPat records specified in a CGrafPort record, but instead use the PenPixPat and BackPixPat procedures. However, if your application does change the content of a PixPat record, it should call the PixPatChanged procedure (described in the preceding section) as well as the PortChanged procedure.

If your application changes the pmTable field of the PixMap record specified in the graphics port, your application should call PortChanged. If your application changes the content of the ColorTable record referenced by the pmTable field, it should call CTabChanged as well.

ASSEMBLY-LANGUAGE INFORMATION
The trap macro and routine selector for the PortChanged procedure are
Trap macroSelector
_QDExtensions$00040009


Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996