1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27\registerctxluafile{libsimpzint}{autosuffix}
28
29\unprotect
30
31\definefont[usedzintfont][dejavusansmono at 10bp]
32
33\permanent\protected\def\barcode[#S#1]
34 {\bgroup
35 \usedzintfont
36 \getdummyparameters
37 [\c!alternative=,\c!text=,\c!option=,#1]
38 \scale
39 [#1]
40 {\clf_zint
41 code {\dummyparameter\c!alternative}
42 text {\dummyparameter\c!text}
43 option {\dummyparameter\c!option}
44 \relax}
45 \egroup}
46
47\protect
48
49\continueifinputfile{libsimpzint.mkxl}
50
51\starttext
52
53\dontcomplain
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77 \startTEXpage
78 \startluacode
79 for i=1,100 do
80 context.dontleavehmode()
81 context.barcode {
82 alternative = "datamatrix",
83 text = string.rep("!",i),
84 }
85 context.space()
86 context.allowbreak()
87 end
88 \stopluacode
89 \stopTEXpage
90
91 \startTEXpage
92 \startluacode
93 for i=1,100 do
94 context.dontleavehmode()
95 context.barcode {
96 alternative = "datamatrix",
97 text = string.rep("!",i),
98 option = "square",
99 }
100 context.space()
101 context.allowbreak()
102 end
103 \stopluacode
104 \stopTEXpage
105
106 \startluacode
107 for i=1,25 do
108 context.startTEXpage()
109 context.dontleavehmode()
110 context(i)
111 context.space()
112 context.barcode {
113 alternative = "datamatrix",
114 text = string.rep("!",i),
115 }
116 context.space()
117 context.barcode {
118 alternative = "datamatrix",
119 text = string.rep("!",i),
120 option = "square",
121 }
122 context.stopTEXpage()
123 end
124 \stopluacode
125\stoptext
126 |