MCPcopy
hub / github.com/pterm/pterm / Sprintf

Method Sprintf

color.go:162–164  ·  view source on GitHub ↗

Sprintf formats according to a format specifier and returns the resulting string. Input will be colored with the parent Color.

(format string, a ...any)

Source from the content-addressed store, hash-verified

160// Sprintf formats according to a format specifier and returns the resulting string.
161// Input will be colored with the parent Color.
162func (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.

Callers 1

PrintfMethod · 0.95

Calls 2

SprintMethod · 0.95
SprintfFunction · 0.85

Tested by

no test coverage detected