scrn-but.lua /size: 883 b    last modification: 2020-07-01 14:35
1
if
not
modules
then
modules
=
{
}
end
modules
[
'
scrn-but
'
]
=
{
2
version
=
1
.
001
,
3
comment
=
"
companion to scrn-but.mkiv
"
,
4
author
=
"
Hans Hagen, PRAGMA-ADE, Hasselt NL
"
,
5
copyright
=
"
PRAGMA ADE / ConTeXt Development Team
"
,
6
license
=
"
see context related readme files
"
7
}
8 9
local
context
=
context
10
local
f_two_colon
=
string
.
formatters
[
"
%s:%s:%s
"
]
11
local
v_section
=
interfaces
.
variables
.
section
12 13
local
function
registerbuttons
(
tag
,
register
,
language
)
14
local
data
=
sorters
.
definitions
[
language
]
15
local
orders
=
data
and
data
.
orders
or
sorters
.
definitions
.
default
.
orders
16
for
i
=
1
,
#
orders
do
17
local
order
=
orders
[
i
]
18
context
.
doregistermenubutton
(
tag
,
order
,
f_two_colon
(
register
,
v_section
,
order
)
)
19
end
20
end
21 22
interfaces
.
implement
{
23
name
=
"
registerbuttons
"
,
24
actions
=
registerbuttons
,
25
arguments
=
"
3 strings
"
,
26
}
27