RelaxNG/publidoc.rng
author Patrick PIERRE <patrick.pierre@prismallia.fr>
jeu., 10 nov. 2011 13:04:58 +0100
changeset 53 37e9f6428d02
parent 50 5181169ff02d
child 56 5e5ea407a594
permissions -rw-r--r--
Ajout de <sup>, <sub> dans <keyword>
patrick@0
     1
<?xml version="1.0" encoding="UTF-8"?>
patrick@0
     2
<grammar xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
patrick@0
     3
  <!-- $Id$ -->
patrick@0
     4
  <start>
patrick@0
     5
    <ref name="publidoc"/>
patrick@0
     6
  </start>
patrick@0
     7
  <define name="publidoc">
patrick@0
     8
    <element name="publidoc">
patrick@0
     9
      <ref name="publidoc.attributes"/>
patrick@0
    10
      <ref name="publidoc.content"/>
patrick@0
    11
    </element>
patrick@0
    12
  </define>
patrick@0
    13
  <define name="publidoc.attributes">
patrick@0
    14
    <ref name="version.attribute"/>
patrick@0
    15
  </define>
patrick@0
    16
  <define name="version.attribute">
patrick@0
    17
    <attribute name="version">
patrick@0
    18
      <value>1.0</value>
patrick@0
    19
    </attribute>
patrick@0
    20
  </define>
patrick@0
    21
  <define name="publidoc.content">
patrick@0
    22
    <choice>
patrick@0
    23
      <ref name="document"/>
patrick@0
    24
      <ref name="top.topic"/>
patrick@0
    25
    </choice>
patrick@0
    26
  </define>
patrick@0
    27
  <!--
patrick@0
    28
    =============================================================================
patrick@20
    29
                                     TOP LEVEL
patrick@0
    30
    =============================================================================
patrick@0
    31
  -->
patrick@0
    32
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ document ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
    33
  <define name="document">
patrick@0
    34
    <element name="document">
patrick@0
    35
      <ref name="document.attributes"/>
patrick@0
    36
      <ref name="document.content"/>
patrick@0
    37
    </element>
patrick@0
    38
  </define>
patrick@0
    39
  <define name="document.attributes">
patrick@0
    40
    <ref name="document.id.attribute"/>
patrick@0
    41
  </define>
patrick@0
    42
  <define name="document.id.attribute">
patrick@0
    43
    <attribute name="xml:id">
patrick@0
    44
      <data type="ID"/>
patrick@0
    45
    </attribute>
patrick@0
    46
  </define>
patrick@0
    47
  <define name="document.content">
patrick@0
    48
    <optional>
patrick@20
    49
      <ref name="top.head"/>
patrick@0
    50
    </optional>
patrick@0
    51
    <choice>
patrick@0
    52
      <oneOrMore>
patrick@0
    53
        <ref name="division"/>
patrick@0
    54
      </oneOrMore>
patrick@0
    55
      <oneOrMore>
patrick@0
    56
        <ref name="topic"/>
patrick@0
    57
      </oneOrMore>
patrick@0
    58
    </choice>
patrick@0
    59
  </define>
patrick@0
    60
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ topic ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
    61
  <define name="top.topic">
patrick@0
    62
    <element name="topic">
patrick@0
    63
      <ref name="top.topic.attributes"/>
patrick@20
    64
      <ref name="top.topic.content"/>
patrick@0
    65
    </element>
patrick@0
    66
  </define>
patrick@20
    67
  <define name="top.topic.attributes">
patrick@20
    68
    <interleave>
patrick@20
    69
      <ref name="topic.id.attribute"/>
patrick@20
    70
      <optional>
patrick@20
    71
        <ref name="topic.type.attribute"/>
patrick@20
    72
      </optional>
patrick@20
    73
    </interleave>
patrick@20
    74
  </define>
patrick@20
    75
  <define name="topic.id.attribute">
patrick@20
    76
    <attribute name="xml:id">
patrick@20
    77
      <data type="ID"/>
patrick@20
    78
    </attribute>
patrick@20
    79
  </define>
patrick@20
    80
  <define name="topic.type.attribute">
patrick@20
    81
    <attribute name="type">
patrick@20
    82
      <data type="NCName"/>
patrick@20
    83
    </attribute>
patrick@20
    84
  </define>
patrick@20
    85
  <define name="top.topic.content">
patrick@20
    86
    <optional>
patrick@20
    87
      <ref name="top.head"/>
patrick@20
    88
    </optional>
patrick@20
    89
    <oneOrMore>
patrick@20
    90
      <ref name="section"/>
patrick@20
    91
    </oneOrMore>
patrick@20
    92
  </define>
patrick@0
    93
  <!--
patrick@0
    94
    =============================================================================
patrick@20
    95
                                    HEAD LEVEL
patrick@0
    96
    =============================================================================
patrick@0
    97
  -->
patrick@20
    98
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ head ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@20
    99
  <define name="top.head">
patrick@20
   100
    <element name="head">
patrick@20
   101
      <ref name="top.head.content"/>
patrick@0
   102
    </element>
patrick@0
   103
  </define>
patrick@20
   104
  <define name="division.head">
patrick@20
   105
    <element name="head">
patrick@20
   106
      <ref name="division.head.content"/>
patrick@20
   107
    </element>
patrick@20
   108
  </define>
patrick@20
   109
  <define name="component.head">
patrick@20
   110
    <element name="head">
patrick@20
   111
      <ref name="component.head.content"/>
patrick@20
   112
    </element>
patrick@20
   113
  </define>
patrick@20
   114
  <define name="section.head">
patrick@20
   115
    <element name="head">
patrick@20
   116
      <ref name="section.head.content"/>
patrick@20
   117
    </element>
patrick@20
   118
  </define>
patrick@20
   119
  <define name="block.head">
patrick@20
   120
    <element name="head">
patrick@20
   121
      <ref name="block.head.content"/>
patrick@20
   122
    </element>
patrick@20
   123
  </define>
patrick@20
   124
  <define name="top.head.content">
patrick@0
   125
    <interleave>
patrick@0
   126
      <optional>
patrick@20
   127
        <ref name="title"/>
patrick@20
   128
        <optional>
patrick@20
   129
          <ref name="subtitle"/>
patrick@20
   130
        </optional>
patrick@20
   131
      </optional>
patrick@34
   132
      <zeroOrMore>
patrick@34
   133
        <ref name="identifier"/>
patrick@34
   134
      </zeroOrMore>
patrick@20
   135
      <optional>
patrick@20
   136
        <ref name="language"/>
patrick@0
   137
      </optional>
patrick@39
   138
      <optional>
patrick@39
   139
        <ref name="copyright"/>
patrick@39
   140
      </optional>
patrick@0
   141
      <zeroOrMore>
patrick@0
   142
        <ref name="author"/>
patrick@0
   143
      </zeroOrMore>
patrick@0
   144
      <optional>
patrick@0
   145
        <ref name="publisher"/>
patrick@0
   146
      </optional>
patrick@0
   147
      <optional>
patrick@0
   148
        <ref name="date"/>
patrick@0
   149
      </optional>
patrick@0
   150
      <optional>
patrick@0
   151
        <ref name="place"/>
patrick@0
   152
      </optional>
patrick@0
   153
      <zeroOrMore>
patrick@0
   154
        <ref name="source"/>
patrick@0
   155
      </zeroOrMore>
patrick@0
   156
      <optional>
patrick@40
   157
        <ref name="keywordset"/>
patrick@40
   158
      </optional>
patrick@40
   159
      <optional>
patrick@0
   160
        <ref name="subjectset"/>
patrick@0
   161
      </optional>
patrick@0
   162
      <optional>
patrick@0
   163
        <ref name="abstract"/>
patrick@0
   164
      </optional>
patrick@35
   165
      <optional>
patrick@35
   166
        <ref name="cover"/>
patrick@35
   167
      </optional>
