Re: [AD] Re: [AL] allegro DTD

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]




On Mon, 29 Nov 2004, Elias Pschernig wrote:

And it's not first draft, but draft 5, remember! :-)


Heh. Well, we should have need of a draft 6 soon. If things go so well
as they look right now, 4.2.0 may ship without makedoc. Hm, or at least
4.4.0 :)

Attached is draft 6 :-) I added em, definition lists (definition-list and term) and removed header and footer.

Have a nice day.

Stepan Roh
<!--
  Allegro XML Documentation DTD Draft 6
  Created by Stepan Roh <src@xxxxxxxx>

  $Id: allegdoc.dtd,v 1.18 2004/11/29 20:16:16 stepan Exp $

  Licensed under Allegro's license (see http://alleg.sf.net).
-->



<!--
  ID attribute (common to all elements).
-->
<!ENTITY % id.attrib    "id   ID    #IMPLIED">



<!--
  Language specification attribute (common to all elements).
-->
<!ENTITY % lang.attrib  "lang CDATA   #IMPLIED">



<!--
  Attributes common to all elements.
-->
<!ENTITY % common.attrib
    "%id.attrib;
     %lang.attrib;"
>



<!--
  Image formats.
-->
<!NOTATION png  SYSTEM "image/png">
<!NOTATION jpeg SYSTEM "image/jpeg">
<!ENTITY % image.formats "png | jpeg">



<!--
  Inlined elements.
-->
<!ENTITY % inline.class "code | tt | em">



<!--
  Linked elements.
-->
<!ENTITY % link.class "link | ulink">



<!--
  Inline content.
-->
<!ENTITY % inline.content "#PCDATA | %inline.class;">



<!--
  Linked content.
-->
<!ENTITY % linked.content "#PCDATA | %link.class;">



<!--
  Active (inlined and link) content.
-->
<!ENTITY % active.content "#PCDATA | %inline.class; | %link.class;">



<!--
  Block-level content.
-->
<!ENTITY % block.content
     "para | text-block | code-block | list | definition-list | block-quote | image">



<!--
  Document is top level element.
-->
<!ENTITY % document.nested "chapter">
<!ELEMENT document
    (title, front-page?, (%document.nested;)*)>
<!ENTITY % document.attrib "">
<!ATTLIST document
    %common.attrib;
    %document.attrib;
>



<!--
  Chapter. Front-page override that specified in parent document.
-->
<!ENTITY % chapter.nested
    "text-section | api-section | changes | people-list | faq-list">
<!ELEMENT chapter
    (title, front-page?, (%chapter.nested;)*)>
<!ENTITY % chapter.attrib "">
<!ATTLIST chapter
    %common.attrib;
    %chapter.attrib;
>



<!--
  Document and section-like elements title.
-->
<!ENTITY % title.nested "#PCDATA">
<!ELEMENT title (%title.nested;)*>
<!ENTITY % title.attrib "">
<!ATTLIST title
    %common.attrib;
    %title.attrib;
>



<!--
  Special first page (or bigger page header).
-->
<!ENTITY % front-page.nested "%block.content;">
<!ELEMENT front-page (%front-page.nested;)*>
<!ENTITY % front-page.attrib "">
<!ATTLIST front-page
    %common.attrib;
    %front-page.attrib;
>



<!--
  Paragraph.
-->
<!ENTITY % para.nested "%active.content;">
<!ELEMENT para (%para.nested;)*>
<!ENTITY % para.attrib "">
<!ATTLIST para
    %common.attrib;
    %para.attrib;
>



<!--
  Text section. Section-like element.
-->
<!ENTITY % text-section.nested "%block.content;">
<!ELEMENT text-section (title?, (%text-section.nested;)*)>
<!ENTITY % text-section.attrib "">
<!ATTLIST text-section
    %common.attrib;
    %text-section.attrib;
>



<!--
  Inner link.
-->
<!ENTITY % link.nested "#PCDATA">
<!ELEMENT link (%link.nested;)*>
<!ENTITY % link.attrib "ref   IDREF   #REQUIRED">
<!ATTLIST link
    %common.attrib;
    %link.attrib;
>



<!--
  Outer link.
-->
<!ENTITY % ulink.nested "#PCDATA">
<!ELEMENT ulink (%ulink.nested;)*>
<!ENTITY % ulink.attrib "url    CDATA #REQUIRED">
<!ATTLIST ulink
    %common.attrib;
    %ulink.attrib;
>



<!--
  Text block which preserves text layout.
-->
<!ENTITY % text-block.nested "%linked.content;">
<!ELEMENT text-block (%text-block.nested;)*>
<!ENTITY % text-block.attrib "">
<!ATTLIST text-block
    %common.attrib;
    %text-block.attrib;
>



<!--
  Code block which preserves text layout.
-->
<!ENTITY % code-block.nested "%linked.content;">
<!ELEMENT code-block (%code-block.nested;)*>
<!ENTITY % code-block.attrib "">
<!ATTLIST code-block
    %common.attrib;
    %code-block.attrib;
