Function

CTFontDescriptorCopyLocalizedAttribute

Returns a localized value for the requested attribute, if available.

Declaration

CFTypeRef CTFontDescriptorCopyLocalizedAttribute(CTFontDescriptorRef descriptor, CFStringRef attribute, CFStringRef  _Nullable *language);

Parameters

descriptor

The font descriptor.

attribute

The requested font attribute.

language

On output, contains a reference to the matched language. The language identifier will conform to the RFC 3066bis standard.

Return Value

A retained reference to a localized attribute based on the global language list.

Discussion

This function passes back the matched language in language. If localization is not possible for the attribute, the behavior matches the value returned from CTFontDescriptorCopyAttribute. Generally, localization of attributes is applicable to name attributes of only a normalized font descriptor.

See Also

Getting Attributes

CTFontDescriptorCopyAttributes

Returns the attributes dictionary of the font descriptor.

CTFontDescriptorCopyAttribute

Returns the value associated with an arbitrary attribute.