patrick@0
   168
      <zeroOrMore>
patrick@0
   169
        <ref name="annotation"/>
patrick@0
   170
      </zeroOrMore>
patrick@0
   171
    </interleave>
patrick@0
   172
  </define>
patrick@20
   173
  <define name="division.head.content">
patrick@20
   174
    <interleave>
patrick@20
   175
      <optional>
patrick@20
   176
        <ref name="title"/>
patrick@20
   177
        <optional>
patrick@20
   178
          <ref name="subtitle"/>
patrick@20
   179
        </optional>
patrick@20
   180
      </optional>
patrick@20
   181
      <optional>
patrick@20
   182
        <ref name="language"/>
patrick@20
   183
      </optional>
patrick@20
   184
      <zeroOrMore>
patrick@20
   185
        <ref name="annotation"/>
patrick@20
   186
      </zeroOrMore>
patrick@20
   187
    </interleave>
patrick@20
   188
  </define>
patrick@20
   189
  <define name="component.head.content">
patrick@20
   190
    <interleave>
patrick@20
   191
      <optional>
patrick@20
   192
        <ref name="title"/>
patrick@20
   193
        <optional>
patrick@20
   194
          <ref name="subtitle"/>
patrick@20
   195
        </optional>
patrick@20
   196
      </optional>
patrick@20
   197
      <optional>
patrick@20
   198
        <ref name="language"/>
patrick@20
   199
      </optional>
patrick@20
   200
      <zeroOrMore>
patrick@20
   201
        <ref name="author"/>
patrick@20
   202
      </zeroOrMore>
patrick@41
   203
      <optional>
patrick@41
   204
        <ref name="abstract"/>
patrick@41
   205
      </optional>
patrick@20
   206
      <zeroOrMore>
patrick@20
   207
        <ref name="annotation"/>
patrick@20
   208
      </zeroOrMore>
patrick@20
   209
    </interleave>
patrick@20
   210
  </define>
patrick@20
   211
  <define name="section.head.content">
patrick@20
   212
    <interleave>
patrick@20
   213
      <optional>
patrick@20
   214
        <ref name="title"/>
patrick@20
   215
        <optional>
patrick@20
   216
          <ref name="subtitle"/>
patrick@20
   217
        </optional>
patrick@20
   218
      </optional>
patrick@20
   219
      <optional>
patrick@20
   220
        <ref name="language"/>
patrick@20
   221
      </optional>
patrick@41
   222
      <optional>
patrick@41
   223
        <ref name="abstract"/>
patrick@41
   224
      </optional>
patrick@20
   225
      <zeroOrMore>
patrick@20
   226
        <ref name="annotation"/>
patrick@20
   227
      </zeroOrMore>
patrick@20
   228
    </interleave>
patrick@20
   229
  </define>
patrick@20
   230
  <define name="block.head.content">
patrick@20
   231
    <optional>
patrick@20
   232
      <ref name="title"/>
patrick@20
   233
      <optional>
patrick@20
   234
        <ref name="subtitle"/>
patrick@20
   235
      </optional>
patrick@20
   236
    </optional>
patrick@20
   237
  </define>
patrick@0
   238
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ title, subtitle ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
   239
  <define name="title">
patrick@0
   240
    <element name="title">
patrick@0
   241
      <ref name="title.content"/>
patrick@0
   242
    </element>
patrick@0
   243
  </define>
patrick@0
   244
  <define name="subtitle">
patrick@0
   245
    <element name="subtitle">
patrick@0
   246
      <ref name="title.content"/>
patrick@0
   247
    </element>
patrick@0
   248
  </define>
patrick@20
   249
  <define name="title.content">
patrick@20
   250
    <ref name="inlines"/>
patrick@20
   251
  </define>
patrick@34
   252
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ identifier ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@38
   253
  <define name="identifier.uri">
patrick@34
   254
    <element name="identifier">
patrick@38
   255
      <attribute name="type">
patrick@38
   256
        <value>uri</value>
patrick@38
   257
      </attribute>
patrick@38
   258
      <data type="anyURI"/>
patrick@34
   259
    </element>
patrick@34
   260
  </define>
patrick@38
   261
  <define name="identifier.ean">
patrick@38
   262
    <element name="identifier">
patrick@38
   263
      <attribute name="type">
patrick@38
   264
        <value>ean</value>
patrick@38
   265
      </attribute>
patrick@38
   266
      <data type="token">
patrick@38
   267
        <param name="pattern">\d{13}</param>
patrick@38
   268
      </data>
patrick@38
   269
    </element>
patrick@34
   270
  </define>
patrick@38
   271
  <define name="identifier">
patrick@34
   272
    <choice>
patrick@38
   273
      <ref name="identifier.uri"/>
patrick@38
   274
      <ref name="identifier.ean"/>
patrick@34
   275
    </choice>
patrick@34
   276
  </define>
patrick@20
   277
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ language ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@20
   278
  <define name="language">
patrick@20
   279
    <element name="language">
patrick@20
   280
      <ref name="language.attributes"/>
patrick@20
   281
    </element>
patrick@20
   282
  </define>
patrick@20
   283
  <define name="language.attributes">
patrick@20
   284
    <ref name="lang.attribute"/>
patrick@20
   285
  </define>
patrick@20
   286
  <define name="lang.attribute">
patrick@20
   287
    <attribute name="xml:lang">
patrick@20
   288
      <data type="language"/>
patrick@20
   289
    </attribute>
patrick@20
   290
  </define>
patrick@39
   291
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ copyright ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@39
   292
  <define name="copyright">
patrick@39
   293
    <element name="copyright">
patrick@39
   294
      <ref name="copyright.content"/>
patrick@39
   295
    </element>
patrick@39
   296
  </define>
patrick@39
   297
  <define name="copyright.content">
patrick@39
   298
    <ref name="inlines"/>
patrick@39
   299
  </define>
patrick@0
   300
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ author, publisher ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@5
   301
  <!-- ~~~~~~ author -->
patrick@0
   302
  <define name="author">
patrick@0
   303
    <element name="author">
patrick@0
   304
      <ref name="author.content"/>
patrick@0
   305
    </element>
patrick@0
   306
  </define>
patrick@0
   307
  <define name="author.content">
patrick@0
   308
    <optional>
patrick@0
   309
      <ref name="firstname"/>
patrick@0
   310
    </optional>
patrick@0
   311
    <ref name="lastname"/>
patrick@33
   312
    <zeroOrMore>
patrick@33
   313
      <ref name="role"/>
patrick@33
   314
    </zeroOrMore>
patrick@33
   315
  </define>
patrick@5
   316
  <!-- ~~~~~~ publisher -->
patrick@0
   317
  <define name="publisher">
patrick@0
   318
    <element name="publisher">
patrick@0
   319
      <ref name="publisher.content"/>
patrick@0
   320
    </element>
patrick@0
   321
  </define>
patrick@0
   322
  <define name="publisher.content">
patrick@34
   323
    <ref name="label"/>
patrick@34
   324
    <optional>
patrick@36
   325
      <ref name="link"/>
patrick@34
   326
    </optional>
patrick@0
   327
  </define>
patrick@5
   328
  <!-- ~~~~~~ firstname -->
patrick@5
   329
  <define name="firstname">
patrick@5
   330
    <element name="firstname">
patrick@5
   331
      <ref name="firstname.content"/>
patrick@5
   332
    </element>
patrick@5
   333
  </define>
patrick@5
   334
  <define name="firstname.content">
patrick@5
   335
    <ref name="inlines"/>
patrick@5
   336
  </define>
patrick@5
   337
  <!-- ~~~~~~ lastname -->
patrick@5
   338
  <define name="lastname">
patrick@5
   339
    <element name="lastname">
patrick@5
   340
      <ref name="lastname.content"/>
patrick@5
   341
    </element>
patrick@5
   342
  </define>
patrick@5
   343
  <define name="lastname.content">
patrick@5
   344
    <ref name="inlines"/>
