summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/context/sample/demo-cld.cld
blob: 7e470da62970fdc97c8b8a33ee540eb32a2c8e2f (plain)
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
-- context.enabletrackers {"tud.trace"}

context.setuplayout( {
  width  = "middle",
  height = "middle",
})

context.showframe()

context.starttext()

context.chapter({ "someref" }, "Hello There")

context.readfile("tufte","","not found")

context.startitemize({ "packed" })
  for i=1,10 do
    context.startitem()
      context("this is item %i",i)
    context.stopitem()
  end
context.stopitemize()

context.startchapter({ title = "test" }, { more = "oeps" })

  context["in"]("chapter",{ "someref" })

  context.startlinecorrection( { "blank" })
  context.bTABLE()
    for i=1,10 do
      context.bTR()
        for i=1,20 do
          context.bTD({ align= "middle", style = "type" })
            context("%#2i",math.random(99))
          context.eTD()
        end
      context.eTR()
    end
  context.eTABLE()
  context.stoplinecorrection()

  context.mathematics("x^{2 \\times 4}")

  context.placefigure("caption", function()
    context.externalfigure( { "cow.pdf" } )
  end)

  context.placefigure("caption", function()
    context.bTABLE()
      context.bTR()
        context.bTD()
          context.externalfigure( { "cow.pdf" }, { width = "3cm", height = "3cm" } )
        context.eTD()
        context.bTD({ align = "{lohi,middle}" } )
          context("and")
        context.eTD()
        context.bTD()
          context.externalfigure( { "cow.pdf" }, { width = "4cm", height = "3cm" } )
        context.eTD()
      context.eTR()
    context.eTABLE()
  end)

context.stopchapter()

context.chapter("Speed Test 1")

for i=1,50 do
  context.readfile("tufte","","not found")
  context.par()
end

context.stoptext()