toString method
Returns the ANSI escape code string that applies this color configuration.
If no colors are set, returns an empty string.
Implementation
@override
String toString() {
if (fg != null) {
return '${ansiEsc}38;5;${fg}m';
} else if (bg != null) {
return '${ansiEsc}48;5;${bg}m';
} else {
return '';
}
}