Jeff07971 wrote:
> Thanks Gizmoh !
I managed to get the alarm working :-)
After enabling the "Alarm Settings" menue you have to edit the
PFTFTSkinApplet.lua file and change the lines starting at "local
_timeFirstColumnX12h":
Code:
--------------------
local _timeFirstColumnX12h = 48
local _timeFirstColumnX24h = 83
s.time_input_background_12h = {
w = WH_FILL,
h = screenHeight - TITLE_HEIGHT,
position = LAYOUT_NONE,
img = _loadImage(self,
"Multi_Character_Entry/tch_multi_char_bkgrd_3c.png"),
x = 0,
y = TITLE_HEIGHT,
}
s.time_input_background_24h = {
w = WH_FILL,
h = screenHeight - TITLE_HEIGHT,
position = LAYOUT_NONE,
img = _loadImage(self,
"Multi_Character_Entry/tch_multi_char_bkgrd_2c.png"),
x = 0,
y = TITLE_HEIGHT,
}
s.time_input_menu_box_12h = {
position = LAYOUT_NONE,
img = _loadImage(self,
"Multi_Character_Entry/menu_box_fixed.png"),
w = 220,
h = 37,
x = 50,
y = 127,
}
s.time_input_menu_box_24h = _uses(s.time_input_menu_box_12h, {
img = _loadImage(self, "UNOFFICIAL/menu_box_fixed_2c.png"),
w = 180,
x = 87,
})
-- time input window
s.input_time_12h = _uses(s.window)
s.input_time_12h.hour = _uses(s.menu, {
w = 75,
--h = screenHeight - TITLE_HEIGHT,
h = screenHeight,
itemHeight = 38,
position = LAYOUT_WEST,
padding = 0,
border = { _timeFirstColumnX12h, TITLE_HEIGHT, 0, 0 },
item = {
bgImg = false,
order = { 'text' },
text = {
align = 'right',
font = _boldfont(30),
padding = { 2, 4, 8, 0 },
fg = { 0xb3, 0xb3, 0xb3 },
sh = { },
},
},
selected = {
item = {
order = { 'text' },
bgImg = false,
text = {
font = _boldfont(30),
fg = { 0xe6, 0xe6, 0xe6 },
sh = { },
align = 'right',
padding = { 2, 4, 8, 0 },
},
},
},
pressed = {
item = {
order = { 'text' },
bgImg = false,
text = {
font = _boldfont(30),
fg = { 0xe6, 0xe6, 0xe6 },
sh = { },
align = 'right',
padding = { 2, 4, 8, 0 },
},
},
},
})
s.input_time_12h.minute = _uses(s.input_time_12h.hour, {
border = { _timeFirstColumnX12h + 75, TITLE_HEIGHT, 0, 0 },
})
s.input_time_12h.ampm = _uses(s.input_time_12h.hour, {
border = { _timeFirstColumnX12h + 75 + 75, TITLE_HEIGHT, 0, 0 },
item = {
text = {
padding = { 0, 2, 8, 0 },
font = _boldfont(26),
},
},
selected = {
item = {
text = {
padding = { 0, 4, 8, 0 },
font = _boldfont(26),
},
},
},
pressed = {
item = {
text = {
padding = { 0, 4, 8, 0 },
font = _boldfont(26),
},
},
},
})
s.input_time_12h.hourUnselected = s.input_time_12h.hour
s.input_time_12h.minuteUnselected = s.input_time_12h.minute
s.input_time_12h.ampmUnselected = s.input_time_12h.ampm
s.input_time_24h = _uses(s.input_time_12h, {
hour = {
border = { _timeFirstColumnX24h, TITLE_HEIGHT, 0, 0 },
},
minute = {
border = { _timeFirstColumnX24h + 75, TITLE_HEIGHT, 0,
0 },
},
hourUnselected = {
border = { _timeFirstColumnX24h, TITLE_HEIGHT, 0, 0 },
},
minuteUnselected = {
border = { _timeFirstColumnX24h + 75, TITLE_HEIGHT, 0,
0 },
},
})
--------------------
Also you have to exchange the pictures in the PITFTSkin/images folder
with the ones attached.
Have fun :-)
+-------------------------------------------------------------------+
|Filename: Multi_Character_Entry.zip |
|Download: http://forums.slimdevices.com/attachment.php?attachmentid=19956|
+-------------------------------------------------------------------+
------------------------------------------------------------------------
Gizmoh's Profile: http://forums.slimdevices.com/member.php?userid=56513
View this thread: http://forums.slimdevices.com/showthread.php?t=98156
_______________________________________________
unix mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/unix