Contents

transformingAttributes(_:_:)

Returns an attributed string by calling a closure that transforms one attribute of a source attributed string.

Declaration

@preconcurrency func transformingAttributes<K>(_ k: K.Type, _ c: (inout AttributedString.SingleAttributeTransformer<K>) -> Void) -> AttributedString where K : AttributedStringKey, K.Value : Sendable

Parameters

Return Value

An attributed string with the applied transformation to the specified attribute.

See Also

Transforming Attributes