patrick@5
   345
  </define>
patrick@34
   346
  <!-- ~~~~~~ role -->
patrick@34
   347
  <define name="role">
patrick@34
   348
    <element name="role">
patrick@34
   349
      <ref name="role.attributes"/>
patrick@34
   350
    </element>
patrick@34
   351
  </define>
patrick@34
   352
  <define name="role.attributes">
patrick@34
   353
    <ref name="role.of.attribute"/>
patrick@34
   354
  </define>
patrick@34
   355
  <define name="role.of.attribute">
patrick@34
   356
    <attribute name="of">
patrick@34
   357
      <choice>
patrick@34
   358
        <value>author</value>
patrick@34
   359
        <value>illustrator</value>
patrick@34
   360
      </choice>
patrick@34
   361
    </attribute>
patrick@34
   362
  </define>
patrick@38
   363
  <!-- ~~~~~~ label -->
patrick@38
   364
  <define name="label">
patrick@38
   365
    <element name="label">
patrick@38
   366
      <ref name="label.content"/>
patrick@38
   367
    </element>
patrick@38
   368
  </define>
patrick@38
   369
  <define name="label.content">
patrick@38
   370
    <ref name="inlines"/>
patrick@38
   371
  </define>
patrick@2
   372
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ place ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@2
   373
  <define name="place">
patrick@2
   374
    <element name="place">
patrick@2
   375
      <ref name="place.content"/>
patrick@2
   376
    </element>
patrick@2
   377
  </define>
patrick@2
   378
  <define name="place.content">
patrick@2
   379
    <ref name="inlines"/>
patrick@2
   380
  </define>
patrick@0
   381
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ source ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@2
   382
  <!-- ~~~~~~ source -->
patrick@0
   383
  <define name="source">
patrick@0
   384
    <element name="source">
patrick@0
   385
      <choice>
patrick@0
   386
        <group>
patrick@0
   387
          <attribute name="type">
patrick@0
   388
            <value>book</value>
patrick@0
   389
          </attribute>
patrick@0
   390
          <ref name="source.content.book"/>
patrick@0
   391
        </group>
patrick@38
   392
        <group>
patrick@38
   393
          <attribute name="type">
patrick@38
   394
            <value>file</value>
patrick@38
   395
          </attribute>
patrick@38
   396
          <ref name="source.content.file"/>
patrick@38
   397
        </group>
patrick@0
   398
      </choice>
patrick@0
   399
      <ref name="source.content"/>
patrick@0
   400
    </element>
patrick@0
   401
  </define>
patrick@0
   402
  <define name="source.content.book">
patrick@38
   403
    <ref name="identifier.ean"/>
patrick@38
   404
    <optional>
patrick@38
   405
      <ref name="title"/>
patrick@38
   406
    </optional>
patrick@0
   407
    <zeroOrMore>
patrick@0
   408
      <ref name="pagenumber"/>
patrick@0
   409
    </zeroOrMore>
patrick@0
   410
  </define>
patrick@38
   411
  <define name="source.content.file">
patrick@38
   412
    <ref name="identifier.uri"/>
patrick@38
   413
  </define>
patrick@0
   414
  <define name="source.content">
patrick@0
   415
    <zeroOrMore>
patrick@0
   416
      <ref name="annotation"/>
patrick@0
   417
    </zeroOrMore>
patrick@0
   418
  </define>
patrick@2
   419
  <!-- ~~~~~~ pagenumber -->
patrick@0
   420
  <define name="pagenumber">
patrick@0
   421
    <element name="pagenumber">
patrick@0
   422
      <ref name="pagenumber.attributes"/>
patrick@0
   423
    </element>
patrick@0
   424
  </define>
patrick@0
   425
  <define name="pagenumber.attributes">
patrick@0
   426
    <ref name="pagenumber.value.attribute"/>
patrick@0
   427
  </define>
patrick@0
   428
  <define name="pagenumber.value.attribute">
patrick@0
   429
    <attribute name="value">
patrick@33
   430
      <data type="positiveInteger"/>
patrick@0
   431
    </attribute>
patrick@0
   432
  </define>
patrick@40
   433
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ keyword & subject ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@40
   434
  <!-- ~~~~~~ keywordset -->
patrick@40
   435
  <define name="keywordset">
patrick@40
   436
    <element name="keywordset">
patrick@40
   437
      <ref name="keywordset.content"/>
patrick@40
   438
    </element>
patrick@40
   439
  </define>
patrick@40
   440
  <define name="keywordset.content">
patrick@40
   441
    <oneOrMore>
patrick@40
   442
      <ref name="keyword"/>
patrick@40
   443
    </oneOrMore>
patrick@40
   444
  </define>
patrick@40
   445
  <!-- ~~~~~~ keyword -->
patrick@40
   446
  <define name="keyword">
patrick@40
   447
    <element name="keyword">
patrick@40
   448
      <ref name="keyword.content"/>
patrick@40
   449
    </element>
patrick@40
   450
  </define>
patrick@40
   451
  <define name="keyword.content">
patrick@53
   452
    <mixed>
patrick@53
   453
      <zeroOrMore>
patrick@53
   454
        <ref name="sup"/>
patrick@53
   455
      </zeroOrMore>
patrick@53
   456
      <zeroOrMore>
patrick@53
   457
        <ref name="sub"/>
patrick@53
   458
      </zeroOrMore>
patrick@53
   459
    </mixed>
patrick@40
   460
  </define>
patrick@2
   461
  <!-- ~~~~~~ subjectset -->
patrick@0
   462
  <define name="subjectset">
patrick@0
   463
    <element name="subjectset">
patrick@0
   464
      <ref name="subjectset.content"/>
patrick@0
   465
    </element>
patrick@0
   466
  </define>
patrick@0
   467
  <define name="subjectset.content">
patrick@0
   468
    <oneOrMore>
patrick@0
   469
      <ref name="subject"/>
patrick@0
   470
    </oneOrMore>
patrick@0
   471
  </define>
patrick@2
   472
  <!-- ~~~~~~ subject -->
patrick@0
   473
  <define name="subject">
patrick@0
   474
    <element name="subject">
patrick@0
   475
      <ref name="subject.attributes"/>
patrick@0
   476
    </element>
patrick@0
   477
  </define>
patrick@0
   478
  <define name="subject.attributes">
patrick@0
   479
    <ref name="subject.id.attribute"/>
patrick@0
   480
  </define>
patrick@0
   481
  <define name="subject.id.attribute">
patrick@0
   482
    <attribute name="id">
patrick@0
   483
      <data type="NMTOKEN"/>
patrick@0
   484
    </attribute>
patrick@0
   485
  </define>
patrick@5
   486
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ abstract ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@2
   487
  <define name="abstract">
patrick@2
   488
    <element name="abstract">
patrick@2
   489
      <ref name="abstract.content"/>
patrick@2
   490
    </element>
patrick@2
   491
  </define>
patrick@2
   492
  <define name="abstract.content">
patrick@2
   493
    <oneOrMore>
patrick@20
   494
      <ref name="p"/>
patrick@2
   495
    </oneOrMore>
patrick@2
   496
  </define>
patrick@35
   497
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ cover ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@35
   498
  <define name="cover">
patrick@35
   499
    <element name="cover">
patrick@35
   500
      <ref name="cover.content"/>
patrick@35
   501
    </element>
patrick@35
   502
  </define>
patrick@35
   503
  <define name="cover.content">
patrick@35
   504
    <ref name="cover.image"/>
patrick@35
   505
  </define>
patrick@35
   506
  <define name="cover.image">
patrick@35
   507
    <element name="image">
patrick@35
   508
      <ref name="cover.image.attributes"/>
patrick@35
   509
    </element>
patrick@35
   510
  </define>
patrick@35
   511
  <define name="cover.image.attributes">
patrick@35
   512
    <ref name="cover.image.id.attribute"/>
