Sprintf formats according to a format specifier and returns the resulting string. Input will be colored with the parent Color.
(format string, a ...any)
| 160 | // Sprintf formats according to a format specifier and returns the resulting string. |
| 161 | // Input will be colored with the parent Color. |
| 162 | func (c Color) Sprintf(format string, a ...any) string { |
| 163 | return c.Sprint(Sprintf(format, a...)) |
| 164 | } |
| 165 | |
| 166 | // Sprintfln formats according to a format specifier and returns the resulting string. |
| 167 | // Spaces are always added between operands and a newline is appended. |