>



<!--
  Image (as block-level element).
-->
<!ENTITY % image.nested "EMPTY">
<!ELEMENT image (%image.nested;)*>
<!ENTITY % image.attrib "
    format      NOTATION (%image.formats;) #REQUIRED
    fileref     CDATA                      #REQUIRED
    title       CDATA                      #REQUIRED
    textfileref CDATA                      #REQUIRED">
<!ATTLIST image
    %common.attrib;
    %image.attrib;
>



<!--
  Frequently Asked Questions list. Section-like element.
-->
<!ENTITY % faq-list.nested "faq-question, faq-answer">
<!ELEMENT faq-list (title?, (%faq-list.nested;)*)>
<!ENTITY % faq-list.attrib "">
<!ATTLIST faq-list
    %common.attrib;
    %faq-list.attrib;
>



<!--
  FAQ question.
-->
<!ENTITY % faq-question.nested "%block.content;">
<!ELEMENT faq-question (%faq-question.nested;)*>
<!ENTITY % faq-question.attrib "">
<!ATTLIST faq-question
    %common.attrib;
    %faq-question.attrib;
>



<!--
  FAQ answer.
-->
<!ENTITY % faq-answer.nested "%block.content;">
<!ELEMENT faq-answer (%faq-answer.nested;)*>
<!ENTITY % faq-answer.attrib "">
<!ATTLIST faq-answer
    %common.attrib;
    %faq-answer.attrib;
>



<!--
  Code style. Text-level element.
-->
<!ENTITY % code.nested "%linked.content;">
<!ELEMENT code (%code.nested;)*>
<!ENTITY % code.attrib "">
<!ATTLIST code
    %common.attrib;
    %code.attrib;
>



<!--
  Teletype style. Text-level element.
-->
<!ENTITY % tt.nested "%linked.content;">
<!ELEMENT tt (%tt.nested;)*>
<!ENTITY % tt.attrib "">
<!ATTLIST tt
    %common.attrib;
    %tt.attrib;
>



<!--
  Emphasize. Text-level element.
-->
<!ENTITY % em.nested "%linked.content;">
<!ELEMENT em (%em.nested;)*>
<!ENTITY % em.attrib "">
<!ATTLIST em
    %common.attrib;
    %em.attrib;
>



<!--
  Ordered or unordered list.
-->
<!ENTITY % list.nested "list-item">
<!ELEMENT list (%list.nested;)*>
<!ENTITY % list.attrib "ordered (true | false) 'false'">
<!ATTLIST list
    %common.attrib;
    %list.attrib;
>



<!--
  List item.
-->
<!ENTITY % list-item.nested "%active.content;">
<!ELEMENT list-item (%list-item.nested;)*>
<!ENTITY % list-item.attrib "">
<!ATTLIST list-item
    %common.attrib;
    %list-item.attrib;
>



<!--
  Definition list. Section-like element.
-->
<!ENTITY % definition-list.nested "term, description">
<!ELEMENT definition-list (%definition-list.nested;)*>
<!ENTITY % definition-list.attrib "">
<!ATTLIST definition-list
    %common.attrib;
    %definition-list.attrib;
>



<!--
  Definition term.
-->
<!ENTITY % term.nested "%active.content;">
<!ELEMENT term (%term.nested;)*>
<!ENTITY % term.attrib "">
<!ATTLIST term
    %common.attrib;
    %term.attrib;
>



<!--
  Block quote.
-->
<!ENTITY % block-quote.nested "%active.content;">
<!ELEMENT block-quote (%block-quote.nested;)*>
<!ENTITY % block-quote.attrib "">
<!ATTLIST block-quote
    %common.attrib;
    %block-quote.attrib;
>



<!--
  List of people. Section-like element.
-->
<!ENTITY % people-list.nested "person, description">
<!ELEMENT people-list (title?, (%people-list.nested;)*)>
<!ENTITY % people-list.attrib "">
<!ATTLIST people-list
    %common.attrib;
    %people-list.attrib;
>



<!--
  Person.
-->
<!ENTITY % person.nested "name | mail">
<!ELEMENT person (%person.nested;)*>
<!ENTITY % person.attrib "">
<!ATTLIST person
    %common.attrib;
    %person.attrib;
>



<!--
  Mail.
-->
<!ENTITY % mail.nested "#PCDATA">
<!ELEMENT mail (%mail.nested;)*>
<!ENTITY % mail.attrib "">
<!ATTLIST mail
    %common.attrib;
    %mail.attrib;
>



<!--
  Changes. Section-like element.
-->
<!ENTITY % changes.nested "change-list">
<!ELEMENT changes (title?, (%changes.nested;)*)>
<!ENTITY % changes.attrib "">
<!ATTLIST changes
    %common.attrib;
    %changes.attrib;
>



<!--
  List of changes for one version.
-->
<!ENTITY % change-list.nested "change-item">
<!ELEMENT change-list (%change-list.nested;)*>
<!ENTITY % change-list.attrib
    "original-version   CDATA   #REQUIRED
     final-version      CDATA   #REQUIRED">
