summaryrefslogtreecommitdiff
path: root/src/leap/util/leap_log_handler.py
diff options
context:
space:
mode:
authorIvan Alejandro <ivanalejandro0@yahoo.com.ar>2013-07-10 18:30:20 -0300
committerIvan Alejandro <ivanalejandro0@yahoo.com.ar>2013-07-12 14:10:03 -0300
commit0cc747fbe97b7015e51504949546b47e2b110a68 (patch)
tree5b3576e650be13ac988620607d0ccac3b5fa90a2 /src/leap/util/leap_log_handler.py
parent54f14a3b34ed530472602413e70fc0b91d18d36a (diff)
Improve LoggerWindow log colors.
Diffstat (limited to 'src/leap/util/leap_log_handler.py')
-rw-r--r--src/leap/util/leap_log_handler.py17
1 files changed, 1 insertions, 16 deletions
diff --git a/src/leap/util/leap_log_handler.py b/src/leap/util/leap_log_handler.py
index 271096d3..9adb21a5 100644
--- a/src/leap/util/leap_log_handler.py
+++ b/src/leap/util/leap_log_handler.py
@@ -52,22 +52,7 @@ class LogHandler(logging.Handler):
:param logging_level: the debug level to define the color.
:type logging_level: str.
"""
- html_style = {
- 'DEBUG': "color: blue",
- 'INFO': "color: black",
- 'WARNING': "color: black; background: yellow;",
- 'ERROR': "color: red",
- 'CRITICAL': "color: red; font-weight: bold;"
- }
-
- style_open = "<span style='" + html_style[logging_level] + "'>"
- style_close = "</span>"
- time = "%(asctime)s"
- name = style_open + "%(name)s"
- level = "%(levelname)s"
- message = "%(message)s" + style_close
- format_attrs = [time, name, level, message]
- log_format = ' - '.join(format_attrs)
+ log_format = '%(asctime)s - %(name)s - %(levelname)s - %(message)s'
formatter = logging.Formatter(log_format)
return formatter