Carbon


ATSUOverwriteAttributes

Header: ATSUnicode.h Carbon status: Supported

Copies all previously set style run attributes, font features, and font variations in a source style object into a destination style object.

OSStatus ATSUOverwriteAttributes (
    ATSUStyle iSourceStyle, 
    ATSUStyle iDestinationStyle
);
Parameter descriptions
iSourceStyle

A reference to a style object whose previously set style run attribute, font feature, and font variation values you want to copy. Note that all previously set values will be copied, whether or not they are also set in the destination style object. You cannot pass NULL for this parameter.

iDestinationStyle

A reference to a style object whose corresponding values you want to replace. You cannot pass NULL for this parameter.

function result

A result code.

DISCUSSION

The ATSUOverwriteAttributes function copies all values other than defaults from a style object. Unlike the function ATSUUnderwriteAttributes, these values can be set in the destination object. All other quantities in the destination style object are left unchanged.

ATSUOverwriteAttributes does not copy the contents of memory referenced by pointers or handles within custom style run attributes or within reference constants. You are responsible for ensuring that this memory remains valid until the source style object is disposed of.

If you wish to create a style object that contains the contents of another style object, call the function ATSUCreateAndCopyStyle. To copy the contents of a style object into an existing style object, call the function ATSUCopyAttributes. To copy style run attributes, font features, and font variations that are set in the source but not in the destination style object, call the function ATSUUnderwriteAttributes.

ATSUOverwriteAttributes may allocate memory in your application heap, unless you designate a different heap by calling the function ATSUCreateMemorySetting.

VERSION NOTES

Available beginning with ATSUI 1.0.

AVAILABILITY

Supported in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 8.5 or later.


© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)