- if self.skinAttributes is not None:
- attribs = [ ]
- for (attrib, value) in self.skinAttributes:
- if attrib == "EntryForegroundColor":
- self.foreColor = parseColor(value).argb()
- elif attrib == "EntryForegroundColorSelected":
- self.foreColorSelected = parseColor(value).argb()
- elif attrib == "EntryBorderColor":
- self.borderColor = parseColor(value).argb()
- elif attrib == "EntryBackgroundColor":
- self.backColor = parseColor(value).argb()
- elif attrib == "EntryBackgroundColorSelected":
- self.backColorSelected = parseColor(value).argb()
- elif attrib == "ServiceNameForegroundColor":
- self.foreColorService = parseColor(value).argb()
- elif attrib == "ServiceNameBackgroundColor":
- self.backColorService = parseColor(value).argb()
- else:
- attribs.append((attrib,value))
- self.skinAttributes = attribs
+ def EntryForegroundColor(value):
+ self.foreColor = parseColor(value).argb()
+ def EntryForegroundColorSelected(value):
+ self.foreColorSelected = parseColor(value).argb()
+ def EntryBackgroundColor(value):
+ self.backColor = parseColor(value).argb()
+ def EntryBackgroundColorSelected(value):
+ self.backColorSelected = parseColor(value).argb()
+ def EntryBorderColor(value):
+ self.borderColor = parseColor(value).argb()
+ def EntryItemHeight(value):
+ self.itemHeight = int(value)
+ def ServiceNameForegroundColor(value):
+ self.foreColorService = parseColor(value).argb()
+ def ServiceNameBackgroundColor(value):
+ self.backColorService = parseColor(value).argb()
+ def ServiceFont(value):
+ self.serviceFont = parseFont(value, ((1,1),(1,1)) )
+ def EntryFont(value):
+ self.entryFont = parseFont(value, ((1,1),(1,1)) )
+
+ for (attrib, value) in list(self.skinAttributes):
+ try:
+ locals().get(attrib)(value)
+ self.skinAttributes.remove((attrib, value))
+ except:
+ pass
+ self.l.setFont(0, self.serviceFont)
+ self.l.setFont(1, self.entryFont)
+ self.l.setItemHeight(self.itemHeight)