git.cweiske.de
/
enigma2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
replace EOF magic by a slightly more accurate PVR EOF.
[enigma2.git]
/
lib
/
python
/
Components
/
Label.py
diff --git
a/lib/python/Components/Label.py
b/lib/python/Components/Label.py
index 5f74b75c8164503e98385e5494057816d7fb8b85..49e94e6e34ed5c6e5b1f0936fd6c2d2ede0df3d5 100644
(file)
--- a/
lib/python/Components/Label.py
+++ b/
lib/python/Components/Label.py
@@
-46,20
+46,32
@@
class MultiColorLabel(Label):
def applySkin(self, desktop, screen):
if self.skinAttributes is not None:
def applySkin(self, desktop, screen):
if self.skinAttributes is not None:
+ foregroundColor = None
+ backgroundColor = None
attribs = [ ]
for (attrib, value) in self.skinAttributes:
if attrib == "foregroundColors":
colors = value.split(',')
attribs = [ ]
for (attrib, value) in self.skinAttributes:
if attrib == "foregroundColors":
colors = value.split(',')
- attribs.append(("foregroundColor",colors[0] ))
for color in colors:
self.foreColors.append(parseColor(color))
for color in colors:
self.foreColors.append(parseColor(color))
+ if not foregroundColor:
+ foregroundColor = colors[0]
elif attrib == "backgroundColors":
colors = value.split(',')
elif attrib == "backgroundColors":
colors = value.split(',')
- attribs.append(("backgroundColor",colors[0] ))
for color in colors:
self.backColors.append(parseColor(color))
for color in colors:
self.backColors.append(parseColor(color))
+ if not backgroundColor:
+ backgroundColor = colors[0]
+ elif attrib == "backgroundColor":
+ backgroundColor = value
+ elif attrib == "foregroundColor":
+ foregroundColor = value
else:
attribs.append((attrib,value))
else:
attribs.append((attrib,value))
+ if foregroundColor:
+ attribs.append(("foregroundColor",foregroundColor))
+ if backgroundColor:
+ attribs.append(("backgroundColor",backgroundColor))
self.skinAttributes = attribs
return GUIComponent.applySkin(self, desktop, screen)
self.skinAttributes = attribs
return GUIComponent.applySkin(self, desktop, screen)