patrick@35
   513
  </define>
patrick@35
   514
  <define name="cover.image.id.attribute">
patrick@35
   515
    <attribute name="id">
patrick@35
   516
      <data type="NMTOKEN"/>
patrick@35
   517
    </attribute>
patrick@35
   518
  </define>
patrick@0
   519
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ annotation ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
   520
  <define name="annotation">
patrick@0
   521
    <element name="annotation">
patrick@0
   522
      <ref name="annotation.content"/>
patrick@0
   523
    </element>
patrick@0
   524
  </define>
patrick@0
   525
  <define name="annotation.content">
patrick@0
   526
    <ref name="inlines"/>
patrick@0
   527
  </define>
patrick@0
   528
  <!--
patrick@0
   529
    =============================================================================
patrick@20
   530
                                    DIVISION LEVEL
patrick@0
   531
    =============================================================================
patrick@0
   532
  -->
patrick@0
   533
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ division ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
   534
  <define name="division">
patrick@0
   535
    <element name="division">
patrick@0
   536
      <ref name="division.content"/>
patrick@0
   537
    </element>
patrick@0
   538
  </define>
patrick@0
   539
  <define name="division.content">
patrick@0
   540
    <optional>
patrick@20
   541
      <ref name="division.head"/>
patrick@0
   542
    </optional>
patrick@0
   543
    <choice>
patrick@0
   544
      <oneOrMore>
patrick@0
   545
        <ref name="division"/>
patrick@0
   546
      </oneOrMore>
patrick@0
   547
      <oneOrMore>
patrick@0
   548
        <ref name="topic"/>
patrick@0
   549
      </oneOrMore>
patrick@0
   550
    </choice>
patrick@0
   551
  </define>
patrick@0
   552
  <!--
patrick@0
   553
    =============================================================================
patrick@20
   554
                                  COMPONENT LEVEL
patrick@0
   555
    =============================================================================
patrick@0
   556
  -->
patrick@0
   557
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ topic ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
   558
  <define name="topic">
patrick@0
   559
    <element name="topic">
patrick@0
   560
      <ref name="topic.attributes"/>
patrick@0
   561
      <ref name="topic.content"/>
patrick@0
   562
    </element>
patrick@0
   563
  </define>
patrick@0
   564
  <define name="topic.attributes">
patrick@0
   565
    <interleave>
patrick@0
   566
      <optional>
patrick@0
   567
        <ref name="topic.id.attribute"/>
patrick@0
   568
      </optional>
patrick@0
   569
      <optional>
patrick@0
   570
        <ref name="topic.type.attribute"/>
patrick@0
   571
      </optional>
patrick@0
   572
    </interleave>
patrick@0
   573
  </define>
patrick@0
   574
  <define name="topic.content">
patrick@0
   575
    <optional>
patrick@20
   576
      <ref name="component.head"/>
patrick@0
   577
    </optional>
patrick@0
   578
    <oneOrMore>
patrick@0
   579
      <ref name="section"/>
patrick@0
   580
    </oneOrMore>
patrick@0
   581
  </define>
patrick@0
   582
  <!--
patrick@0
   583
    =============================================================================
patrick@20
   584
                                    SECTION LEVEL
patrick@0
   585
    =============================================================================
patrick@0
   586
  -->
patrick@20
   587
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ section ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
   588
  <define name="section">
patrick@0
   589
    <element name="section">
patrick@0
   590
      <ref name="section.content"/>
patrick@0
   591
      <ref name="section.attributes"/>
patrick@0
   592
    </element>
patrick@0
   593
  </define>
patrick@0
   594
  <define name="section.content">
patrick@0
   595
    <optional>
patrick@20
   596
      <ref name="section.head"/>
patrick@0
   597
    </optional>
patrick@0
   598
    <choice>
patrick@0
   599
      <oneOrMore>
patrick@0
   600
        <ref name="section"/>
patrick@0
   601
      </oneOrMore>
patrick@0
   602
      <oneOrMore>
patrick@10
   603
        <ref name="block"/>
patrick@0
   604
      </oneOrMore>
patrick@0
   605
    </choice>
patrick@0
   606
  </define>
patrick@0
   607
  <define name="section.attributes">
patrick@0
   608
    <optional>
patrick@37
   609
      <ref name="section.type.attribute"/>
patrick@0
   610
    </optional>
patrick@0
   611
  </define>
patrick@37
   612
  <define name="section.type.attribute">
patrick@37
   613
    <attribute name="type">
patrick@0
   614
      <data type="NCName"/>
patrick@0
   615
    </attribute>
patrick@0
   616
  </define>
patrick@0
   617
  <!--
patrick@0
   618
    =============================================================================
patrick@20
   619
                                    BLOCK LEVEL
patrick@0
   620
    =============================================================================
patrick@0
   621
  -->
patrick@20
   622
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ block ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@10
   623
  <define name="block">
patrick@10
   624
    <choice>
patrick@20
   625
      <ref name="p"/>
patrick@20
   626
      <ref name="speech"/>
patrick@10
   627
      <ref name="list"/>
patrick@44
   628
      <ref name="blockquote"/>
patrick@17
   629
      <ref name="table"/>
patrick@10
   630
      <ref name="media"/>
patrick@10
   631
    </choice>
patrick@10
   632
  </define>
patrick@42
   633
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ p ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@20
   634
  <define name="p">
patrick@20
   635
    <element name="p">
patrick@20
   636
      <ref name="p.content"/>
patrick@0
   637
    </element>
patrick@0
   638
  </define>
patrick@20
   639
  <define name="p.content">
patrick@25
   640
    <ref name="inlines"/>
patrick@0
   641
  </define>
patrick@20
   642
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ speech ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@20
   643
  <!-- ~~~~~~ speech -->
patrick@20
   644
  <define name="speech">
patrick@20
   645
    <element name="speech">
patrick@20
   646
      <ref name="speech.content"/>
patrick@20
   647
    </element>
patrick@20
   648
  </define>
patrick@20
   649
  <define name="speech.content">
patrick@20
   650
    <optional>
patrick@20
   651
      <ref name="speaker"/>
patrick@20
   652
    </optional>
patrick@20
   653
    <optional>
patrick@20
   654
      <ref name="stage"/>
patrick@20
   655
    </optional>
patrick@20
   656
    <oneOrMore>
patrick@20
   657
      <ref name="p"/>
patrick@20
   658
    </oneOrMore>
patrick@20
   659
  </define>
patrick@20
   660
  <!-- ~~~~~~ speaker -->
patrick@20
   661
  <define name="speaker">
patrick@20
   662
    <element name="speaker">
patrick@20
   663
      <ref name="speaker.content"/>
patrick@20
   664
    </element>
patrick@20
   665
  </define>
patrick@20
   666
  <define name="speaker.content">
patrick@20
   667
    <ref name="inlines"/>
patrick@20
   668
  </define>
patrick@20
   669
  <!-- ~~~~~~ stage -->
patrick@20
   670
  <define name="stage">
patrick@20
   671
    <element name="stage">
patrick@20
   672
      <ref name="stage.content"/>
patrick@20
   673
    </element>
patrick@20
   674
  </define>
patrick@20
   675
  <define name="stage.content">
patrick@20
   676
    <ref name="inlines"/>
patrick@20
   677
  </define>
patrick@17
   678
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ list ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@10
   679
  <!-- ~~~~~~ list -->
patrick@10
   680
  <define name="list">
patrick@10
   681
    <element name="list">
patrick@10
   682
      <ref name="list.content"/>
patrick@10
   683
    </element>
patrick@10
   684
  </define>
patrick@10
   685
  <define name="list.content">
patrick@10
   686
    <optional>
patrick@20
   687
      <ref name="block.head"/>
patrick@10
   688
    </optional>
patrick@10
   689
    <choice>
patrick@10
   690
      <group>
patrick@10
   691
        <optional>
patrick@10
   692
          <attribute name="type">
