---
title: "CTFontCollectionCopyFontAttributes(_:_:_:)"
framework: coretext
role: symbol
role_heading: Function
path: "coretext/ctfontcollectioncopyfontattributes(_:_:_:)"
---

# CTFontCollectionCopyFontAttributes(_:_:_:)

Retrieves an array of dictionaries containing font descriptor attribute values.

## Declaration

```swift
func CTFontCollectionCopyFontAttributes(_ collection: CTFontCollection, _ attributeNames: CFSet, _ options: CTFontCollectionCopyOptions) -> CFArray
```

## Parameters

- `collection`: The font collection reference.
- `attributeNames`: The attributes to retrieve for each descriptor in the collection.
- `options`: Options to alter the return value. With doc://com.apple.coretext/documentation/CoreText/CTFontCollectionCopyOptions/kCTFontCollectionCopyDefaultOptions, the values appear in the same order as the results from doc://com.apple.coretext/documentation/CoreText/CTFontCollectionCreateMatchingFontDescriptors(_:). Setting doc://com.apple.coretext/documentation/CoreText/CTFontCollectionCopyOptions/unique removes duplicate values. Setting doc://com.apple.coretext/documentation/CoreText/CTFontCollectionCopyOptions/standardSort sorts the values in standard UI order.

## Return Value

Return Value An array that contains one CFDictionary value for each descriptor mapping the specified attribute names.

## See Also

### Get Font Descriptor Attributes

- [CTFontCollectionCopyFontAttribute(_:_:_:)](coretext/ctfontcollectioncopyfontattribute(_:_:_:).md)
