Basic UI
Tabs
setDefaultTab("NAME HERE")
The following code demonstrates how to use setDefaultTab to create a new tab and add macros / buttons to that tab.
setDefaultTab("Test")
macro(100, "Testing", function()
info("test macro")
end)
addButton("id1", "Test Button", function()
info("test button")
end)
addTab("NAME HERE")
The following code demonstrates how to use addTab to create a new tab and add macros / buttons to that tab.
local newTab = addTab("Test")
macro(100, "Testing", function()
info("test macro")
end, newTab)
addButton("id1", "Test Button", function()
info("test button")
end, newTab)
It's recommended to use setDefaultTab instead of addTab as that will make it way easier to organize tabs by files instead of having to keep track of tab variables within your code.
No Comments