Add a COLOR_TIME_STRING theming option
This commit is contained in:
parent
2697159c89
commit
7bd6dd37c2
2 changed files with 5 additions and 0 deletions
|
@ -201,6 +201,7 @@ class Theme(object):
|
|||
# Time
|
||||
CHAR_TIME_LEFT = ''
|
||||
CHAR_TIME_RIGHT = ''
|
||||
COLOR_TIME_STRING = (-1, -1)
|
||||
|
||||
# Tabs
|
||||
COLOR_TAB_NORMAL = (7, 4)
|
||||
|
|
|
@ -102,7 +102,11 @@ class BaseTextWin(Win):
|
|||
Write the date on the yth line of the window
|
||||
"""
|
||||
if time:
|
||||
color = get_theme().COLOR_TIME_STRING
|
||||
curses_color = to_curses_attr(color)
|
||||
self._win.attron(curses_color)
|
||||
self.addstr(time)
|
||||
self._win.attroff(curses_color)
|
||||
self.addstr(' ')
|
||||
|
||||
def resize(self, height, width, y, x, room=None):
|
||||
|
|
Loading…
Reference in a new issue