---
title: "width(for:rectEdge:)"
framework: appkit
role: symbol
role_heading: Instance Method
path: "appkit/nstextblock/width(for:rectedge:)"
---

# width(for:rectEdge:)

## Declaration

```swift
func width(for layer: NSTextBlock.Layer, rectEdge: CGRectEdge) -> CGFloat
```