patrick@12
   693
            <value>ordered</value>
patrick@10
   694
          </attribute>
patrick@10
   695
        </optional>
patrick@10
   696
        <ref name="item"/>
patrick@10
   697
        <oneOrMore>
patrick@10
   698
          <ref name="item"/>
patrick@10
   699
        </oneOrMore>
patrick@10
   700
      </group>
patrick@10
   701
      <group>
patrick@10
   702
        <attribute name="type">
patrick@10
   703
          <value>glossary</value>
patrick@10
   704
        </attribute>
patrick@10
   705
        <oneOrMore>
patrick@10
   706
          <ref name="glossary.item"/>
patrick@10
   707
        </oneOrMore>
patrick@10
   708
      </group>
patrick@10
   709
    </choice>
patrick@10
   710
  </define>
patrick@10
   711
  <!-- ~~~~~~ item -->
patrick@10
   712
  <define name="item">
patrick@10
   713
    <element name="item">
patrick@10
   714
      <ref name="item.content"/>
patrick@10
   715
    </element>
patrick@10
   716
  </define>
patrick@10
   717
  <define name="item.content">
patrick@30
   718
    <choice>
patrick@30
   719
      <ref name="inlines"/>
patrick@30
   720
      <oneOrMore>
patrick@30
   721
        <ref name="block"/>
patrick@30
   722
      </oneOrMore>
patrick@30
   723
    </choice>
patrick@10
   724
  </define>
patrick@10
   725
  <!-- ~~~~~~ glossary.item -->
patrick@10
   726
  <define name="glossary.item">
patrick@10
   727
    <element name="item">
patrick@10
   728
      <ref name="glossary.item.content"/>
patrick@10
   729
    </element>
patrick@10
   730
  </define>
patrick@10
   731
  <define name="glossary.item.content">
patrick@10
   732
    <ref name="label"/>
patrick@10
   733
    <oneOrMore>
patrick@10
   734
      <ref name="block"/>
patrick@10
   735
    </oneOrMore>
patrick@10
   736
  </define>
patrick@44
   737
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ blockquote ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@44
   738
  <!-- ~~~~~~ blockquote -->
patrick@44
   739
  <define name="blockquote">
patrick@44
   740
    <element name="blockquote">
patrick@44
   741
      <ref name="blockquote.content"/>
patrick@44
   742
    </element>
patrick@44
   743
  </define>
patrick@44
   744
  <define name="blockquote.content">
patrick@44
   745
    <optional>
patrick@44
   746
      <ref name="block.head"/>
patrick@44
   747
    </optional>
patrick@44
   748
    <oneOrMore>
patrick@44
   749
      <choice>
patrick@44
   750
        <ref name="p"/>
patrick@44
   751
        <ref name="speech"/>
patrick@44
   752
        <ref name="list"/>
patrick@44
   753
      </choice>
patrick@44
   754
    </oneOrMore>
patrick@44
   755
    <optional>
patrick@44
   756
      <ref name="attribution"/>
patrick@44
   757
    </optional>
patrick@44
   758
  </define>
patrick@44
   759
  <!-- ~~~~~~ attribution -->
patrick@44
   760
  <define name="attribution">
patrick@44
   761
    <element name="attribution">
patrick@44
   762
      <ref name="attribtuion.content"/>
patrick@44
   763
    </element>
patrick@44
   764
  </define>
patrick@44
   765
  <define name="attribtuion.content">
patrick@44
   766
    <ref name="inlines"/>
patrick@44
   767
  </define>
patrick@17
   768
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ table ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@17
   769
  <define name="table">
patrick@17
   770
    <element name="table">
patrick@17
   771
      <ref name="table.content"/>
patrick@17
   772
    </element>
patrick@17
   773
  </define>
patrick@17
   774
  <define name="table.content">
patrick@17
   775
    <optional>
patrick@20
   776
      <ref name="block.head"/>
patrick@17
   777
    </optional>
patrick@17
   778
    <oneOrMore>
patrick@17
   779
      <ref name="tgroup"/>
patrick@17
   780
    </oneOrMore>
patrick@17
   781
    <optional>
patrick@17
   782
      <ref name="caption"/>
patrick@17
   783
    </optional>
patrick@17
   784
  </define>
patrick@17
   785
  <!-- ~~~~~~ tgroup -->
patrick@17
   786
  <define name="tgroup">
patrick@17
   787
    <element name="tgroup">
patrick@17
   788
      <ref name="tgroup.attributes"/>
patrick@17
   789
      <ref name="tgroup.content"/>
patrick@17
   790
    </element>
patrick@17
   791
  </define>
patrick@17
   792
  <define name="tgroup.content">
patrick@17
   793
    <optional>
patrick@17
   794
      <ref name="thead"/>
patrick@17
   795
    </optional>
patrick@17
   796
    <optional>
patrick@17
   797
      <ref name="tfoot"/>
patrick@17
   798
    </optional>
patrick@17
   799
    <ref name="tbody"/>
patrick@17
   800
  </define>
patrick@17
   801
  <define name="tgroup.attributes">
patrick@17
   802
    <interleave>
patrick@17
   803
      <ref name="cols.attribute"/>
patrick@17
   804
      <optional>
patrick@17
   805
        <ref name="align.attribute"/>
patrick@17
   806
      </optional>
patrick@17
   807
      <optional>
patrick@17
   808
        <ref name="colsep.attribute"/>
patrick@17
   809
      </optional>
patrick@17
   810
      <optional>
patrick@17
   811
        <ref name="rowsep.attribute"/>
patrick@17
   812
      </optional>
patrick@17
   813
    </interleave>
patrick@17
   814
  </define>
patrick@17
   815
  <define name="cols.attribute">
patrick@17
   816
    <attribute name="cols">
patrick@17
   817
      <data type="positiveInteger"/>
patrick@17
   818
    </attribute>
patrick@17
   819
  </define>
patrick@17
   820
  <define name="align.attribute">
patrick@17
   821
    <attribute name="align">
patrick@17
   822
      <choice>
patrick@17
   823
        <value>left</value>
patrick@17
   824
        <value>right</value>
patrick@17
   825
        <value>center</value>
patrick@17
   826
        <value>justify</value>
patrick@17
   827
      </choice>
patrick@17
   828
    </attribute>
patrick@17
   829
  </define>
patrick@17
   830
  <define name="colsep.attribute">
patrick@17
   831
    <attribute name="colsep">
patrick@17
   832
      <choice>
patrick@17
   833
        <value>0</value>
patrick@17
   834
        <value>1</value>
patrick@17
   835
      </choice>
patrick@17
   836
    </attribute>
patrick@17
   837
  </define>
patrick@17
   838
  <define name="rowsep.attribute">
patrick@17
   839
    <attribute name="rowsep">
patrick@17
   840
      <choice>
patrick@17
   841
        <value>0</value>
patrick@17
   842
        <value>1</value>
patrick@17
   843
      </choice>
patrick@17
   844
    </attribute>
patrick@17
   845
  </define>
patrick@17
   846
  <!-- ~~~~~~ thead, tfoot, tbody -->
patrick@17
   847
  <define name="thead">
patrick@17
   848
    <element name="thead">
patrick@22
   849
      <ref name="thead.attributes"/>
patrick@17
   850
      <ref name="thead.content"/>
patrick@17
   851
    </element>
patrick@17
   852
  </define>
patrick@17
   853
  <define name="tfoot">
patrick@17
   854
    <element name="tfoot">
patrick@22
   855
      <ref name="tfoot.attributes"/>
patrick@17
   856
      <ref name="tfoot.content"/>
patrick@17
   857
    </element>
patrick@17
   858
  </define>
patrick@17
   859
  <define name="tbody">
patrick@17
   860
    <element name="tbody">
patrick@22
   861
      <ref name="tbody.attributes"/>
patrick@17
   862
      <ref name="tbody.content"/>
patrick@17
   863
    </element>
