Timerlist - added eventNameFont for timername size
authorims <ims21@users.sourceforge.net>
Sun, 25 Jan 2015 13:34:43 +0000 (14:34 +0100)
committerlittlesat <littlesat99@yahoo.com>
Sun, 25 Jan 2015 16:30:18 +0000 (17:30 +0100)
Signed-off-by: littlesat <littlesat99@yahoo.com>

lib/python/Components/TimerList.py

index 00af6e1..635713e 100644 (file)
@@ -27,7 +27,7 @@ class TimerList(HTMLComponent, GUIComponent, object):
                        serviceNameWidth = width - 200 - self.iconWidth - self.iconMargin
 
                res.append((eListboxPythonMultiContent.TYPE_TEXT, width - serviceNameWidth, 0, serviceNameWidth, self.rowSplit, 0, RT_HALIGN_RIGHT|RT_VALIGN_BOTTOM, serviceName))
-               res.append((eListboxPythonMultiContent.TYPE_TEXT, self.iconWidth + self.iconMargin, 0, width - serviceNameWidth - self.iconWidth - self.iconMargin, self.rowSplit, 1, RT_HALIGN_LEFT|RT_VALIGN_BOTTOM, timer.name))
+               res.append((eListboxPythonMultiContent.TYPE_TEXT, self.iconWidth + self.iconMargin, 0, width - serviceNameWidth - self.iconWidth - self.iconMargin, self.rowSplit, 2, RT_HALIGN_LEFT|RT_VALIGN_BOTTOM, timer.name))
 
                begin = FuzzyTime(timer.begin)
                if timer.repeated:
@@ -89,6 +89,7 @@ class TimerList(HTMLComponent, GUIComponent, object):
                self.l.setBuildFunc(self.buildTimerEntry)
                self.serviceNameFont = gFont("Regular", 20)
                self.font = gFont("Regular", 18)
+               self.eventNameFont = gFont("Regular", 18)
                self.l.setList(list)
                self.itemHeight = 50
                self.rowSplit = 25
@@ -110,6 +111,8 @@ class TimerList(HTMLComponent, GUIComponent, object):
                        self.itemHeight = int(value)
                def setServiceNameFont(value):
                        self.serviceNameFont = parseFont(value, ((1,1),(1,1)))
+               def setEventNameFont(value):
+                       self.eventNameFont = parseFont(value, ((1,1),(1,1)))
                def setFont(value):
                        self.font = parseFont(value, ((1,1),(1,1)))
                def rowSplit(value):
@@ -127,6 +130,7 @@ class TimerList(HTMLComponent, GUIComponent, object):
                self.l.setItemHeight(self.itemHeight)
                self.l.setFont(0, self.serviceNameFont)
                self.l.setFont(1, self.font)
+               self.l.setFont(2, self.eventNameFont)
                return GUIComponent.applySkin(self, desktop, parent)
 
        def getCurrent(self):