<!ATTLIST change-list
    %common.attrib;
    %change-list.attrib;
>



<!--
  One change in change-list.
-->
<!ENTITY % change-item.nested "%block.content;">
<!ELEMENT change-item (%change-item.nested;)*>
<!ENTITY % change-item.attrib
    "author             CDATA   #REQUIRED">
<!ATTLIST change-item
    %common.attrib;
    %change-item.attrib;
>



<!--
  API section. Section-like element.
-->
<!ENTITY % api-section.nested "function | variable | typedef">
<!ELEMENT api-section (title?, (%api-section.nested;)*)>
<!ENTITY % api-section.attrib "">
<!ATTLIST api-section
    %common.attrib;
    %api-section.attrib;
>



<!--
  API function. Constness of return value, and whether
  or not the function is a macro are all specified in attributes.
-->
<!ENTITY % function.nested "EMPTY">
<!ELEMENT function
    (name, return-value, argument-list, cross-refs?, description,
    (%function.nested;)*)>
<!ENTITY % function.attrib
    "macro (true | false) 'false'
     const (true | false) 'false'">
<!ATTLIST function
    %common.attrib;
    %function.attrib;
>



<!--
  Return value of function.
-->
<!ENTITY % return-value.nested "EMPTY">
<!ELEMENT return-value (type, (%return-value.nested;)*)>
<!ENTITY % return-value.attrib "">
<!ATTLIST return-value
    %common.attrib;
    %return-value.attrib;
>



<!--
  Type of function return value, argument or definition.
-->
<!ENTITY % type.nested "#PCDATA">
<!ELEMENT type (%type.nested;)*>
<!ENTITY % type.attrib "">
<!ATTLIST type
    %common.attrib;
    %type.attrib;
>



<!--
  List of function arguments.
-->
<!ENTITY % argument-list.nested "argument">
<!ELEMENT argument-list (%argument-list.nested;)*>
<!ENTITY % argument-list.attrib "">
<!ATTLIST argument-list
    %common.attrib;
    %argument-list.attrib;
>



<!--
  A single function argument description. Contains a name and type.
  The const-ness is specified in attribute.
-->
<!ENTITY % argument.nested "EMPTY">
<!ELEMENT argument (name, type, (%argument.nested;)*)>
<!ENTITY % argument.attrib
     "const (true | false) 'false'">
<!ATTLIST argument
    %common.attrib;
    %argument.attrib;
>



<!--
  Constant or variable.
-->
<!ENTITY % variable.nested "EMPTY">
<!ELEMENT variable (name, type, cross-refs?, description, (%variable.nested;)*)>
<!ENTITY % variable.attrib
     "const  (true | false)  'false'">
<!ATTLIST variable
    %common.attrib;
    %variable.attrib;
>



<!--
  Return type of function or type of variable.
-->
<!ELEMENT typedef (name, (struct | union)?, cross-refs?, description)>
<!ENTITY % typedef.attrib "">
<!ATTLIST typedef
    %common.attrib;
    %typedef.attrib;
>



<!--
  Definition of a structure.
-->
<!ELEMENT struct (member)*>
<!ENTITY % struct.attrib "">
<!ATTLIST struct
    %common.attrib;
    %struct.attrib;
>



<!--
  Definition of an union.
-->
<!ELEMENT union (member)*>
<!ENTITY % union.attrib "">
<!ATTLIST union
    %common.attrib;
    %union.attrib;
>



<!--
  Member of struct or union.
  The const-ness is specified in attribute.
-->
<!ENTITY % member.nested "EMPTY">
<!ELEMENT member (name, type, (%member.nested;)*)>
<!ENTITY % member.attrib
     "const (true | false) 'false'">
<!ATTLIST member
    %common.attrib;
    %member.attrib;
>



<!--
  Cross-references.
-->
<!ENTITY % cross-refs.nested "cross-ref">
<!ELEMENT cross-refs (%cross-refs.nested;)*>
<!ENTITY % cross-refs.attrib "">
<!ATTLIST cross-refs
    %common.attrib;
    %cross-refs.attrib;
>



<!--
  Cross-reference to function or description.
-->
<!ENTITY % cross-ref.nested "#PCDATA">
<!ELEMENT cross-ref (%cross-ref.nested;)*>
<!ENTITY % cross-ref.attrib "ref    IDREF #REQUIRED">
<!ATTLIST cross-ref
    %common.attrib;
    %cross-ref.attrib;
>



<!--
  Function, variable or type description.
-->
<!ENTITY % description.nested "%block.content;">
<!ELEMENT description (%description.nested;)*>
<!ENTITY % description.attrib "">
<!ATTLIST description
    %common.attrib;
    %description.attrib;
>



<!--
  Name. Used for functions, variables, types and people.
-->
<!ENTITY % name.nested "#PCDATA">
<!ELEMENT name (%name.nested;)*>
<!ENTITY % name.attrib "">
<!ATTLIST name
    %common.attrib;
    %name.attrib;
>


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/