patrick@17
   864
  </define>
patrick@22
   865
  <define name="thead.attributes">
patrick@22
   866
    <optional>
patrick@22
   867
      <ref name="valign.attribute"/>
patrick@22
   868
    </optional>
patrick@22
   869
  </define>
patrick@22
   870
  <define name="tfoot.attributes">
patrick@22
   871
    <optional>
patrick@22
   872
      <ref name="valign.attribute"/>
patrick@22
   873
    </optional>
patrick@22
   874
  </define>
patrick@22
   875
  <define name="tbody.attributes">
patrick@22
   876
    <optional>
patrick@22
   877
      <ref name="valign.attribute"/>
patrick@22
   878
    </optional>
patrick@22
   879
  </define>
patrick@22
   880
  <define name="valign.attribute">
patrick@22
   881
    <attribute name="valign">
patrick@22
   882
      <choice>
patrick@22
   883
        <value>top</value>
patrick@22
   884
        <value>middle</value>
patrick@22
   885
        <value>bottom</value>
patrick@22
   886
      </choice>
patrick@22
   887
    </attribute>
patrick@22
   888
  </define>
patrick@17
   889
  <define name="thead.content">
patrick@17
   890
    <oneOrMore>
patrick@17
   891
      <ref name="row"/>
patrick@17
   892
    </oneOrMore>
patrick@17
   893
  </define>
patrick@17
   894
  <define name="tfoot.content">
patrick@17
   895
    <oneOrMore>
patrick@17
   896
      <ref name="row"/>
patrick@17
   897
    </oneOrMore>
patrick@17
   898
  </define>
patrick@17
   899
  <define name="tbody.content">
patrick@17
   900
    <oneOrMore>
patrick@17
   901
      <ref name="row"/>
patrick@17
   902
    </oneOrMore>
patrick@17
   903
  </define>
patrick@17
   904
  <!-- ~~~~~~ row -->
patrick@17
   905
  <define name="row">
patrick@17
   906
    <element name="row">
patrick@17
   907
      <ref name="row.attribute"/>
patrick@17
   908
      <ref name="row.content"/>
patrick@17
   909
    </element>
patrick@17
   910
  </define>
patrick@17
   911
  <define name="row.attribute">
patrick@17
   912
    <optional>
patrick@17
   913
      <ref name="valign.attribute"/>
patrick@17
   914
    </optional>
patrick@17
   915
  </define>
patrick@17
   916
  <define name="row.content">
patrick@17
   917
    <oneOrMore>
patrick@17
   918
      <ref name="entry"/>
patrick@17
   919
    </oneOrMore>
patrick@17
   920
  </define>
patrick@17
   921
  <!-- ~~~~~~ entry -->
patrick@17
   922
  <define name="entry">
patrick@17
   923
    <element name="entry">
patrick@17
   924
      <ref name="entry.content"/>
patrick@17
   925
    </element>
patrick@17
   926
  </define>
patrick@17
   927
  <define name="entry.content">
patrick@17
   928
    <choice>
patrick@17
   929
      <ref name="inlines"/>
patrick@17
   930
      <oneOrMore>
patrick@37
   931
        <choice>
patrick@37
   932
          <ref name="p"/>
patrick@37
   933
          <ref name="media"/>
patrick@37
   934
        </choice>
patrick@17
   935
      </oneOrMore>
patrick@17
   936
    </choice>
patrick@17
   937
  </define>
patrick@17
   938
  <!-- ~~~~~~ caption -->
patrick@17
   939
  <define name="caption">
patrick@17
   940
    <element name="caption">
patrick@17
   941
      <ref name="caption.content"/>
patrick@17
   942
    </element>
patrick@17
   943
  </define>
patrick@17
   944
  <define name="caption.content">
patrick@20
   945
    <choice>
patrick@20
   946
      <ref name="inlines"/>
patrick@20
   947
      <oneOrMore>
patrick@20
   948
        <ref name="p"/>
patrick@20
   949
      </oneOrMore>
patrick@20
   950
    </choice>
patrick@11
   951
  </define>
patrick@35
   952
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ media ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@2
   953
  <!-- ~~~~~~ media -->
patrick@0
   954
  <define name="media">
patrick@0
   955
    <element name="media">
patrick@0
   956
      <ref name="media.content"/>
patrick@0
   957
    </element>
patrick@0
   958
  </define>
patrick@0
   959
  <define name="media.content">
patrick@24
   960
    <optional>
patrick@24
   961
      <ref name="block.head"/>
patrick@24
   962
    </optional>
patrick@0
   963
    <oneOrMore>
patrick@43
   964
      <choice>
patrick@43
   965
        <ref name="image"/>
patrick@45
   966
        <ref name="audio"/>
patrick@43
   967
      </choice>
patrick@0
   968
    </oneOrMore>
patrick@0
   969
    <optional>
patrick@17
   970
      <ref name="caption"/>
patrick@0
   971
    </optional>
patrick@35
   972
    <optional>
patrick@36
   973
      <ref name="link"/>
patrick@35
   974
    </optional>
patrick@0
   975
  </define>
patrick@2
   976
  <!-- ~~~~~~ image -->
patrick@0
   977
  <define name="image">
patrick@0
   978
    <element name="image">
patrick@0
   979
      <ref name="image.attributes"/>
patrick@0
   980
      <ref name="image.content"/>
patrick@0
   981
    </element>
patrick@0
   982
  </define>
patrick@0
   983
  <define name="image.attributes">
patrick@0
   984
    <ref name="media.id.attribute"/>
patrick@49
   985
    <optional>
patrick@49
   986
      <ref name="image.type"/>
patrick@49
   987
    </optional>
patrick@0
   988
  </define>
patrick@17
   989
  <define name="media.id.attribute">
patrick@17
   990
    <attribute name="id">
patrick@17
   991
      <data type="NMTOKEN"/>
patrick@17
   992
    </attribute>
patrick@17
   993
  </define>
patrick@49
   994
  <define name="image.type">
patrick@49
   995
    <attribute name="type">
patrick@50
   996
      <choice>
patrick@50
   997
        <value>cover</value>
patrick@50
   998
        <value>thumbnail</value>
patrick@50
   999
      </choice>
patrick@49
  1000
    </attribute>
patrick@49
  1001
  </define>
patrick@0
  1002
  <define name="image.content">
patrick@0
  1003
    <optional>
patrick@0
  1004
      <ref name="copyright"/>
patrick@0
  1005
    </optional>
patrick@0
  1006
  </define>
patrick@45
  1007
  <!-- ~~~~~~ audio -->
patrick@45
  1008
  <define name="audio">
patrick@45
  1009
    <element name="audio">
patrick@45
  1010
      <ref name="audio.attributes"/>
patrick@43
  1011
    </element>
patrick@43
  1012
  </define>
patrick@45
  1013
  <define name="audio.attributes">
patrick@43
  1014
    <ref name="media.id.attribute"/>
patrick@43
  1015
  </define>
patrick@0
  1016
  <!--
patrick@0
  1017
    =============================================================================
patrick@20
  1018
                                    INLINE LEVEL
patrick@0
  1019
    =============================================================================
patrick@0
  1020
  -->
patrick@0
  1021
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ inlines ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
  1022
  <define name="inlines">
patrick@0
  1023
    <mixed>
patrick@0
  1024
      <interleave>
patrick@0
  1025
        <zeroOrMore>
patrick@0
  1026
          <ref name="sup"/>
patrick@0
  1027
        </zeroOrMore>
patrick@0
  1028
        <zeroOrMore>
patrick@0
  1029
          <ref name="sub"/>
patrick@0
  1030
        </zeroOrMore>
patrick@0
  1031
        <zeroOrMore>
patrick@42
  1032
          <ref name="var"/>
patrick@42
  1033
        </zeroOrMore>
patrick@42
  1034
        <zeroOrMore>
patrick@12
  1035
          <ref name="number"/>
