style system overhaul

This commit is contained in:
airstruck
2015-11-09 17:14:40 -05:00
parent f866442cf1
commit 058d9351e5
9 changed files with 86 additions and 83 deletions

View File

@@ -35,19 +35,19 @@ local style = {
local mainForm = { id = 'mainWindow', type = 'panel',
{ type = 'menu', id = 'menubar', flow = 'x',
{ text = 'File', id = 'menuFile',
{ text = 'Save', id = 'menuFileSave', },
{ text = 'Quit' },
{ text = 'Save', id = 'menuFileSave', key = 'ctrl-s' },
{ text = 'Quit', id = 'menuQuit', key = 'escape' },
},
{ text = 'Edit',
{ text = 'Cut' },
{ text = 'Copy' },
{ text = 'Paste' },
{ text = 'Cut', key = 'ctrl-c' },
{ text = 'Copy', key = 'ctrl-x' },
{ text = 'Paste', key = 'ctrl-v' },
{ type = 'slider' },
},
{ text = 'View',
{ text = 'Theme',
{ text = 'Light' },
{ text = 'Dark' },
{ text = 'Light', key = 'ctrl-l' },
{ text = 'Dark', key = 'ctrl-d' },
},
{ text = 'Style',
{ text = 'Default' },
@@ -161,4 +161,12 @@ erge rg eg erg er ergs erg er ge rh erh rth]]
layout.mainCanvas.align = 'top'
print(layout.menuQuit)
--[[
Layout.menuQuit:onPress(function (event)
love.event.quit()
end)
]]
layout:show()