summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/stex/schema/rnc/omdoc/xhtml-table.rnc
blob: ab2b4d20ee460e42dd4b49cfa9c225d07af47b1a (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
# Tables Module

# This builds on the basic tables module, unlike with the DTD
# implementation.

include "xhtml-basic-table.rnc" {
  table =
    element table {
      table.attlist,
      caption?,
      (col* | colgroup*),
      ((thead?, tfoot?, tbody+) | tr+)
    }
  th = element th { th.attlist & Flow.model }
  td = element td { td.attlist & Flow.model }
  CellHAlign.attrib =
    attribute align {
      "left" | "center" | "right" | "justify" | "char"
    }? &
    attribute char { Character.datatype }? &
    attribute charoff { Length.datatype }?
  CellVAlign.attrib =
    attribute valign { "top" | "middle" | "bottom" | "baseline" }?
  scope.attrib =
    attribute scope { "row" | "col" | "rowgroup" | "colgroup" }?
}
table.attlist &=
  attribute width { Length.datatype }? &
  attribute border { Pixels.datatype }? &
  frame.attrib &
  rules.attrib &
  attribute cellspacing { Length.datatype }? &
  attribute cellpadding { Length.datatype }?
col = element col { col.attlist }
col.attlist =
  Common.attrib &
  attribute span { Number.datatype }? &
  attribute width { MultiLength.datatype }? &
  CellHAlign.attrib &
  CellVAlign.attrib
colgroup = element colgroup { colgroup.attlist & col* }
colgroup.attlist =
  Common.attrib &
  attribute span { Number.datatype }? &
  attribute width { MultiLength.datatype }? &
  CellHAlign.attrib &
  CellVAlign.attrib
tbody = element tbody { tbody.attlist & tr+ }
tbody.attlist = Common.attrib & CellHAlign.attrib & CellVAlign.attrib
thead = element thead { thead.attlist & tr+ }
thead.attlist = Common.attrib & CellHAlign.attrib & CellVAlign.attrib
tfoot = element tfoot { tfoot.attlist & tr+ }
tfoot.attlist = Common.attrib & CellHAlign.attrib & CellVAlign.attrib
frame.attrib =
  attribute frame {
    "void"
    | "above"
    | "below"
    | "hsides"
    | "lhs"
    | "rhs"
    | "vsides"
    | "box"
    | "border"
  }?
rules.attrib =
  attribute rules { "none" | "groups" | "rows" | "cols" | "all" }?