NSMutableAttributedString

public extension NSMutableAttributedString
  • Simple Swift wrapper for setAttributes(_ attrs: [NSAttributedString.Key : Any]?, range: NSRange)

    Declaration

    Swift

    @discardableResult
    func set(attributes: StringAttributes, range: ClosedRange<Int>) -> Self

    Parameters

    attributes

    StringAttributes is a typealias for [NSAttributedString.Key : Any],

    range

    Closed Int Range. Example: 0 … 3