core :: Text :: apply_format
private fun apply_format(f: TermCharFormat): String do if stdout_isatty or force_console_colors then return "{f}{self}{normal}" else return to_s end