Template repo for tiny cross-platform apps that can be modified on phone, tablet or computer.
1{
2 {type='rows', default={font={size=21}, line_height=35},
3 {type='text', font={size=28}, line_height=50,
4 {'Lua@{Lua} > top-level',
5 attrs={
6 Lua={target='--lua'},
7 }},
8 },
9 {type='filler', height=15},
10 {type='text', 'Todos os programas Lua são feitos de alguns tipos de coisas.'},
11 {type='filler', height=15},
12 {type='text', 'x = 34', font={size=24}},
13 {type='text', ' Definições de variáveis'},
14 {type='filler', height=10},
15 {type='text', 'function add(a, b) return a+b end', font={size=24}},
16 {type='text', ' Definições de funções'},
17 {type='text', " (Pode conter múltiplas instruções antes do 'end'. Incluindo definições de variáveis.)"},
18 {type='filler', height=10},
19 {type='text', 'x = add(3, 4)', font={size=24}},
20 {type='text', ' Definições de variáveis podem chamar funções (definidas acima/anteriormente)'},
21 {type='filler', height=10},
22 {type='text', 'add = function(a, b) return a+b end', font={size=24}},
23 {type='text', ' Apenas uma forma alternativa de definir a função acima. Um nome de função é apenas um tipo de nome de variável.'},
24 }
25}