patrick@0
  1036
        </zeroOrMore>
patrick@0
  1037
        <zeroOrMore>
patrick@42
  1038
          <ref name="math"/>
patrick@42
  1039
        </zeroOrMore>
patrick@42
  1040
        <zeroOrMore>
patrick@0
  1041
          <ref name="date"/>
patrick@0
  1042
        </zeroOrMore>
patrick@0
  1043
        <zeroOrMore>
patrick@0
  1044
          <ref name="name"/>
patrick@0
  1045
        </zeroOrMore>
patrick@0
  1046
        <zeroOrMore>
patrick@5
  1047
          <ref name="note"/>
patrick@0
  1048
        </zeroOrMore>
patrick@0
  1049
        <zeroOrMore>
patrick@0
  1050
          <ref name="foreign"/>
patrick@0
  1051
        </zeroOrMore>
patrick@0
  1052
        <zeroOrMore>
patrick@0
  1053
          <ref name="highlight"/>
patrick@0
  1054
        </zeroOrMore>
patrick@5
  1055
        <zeroOrMore>
patrick@5
  1056
          <ref name="mentioned"/>
patrick@5
  1057
        </zeroOrMore>
patrick@5
  1058
        <zeroOrMore>
patrick@5
  1059
          <ref name="quote"/>
patrick@5
  1060
        </zeroOrMore>
patrick@8
  1061
        <zeroOrMore>
patrick@8
  1062
          <ref name="acronym"/>
patrick@8
  1063
        </zeroOrMore>
patrick@10
  1064
        <zeroOrMore>
patrick@10
  1065
          <ref name="term"/>
patrick@10
  1066
        </zeroOrMore>
patrick@25
  1067
        <zeroOrMore>
patrick@25
  1068
          <ref name="link"/>
patrick@25
  1069
        </zeroOrMore>
patrick@42
  1070
        <zeroOrMore>
patrick@42
  1071
          <ref name="anchor"/>
patrick@42
  1072
        </zeroOrMore>
patrick@0
  1073
      </interleave>
patrick@0
  1074
    </mixed>
patrick@0
  1075
  </define>
patrick@42
  1076
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ sub, sup, var ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
  1077
  <define name="sup">
patrick@0
  1078
    <element name="sup">
patrick@42
  1079
      <text/>
patrick@0
  1080
    </element>
patrick@0
  1081
  </define>
patrick@0
  1082
  <define name="sub">
patrick@0
  1083
    <element name="sub">
patrick@42
  1084
      <text/>
patrick@0
  1085
    </element>
patrick@0
  1086
  </define>
patrick@42
  1087
  <define name="var">
patrick@42
  1088
    <element name="var">
patrick@42
  1089
      <text/>
patrick@42
  1090
    </element>
patrick@42
  1091
  </define>
patrick@42
  1092
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ math ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@42
  1093
  <define name="math">
patrick@42
  1094
    <element name="math">
patrick@42
  1095
      <choice>
patrick@42
  1096
        <group>
patrick@42
  1097
          <attribute name="notation">
patrick@42
  1098
            <value>tex</value>
patrick@42
  1099
          </attribute>
patrick@42
  1100
          <ref name="math.attributes"/>
patrick@42
  1101
          <ref name="math.tex.content"/>
patrick@42
  1102
        </group>
patrick@42
  1103
        <group>
patrick@42
  1104
          <ref name="math.attributes"/>
patrick@42
  1105
          <ref name="math.content"/>
patrick@42
  1106
        </group>
patrick@42
  1107
      </choice>
patrick@42
  1108
    </element>
patrick@42
  1109
  </define>
patrick@42
  1110
  <define name="math.attributes">
patrick@42
  1111
    <optional>
patrick@42
  1112
      <ref name="wide.attribute"/>
patrick@42
  1113
    </optional>
patrick@42
  1114
  </define>
patrick@42
  1115
  <define name="wide.attribute">
patrick@42
  1116
    <attribute name="wide">
patrick@42
  1117
      <data type="boolean"/>
patrick@42
  1118
    </attribute>
patrick@42
  1119
  </define>
patrick@42
  1120
  <define name="math.content">
patrick@42
  1121
    <mixed>
patrick@42
  1122
      <interleave>
patrick@42
  1123
        <zeroOrMore>
patrick@42
  1124
          <ref name="sup"/>
patrick@42
  1125
        </zeroOrMore>
patrick@42
  1126
        <zeroOrMore>
patrick@42
  1127
          <ref name="sub"/>
patrick@42
  1128
        </zeroOrMore>
patrick@42
  1129
        <zeroOrMore>
patrick@42
  1130
          <ref name="var"/>
patrick@42
  1131
        </zeroOrMore>
patrick@42
  1132
      </interleave>
patrick@42
  1133
    </mixed>
patrick@42
  1134
  </define>
patrick@42
  1135
  <define name="math.tex.content">
patrick@42
  1136
    <text/>
patrick@42
  1137
  </define>
patrick@12
  1138
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ number ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@12
  1139
  <define name="number">
patrick@12
  1140
    <element name="number">
patrick@12
  1141
      <choice>
patrick@12
  1142
        <group>
patrick@12
  1143
          <attribute name="type">
patrick@12
  1144
            <value>roman</value>
patrick@12
  1145
          </attribute>
patrick@12
  1146
          <ref name="number.attributes"/>
patrick@12
  1147
          <ref name="number.roman.content"/>
patrick@12
  1148
        </group>
patrick@12
  1149
        <group>
patrick@12
  1150
          <ref name="number.attributes"/>
patrick@12
  1151
          <ref name="number.content"/>
patrick@12
  1152
        </group>
patrick@12
  1153
      </choice>
patrick@0
  1154
    </element>
patrick@0
  1155
  </define>
patrick@12
  1156
  <define name="number.attributes">
patrick@12
  1157
    <optional>
patrick@12
  1158
      <ref name="number.value.attribute"/>
patrick@12
  1159
    </optional>
patrick@12
  1160
  </define>
patrick@12
  1161
  <define name="number.value.attribute">
patrick@12
  1162
    <attribute name="value">
patrick@12
  1163
      <choice>
patrick@12
  1164
        <data type="integer"/>
patrick@12
  1165
        <data type="decimal"/>
patrick@12
  1166
      </choice>
patrick@12
  1167
    </attribute>
patrick@12
  1168
  </define>
patrick@12
  1169
  <define name="number.content">
patrick@12
  1170
    <mixed>
patrick@12
  1171
      <zeroOrMore>
patrick@12
  1172
        <ref name="sup"/>
patrick@12
  1173
      </zeroOrMore>
patrick@12
  1174
    </mixed>
patrick@12
  1175
  </define>
patrick@12
  1176
  <define name="number.roman.content">
patrick@12
  1177
    <data type="token">
patrick@12
  1178
      <param name="pattern">[dlxvi]+</param>
patrick@12
  1179
    </data>
patrick@12
  1180
  </define>
patrick@36
  1181
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ date ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
  1182
  <define name="date">
patrick@0
  1183
    <element name="date">
patrick@0
  1184
      <ref name="date.attributes"/>
patrick@0
  1185
      <ref name="date.content"/>
patrick@0
  1186
    </element>
patrick@0
  1187
  </define>
patrick@0
  1188
  <define name="date.attributes">
patrick@12
  1189
    <interleave>
patrick@12
  1190
      <ref name="date.value.attribute"/>
patrick@12
  1191
      <optional>
patrick@12
  1192
        <ref name="date.of.attribute"/>
patrick@12
  1193
      </optional>
patrick@12
  1194
    </interleave>
patrick@12
  1195
  </define>
patrick@12
  1196
  <define name="date.value.attribute">
patrick@12
  1197
    <attribute name="value">
patrick@12
  1198
      <choice>
patrick@12
  1199
        <data type="date"/>
patrick@12
  1200
        <data type="gYearMonth"/>
patrick@12
  1201
        <data type="gYear"/>
