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


func CTFontDescriptorCopyLocalizedAttribute(_ descriptor: CTFontDescriptor, _ attribute: CFString, _ language: UnsafeMutablePointer<Unmanaged<CFString>?>?) -> CFTypeRef?



The font descriptor.


The requested font attribute.


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.


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

func CTFontDescriptorCopyAttributes(CTFontDescriptor) -> CFDictionary

Returns the attributes dictionary of the font descriptor.

func CTFontDescriptorCopyAttribute(CTFontDescriptor, CFString) -> CFTypeRef?

Returns the value associated with an arbitrary attribute.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software