---
title: width
framework: foundation
role: symbol
role_heading: Instance Property
path: foundation/measurement/formatstyle/width
---

# width

The width of the measurement unit.

## Declaration

```swift
var width: Measurement<UnitType>.FormatStyle.UnitWidth
```

## Discussion

Discussion The width property specifies the display of the measurement unit. The possible values are abbreviated, narrow, and wide. The format style represents the unit in the shortest notation available. The following example shows 100 degrees Fahrenheit in each width for the en_US locale. let temperatureMeasurement = Measurement<UnitTemperature>(value: 100, unit: .fahrenheit) temperatureMeasurement.formatted(.measurement(width: .wide)) // 100 degrees Fahrenheit temperatureMeasurement.formatted(.measurement(width: .abbreviated)) // 100°F temperatureMeasurement.formatted(.measurement(width: .narrow)) // 100°

## See Also

### Modifying a measurement format style

- [Measurement.FormatStyle.UnitWidth](foundation/measurement/formatstyle/unitwidth.md)
- [numberFormatStyle](foundation/measurement/formatstyle/numberformatstyle.md)
- [usage](foundation/measurement/formatstyle/usage.md)
- [hidesScaleName](foundation/measurement/formatstyle/hidesscalename.md)
- [locale](foundation/measurement/formatstyle/locale.md)
- [locale(_:)](foundation/measurement/formatstyle/locale(_:).md)
