<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "macOS: -",
    "tvOS: -",
    "visionOS: -",
    "watchOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "CoreText",
  "identifier" : "/documentation/CoreText/CTFontCollectionSortDescriptorsCallback",
  "metadataVersion" : "0.1.0",
  "role" : "Type Alias",
  "symbol" : {
    "kind" : "Type Alias",
    "modules" : [
      "Core Text"
    ],
    "preciseIdentifier" : "c:@T@CTFontCollectionSortDescriptorsCallback"
  },
  "title" : "CTFontCollectionSortDescriptorsCallback"
}
-->

# CTFontCollectionSortDescriptorsCallback

The collection sorting callback type.

```
typealias CTFontCollectionSortDescriptorsCallback = (CTFontDescriptor, CTFontDescriptor, UnsafeMutableRawPointer) -> CFComparisonResult
```

## Parameters

`first`

The first descriptor.

`second`

The second descriptor.

`refCon`

A pointer to contextual data from the client.

## Return Value

The matching font descriptors of a collection in sorted order.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)