<color name="ListboxSelectedForeground" color="#ffffff" />
<color name="ListboxMarkedBackground" color="#ff0000" />
<color name="ListboxMarkedForeground" color="#ffffff" />
+ <color name="ListboxMarkedAndSelectedBackground" color="#800000" />
+ <color name="ListboxMarkedAndSelectedForeground" color="#ffffff" />
<color name="WindowTitleForeground" color="#ffffff" />
<color name="WindowTitleBackground" color="#33294a6b" />
<borderset name="bsWindow">
<widget name="scan_state" position="10,65" size="280,60" font="Regular;20" />
<widget name="servicelist" position="10,135" size="280,175" selectionDisabled="1" />
</screen>
- <screen name="InputBox" position="100,100" size="550,400" title="Input" >
+ <screen name="InputBox" position="100,100" size="550,60" title="Input" >
<widget name="text" position="0,0" size="550,25" font="Regular;20" />
<widget name="input" position="0,30" size="550,25" font="Regular;20" />
- </screen>"""
+ </screen>
+ <screen name="ChoiceBox" position="100,100" size="550,400" title="Input" >
+ <widget name="text" position="0,0" size="550,25" font="Regular;20" />
+ <widget name="list" position="0,30" size="550,335" scrollbarMode="showOnDemand" />
+ <applet type="onLayoutFinish">
+# this should be factored out into some helper code, but currently demonstrates applets.
+from enigma import eSize, ePoint
+
+orgwidth = self.instance.size().width()
+orgpos = self.instance.position()
+textsize = self["text"].getSize()
+
+# y size still must be fixed in font stuff...
+textsize = (textsize[0] + 50, textsize[1] + 50)
+count = len(self.list)
+if count > 6:
+ count = 6
+offset = 30 * count
+wsizex = textsize[0] + 60
+wsizey = textsize[1] + offset
+if (400 > wsizex):
+ wsizex = 400
+wsize = (wsizex, wsizey)
+
+
+# resize
+self.instance.resize(eSize(*wsize))
+
+# resize label
+self["text"].instance.resize(eSize(*textsize))
+
+# move list
+listsize = (wsizex, 30 * len(self.list))
+self["list"].instance.move(ePoint(0, textsize[1]))
+self["list"].instance.resize(eSize(*listsize))
+
+# center window
+newwidth = wsize[0]
+self.instance.move(ePoint(orgpos.x() + (orgwidth - newwidth)/2, orgpos.y()))
+ </applet>
+ </screen>
<screen name="TimerEdit" position="70,100" size="590,335" title="Timer Edit">
<widget name="description" position="10,10" size="580,40" font="Regular;25" />
<widget name="lbegin" position="405,102" size="103,30" font="Regular;25" foregroundColor="red" />