String returns the ANSI escape sequence.
()
| 75 | |
| 76 | // String returns the ANSI escape sequence. |
| 77 | func (s *Style) String() string { |
| 78 | if len(s.codes) == 0 { |
| 79 | return "" |
| 80 | } |
| 81 | return esc + strings.Join(s.codes, ";") + "m" |
| 82 | } |
| 83 | |
| 84 | // Format returns a format string for use with fmt.Printf. |
| 85 | func (s *Style) Format() string { |
no outgoing calls