patrick@12
  1202
      </choice>
patrick@12
  1203
    </attribute>
patrick@0
  1204
  </define>
patrick@0
  1205
  <define name="date.of.attribute">
patrick@0
  1206
    <attribute name="of">
patrick@33
  1207
      <choice>
patrick@33
  1208
        <value>birth</value>
patrick@33
  1209
        <value>death</value>
patrick@33
  1210
      </choice>
patrick@0
  1211
    </attribute>
patrick@0
  1212
  </define>
patrick@0
  1213
  <define name="date.content">
patrick@12
  1214
    <mixed>
patrick@12
  1215
      <zeroOrMore>
patrick@12
  1216
        <ref name="sup"/>
patrick@12
  1217
      </zeroOrMore>
patrick@12
  1218
    </mixed>
patrick@0
  1219
  </define>
patrick@36
  1220
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ name ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
  1221
  <define name="name">
patrick@0
  1222
    <element name="name">
patrick@0
  1223
      <ref name="name.attributes"/>
patrick@0
  1224
      <ref name="name.content"/>
patrick@0
  1225
    </element>
patrick@0
  1226
  </define>
patrick@0
  1227
  <define name="name.attributes">
patrick@0
  1228
    <optional>
patrick@0
  1229
      <ref name="name.of.attribute"/>
patrick@0
  1230
    </optional>
patrick@0
  1231
  </define>
patrick@0
  1232
  <define name="name.of.attribute">
patrick@0
  1233
    <attribute name="of">
patrick@33
  1234
      <choice>
patrick@33
  1235
        <value>person</value>
patrick@33
  1236
        <value>company</value>
patrick@33
  1237
        <value>book</value>
patrick@33
  1238
        <value>newspaper</value>
patrick@33
  1239
        <value>party</value>
patrick@33
  1240
      </choice>
patrick@0
  1241
    </attribute>
patrick@0
  1242
  </define>
patrick@2
  1243
  <define name="name.content">
patrick@2
  1244
    <ref name="inlines"/>
patrick@2
  1245
  </define>
patrick@36
  1246
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ note ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@5
  1247
  <define name="note">
patrick@5
  1248
    <element name="note">
patrick@5
  1249
      <ref name="note.attributes"/>
patrick@5
  1250
      <ref name="note.content"/>
patrick@0
  1251
    </element>
patrick@0
  1252
  </define>
patrick@5
  1253
  <define name="note.attributes">
patrick@0
  1254
    <optional>
patrick@5
  1255
      <ref name="note.label.attribute"/>
patrick@0
  1256
    </optional>
patrick@0
  1257
  </define>
patrick@5
  1258
  <define name="note.label.attribute">
patrick@0
  1259
    <attribute name="label"/>
patrick@0
  1260
  </define>
patrick@5
  1261
  <define name="note.content">
patrick@17
  1262
    <choice>
patrick@17
  1263
      <ref name="inlines"/>
patrick@17
  1264
      <oneOrMore>
patrick@20
  1265
        <ref name="p"/>
patrick@17
  1266
      </oneOrMore>
patrick@17
  1267
    </choice>
patrick@0
  1268
  </define>
patrick@36
  1269
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ foreign ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
  1270
  <define name="foreign">
patrick@0
  1271
    <element name="foreign">
patrick@0
  1272
      <ref name="foreign.attributes"/>
patrick@0
  1273
      <ref name="foreign.content"/>
patrick@0
  1274
    </element>
patrick@0
  1275
  </define>
patrick@0
  1276
  <define name="foreign.attributes">
patrick@0
  1277
    <optional>
patrick@0
  1278
      <ref name="lang.attribute"/>
patrick@0
  1279
    </optional>
patrick@0
  1280
  </define>
patrick@0
  1281
  <define name="foreign.content">
patrick@0
  1282
    <ref name="inlines"/>
patrick@0
  1283
  </define>
patrick@36
  1284
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ highlight ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
  1285
  <define name="highlight">
patrick@0
  1286
    <element name="highlight">
patrick@0
  1287
      <ref name="highlight.content"/>
patrick@0
  1288
    </element>
patrick@0
  1289
  </define>
patrick@0
  1290
  <define name="highlight.content">
patrick@0
  1291
    <ref name="inlines"/>
patrick@0
  1292
  </define>
patrick@36
  1293
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ mentioned ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@5
  1294
  <define name="mentioned">
patrick@5
  1295
    <element name="mentioned">
patrick@5
  1296
      <ref name="mentioned.content"/>
patrick@5
  1297
    </element>
patrick@5
  1298
  </define>
patrick@5
  1299
  <define name="mentioned.content">
patrick@5
  1300
    <ref name="inlines"/>
patrick@5
  1301
  </define>
patrick@36
  1302
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ quote ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@5
  1303
  <define name="quote">
patrick@5
  1304
    <element name="quote">
patrick@5
  1305
      <ref name="quote.content"/>
patrick@5
  1306
    </element>
patrick@5
  1307
  </define>
patrick@5
  1308
  <define name="quote.content">
patrick@5
  1309
    <ref name="inlines"/>
patrick@5
  1310
  </define>
patrick@36
  1311
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ acronym ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@8
  1312
  <define name="acronym">
patrick@8
  1313
    <element name="acronym">
patrick@8
  1314
      <ref name="acronym.content"/>
patrick@8
  1315
    </element>
patrick@8
  1316
  </define>
patrick@8
  1317
  <define name="acronym.content">
patrick@8
  1318
    <ref name="inlines"/>
patrick@8
  1319
  </define>
patrick@36
  1320
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ term ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@10
  1321
  <define name="term">
patrick@10
  1322
    <element name="term">
patrick@10
  1323
      <ref name="term.content"/>
patrick@10
  1324
    </element>
patrick@10
  1325
  </define>
patrick@10
  1326
  <define name="term.content">
patrick@10
  1327
    <ref name="inlines"/>
patrick@10
  1328
  </define>
patrick@36
  1329
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ link ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@0
  1330
  <define name="link">
patrick@0
  1331
    <element name="link">
patrick@0
  1332
      <ref name="link.attributes"/>
patrick@0
  1333
      <ref name="link.content"/>
patrick@0
  1334
    </element>
patrick@0
  1335
  </define>
patrick@0
  1336
  <define name="link.attributes">
patrick@43
  1337
    <choice>
patrick@43
  1338
      <ref name="uri.attribute"/>
patrick@43
  1339
      <ref name="idref.attribute"/>
patrick@43
  1340
    </choice>
patrick@10
  1341
  </define>
patrick@10
  1342
  <define name="uri.attribute">
patrick@10
  1343
    <attribute name="uri">
patrick@10
  1344
      <data type="anyURI"/>
patrick@10
  1345
    </attribute>
patrick@10
  1346
  </define>
patrick@10
  1347
  <define name="idref.attribute">
patrick@10
  1348
    <attribute name="idref">
patrick@10
  1349
      <data type="IDREF"/>
patrick@10
  1350
    </attribute>
patrick@0
  1351
  </define>
patrick@0
  1352
  <define name="link.content">
patrick@0
  1353
    <ref name="inlines"/>
patrick@0
  1354
  </define>
patrick@42
  1355
  <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ anchor ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
patrick@42
  1356
  <define name="anchor">
patrick@42
  1357
    <element name="anchor">
patrick@43
  1358
      <ref name="anchor.attributes"/>
patrick@42
  1359
    </element>
patrick@42
  1360
  </define>
patrick@42
  1361
  <define name="anchor.attributes">
patrick@42
  1362
    <ref name="anchor.id.attribute"/>
patrick@42
  1363
  </define>
patrick@42
  1364
  <define name="anchor.id.attribute">
patrick@42
  1365
    <attribute name="xml:id">
patrick@42
  1366
      <data type="ID"/>
patrick@42
  1367
    </attribute>
patrick@42
  1368
  </define>
patrick@0
  1369
</grammar>