Important: The information in this document is obsolete and should not be used for new development.
GetPatternTo get a pattern (
'PAT ') resource stored in a resource file, you can use the
FUNCTION GetPattern (patID: Integer): PatHandle;
- The resource ID for a resource of type
GetPatternfunction returns a handle to the pattern having the resource ID that you specify in the patID parameter. The
GetPatternfunction calls the following Resource Manager function with these parameters:
GetResource('PAT ', patID);If a pattern resource with the ID that you request does not exist, the
The data structure of type
PatHandleis defined as follows:
TYPE PatPrt = ^Pattern; PatHandle = ^PatPtr; Pattern = PACKED ARRAY[0..7] OF 0..255;When you are finished using the pattern, dispose of its handle with the Memory Manager function
GetPatternfunction may move or purge memory blocks in the application heap. Your application should not call this function at interrupt time.
SEE ALSOThe pattern resource is described on page 3-136; the
Patternrecord is described on page 3-36. See the chapter "Resource Manager" in Inside Macintosh: More Macintosh Toolbox for more information about resources, the Resource Manager, and the
GetResourcefunction. See Inside Macintosh: Memory for information about the