Contents

initWithFormat:options:locale:arguments:

Initializes an attributed string by substituting a list of function arguments into a specially formatted string.

Declaration

- (instancetype) initWithFormat:(NSAttributedString *) format options:(NSAttributedStringFormattingOptions) options locale:(NSLocale *) locale arguments:(va_list) arguments;

Parameters

  • format:

    The format string to use to create the final string. For a list of format specifiers you can include in this string, see TP40004265.

  • options:

    Options for how to apply attributes to the string’s content.

  • locale:

    The locale to use for formatting the string. The locale controls the formatting of region-sensitive values such as numbers and currencies.

  • arguments:

    A list of arguments to substitute into the format string.

Return Value

An initialized attributed string that combines the format string with the provided arguments and other information.

See Also

Creating a formatted string