x-udhr.mkiv /size: 1821 b    last modification: 2020-07-01 14:35
1
%D \module
2
%D [ file=x-udhr,
3
%D version=2011.06.11,
4
%D title=\CONTEXT\ Modules,
5
%D subtitle=Unicode Language Test Files,
6
%D author=Hans Hagen,
7
%D date=\currentdate,
8
%D copyright={PRAGMA ADE \& \CONTEXT\ Development Team}]
9
%C
10
%C This module is part of the \CONTEXT\ macro||package and is
11
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
12
%C details.
13 14
%D The XML files can be fetched from: \from[http://unicode.org/udhr/].
15 16
\startmodule
[
udhr
]
17 18
\startxmlsetups
udhr
:
basics
19
\xmlsetsetup
{
#
1
}
{
*
}
{
udhr
:
*
}
20
\stopxmlsetups
21 22
\xmlregistersetup
{
udhr
:
basics
}
23 24
\startxmlsetups
udhr
:
udhr
25 26
\mainlanguage
[
\xmlatt
{
#
1
}{
language
}
]
27 28
\starttitle
[
title
=
\xmltext
{
#
1
}{
/
title
}
]
29
\xmlfirst
{
#
1
}{
/
preamble
}
30
\xmlall
{
#
1
}{
/
article
}
31
\stoptitle
32 33
\stopxmlsetups
34 35
\startxmlsetups
udhr
:
preamble
36
\startsubject
[
title
=
\xmltext
{
#
1
}{
/
title
}
]
37
\xmlall
{
#
1
}{
/
*
)
}
38
\stopsubject
39
\stopxmlsetups
40 41
\startxmlsetups
udhr
:
article
42
\startsubject
[
title
=
\xmltext
{
#
1
}{
/
title
}
]
43
\xmlall
{
#
1
}{
/
*
)
}
44
\stopsubject
45
\stopxmlsetups
46 47
\startxmlsetups
udhr
:
orderedlist
48
\startitemize
[
n
]
49
\xmlflush
{
#
1
}
50
\stopitemize
51
\stopxmlsetups
52 53
\startxmlsetups
udhr
:
listitem
54
\startitem
55
\xmlflush
{
#
1
}
56
\stopitem
57
\stopxmlsetups
58 59
\startxmlsetups
udhr
:
para
60
\xmlflush
{
#
1
}
61
\par
62
\stopxmlsetups
63 64
\setupbodyfont
65
[
dejavu
,
1
0
pt
]
66 67
\setuplayout
68
[
width
-
=
middle
,
69
height
=
middle
,
70
footer
=
0
cm
,
71
header
=
1
.
5
cm
]
72 73
\setupwhitespace
74
[
big
]
75 76
\setuphead
77
[
chapter
]
78
[
header
=
high
,
79
style
=
\bfb
,
80
align
=
middle
]
81 82
\setuphead
83
[
section
]
84
[
style
=
\bfa
,
85
align
=
middle
]
86 87
\setuptolerance
88
[
verytolerant
]
89 90
\continueifinputfile
{
x
-
udhr
.
mkiv
}
91 92
% todo: when argument given then process it
93 94
\starttext
95
\xmlprocessfile
{
main
}{
udhr
_
nld
.
xml
}{}
96
\stoptext
97 98
\stopmodule
99