def print_e(string, context=None): """Print errors.""" # Translators: "E" as in "Error". It is prepended to # terminal output. APT uses a similar output format. prefix = _("E:") + " " string = _format_print(string, Colorise.red(prefix)) _print(string, sys.stderr) # Translators: Name of the warnings tab in the Output Log window quodlibet.util.logging.log(clicolor.strip_color(string), "errors")
def print_e(string, context=None): """Print errors.""" # Translators: "E" as in "Error". It is prepended to # terminal output. APT uses a similar output format. prefix = _("E: ") string = _format_print(string, Colorise.red(prefix)) _print(string, sys.stderr) # Translators: Name of the warnings tab in the Output Log window quodlibet.util.logging.log(clicolor.strip_color(string), _("Errors"))
def print_w(string): """Print warnings.""" # Translators: "W" as in "Warning". It is prepended to # terminal output. APT uses a similar output format. prefix = _("W:") + " " string = _format_print(string, Colorise.red(prefix)) _print(string, sys.stderr) # Translators: Name of the warnings tab in the Output Log window quodlibet.util.logging.log(clicolor.strip_color(string), "warnings")
def print_w(string): """Print warnings.""" # Translators: "W" as in "Warning". It is prepended to # terminal output. APT uses a similar output format. prefix = _("W:") + " " string = _format_print(string, Colorise.red(prefix)) if PY2: _print(string, sys.stderr) else: _print(string, sys.stderr.buffer) # Translators: Name of the warnings tab in the Output Log window quodlibet.util.logging.log(clicolor.strip_color(string), "warnings")