text entry, more keyboard support

This commit is contained in:
airstruck
2015-11-02 00:16:48 -05:00
parent 0a36a6b411
commit 4baea757ef
2 changed files with 129 additions and 60 deletions

View File

@@ -75,8 +75,7 @@ local mainForm = { title = "Test window", id = 'mainWindow', type = 'panel',
},
{ type = 'sash', height = 4, },
{ type = 'panel', flow = 'x', height = 48, padding = 2,
{ type = 'text', id = 'aTextField', text = 'a text field',
font = 'font/liberation/LiberationMono-Regular.ttf' },
{ type = 'text', id = 'aTextField', text = 'a text field' },
{ type = 'button', key='return', width = 80, id = 'aButton', text = 'Styling!' },
},
{ type = 'panel', id = 'statusbar', height = 24, padding = 4, textColor = { 255, 0, 0 } },
@@ -131,6 +130,8 @@ layout.newButton:onPress(function (event)
print('creating a new thing!')
end)
layout.mainCanvas.font = 'font/liberation/LiberationMono-Regular.ttf'
layout.mainCanvas.text = [[Abedede sdfsdf asfdsdfdsfs sdfsdfsdf
sfsdfdfbv db er erg rth tryj ty j fgh dfgv
wefwef rgh erh rth e rgs dvg eh tyj rt h erg