<!-- typebook.dtd

    An application of DocBook for documenting typographic systems (eg DTP)

    Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004
    Silmaril Consultants - Peter Flynn <[email protected]>

    You may modify, use, and distribute this shim in any way you wish
    except by charging for it or claiming that you wrote it. This header
    and identity must be preserved on all copies and derivatives.

    The DocBook DTD is copyright of the Davenport Group and OASIS.

    A suitable Public Identifier for this shim is

    +//Silmaril//DTD DocBook 4.2 Adapted for Typographic Systems//EN//XML

-->

<!-- Declare the DTD and give the path to your local copy. This could
    be a full URL but some editors don't have networking capability.
    The canonical URL for the DocBook DTD is

       http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd

    Documentation is at http://www.docbook.org

    You also need a copy of the MathML2 DTD.

-->

<!ENTITY % docbook SYSTEM "/dtds/docbook/docbookx.dtd">

<!-- Set up a toggle to let the internal subset in the instance
    define what the output target is (default is HTML) -->

<!ENTITY % target "html">
<!ENTITY % %target; "INCLUDE">

<!ENTITY % html "IGNORE">
<!ENTITY % latex "IGNORE">

<!-- LOCAL MODIFICATIONS (things which DocBook should have but doesn't -->

<!-- 1. Allow tables to end with a <para> or <simplelist> for notes -->

<!ENTITY % tbl.tgroup.mdl
        "colspec*,spanspec*,thead?,tfoot?,tbody,(para|simplelist)*">

<!-- 2. Force colwidth attribute onto ENTRY by abusing %role.attrib;
       so that table column width can be controlled by a specific
       entry. Also abuse colspec to bear a role (presetting the
       typographic appearance for a column). Use altfilename for
       those occasions where you want to replace text with an image. -->

<!ENTITY % role.attrib
       "role           CDATA           #IMPLIED
        colwidth       CDATA           #IMPLIED
        altfilename    CDATA           #IMPLIED">

<!-- 3. Add some extra markup to apply to the content of wordasword,
       otherwise it's impossible for a stylesheet to get the
       appearance right. -->

<!ENTITY % local.word.char.mix
        "|foreignphrase|varname|systemitem|format|literal|productname|TeX|LaTeX|LaTeXe|BibTeX|LyX">
<!ENTITY % local.textobject.mix "|TeX|LaTeX|LaTeXe|BibTeX|LyX">

<!-- 4. Add a reference point to block quotations so they can refer to
       something in the bibliography properly -->

<!ENTITY % local.blockquote.attrib "citedoc IDREF #IMPLIED
                                   citedetail CDATA #IMPLIED">

<!-- 5. Add a compulsory ID to firstterm by ignoring what's declared
       and redeclaring it at the end of this file (see bottom),
       otherwise it can't be used for linking -->

<!ENTITY % firstterm.attlist "IGNORE">

<!-- 6. Add a reference point to cited titles and acronyms for the
       same reason as block quotations above -->

<!ENTITY % local.citetitle.attrib
        "ref IDREF #REQUIRED
         show (author|date|both|none|title|authoronly) 'title'">
<!ENTITY % local.acronym.attrib "ref IDREF #IMPLIED">

<!-- 6a. Hint to users that dates should have a sensible format -->

<!ENTITY % local.date.attrib "YYYY-MM-DD CDATA #REQUIRED">

<!-- 6b. Add citetitle to releaseinfo and acronym to revremark
        and add logos here and to other places they might occur -->

<!ENTITY % local.docinfo.char.mix "|citetitle|acronym|format|TeX|LaTeX|LaTeXe|BibTeX|LyX">
<!ENTITY % local.ndxterm.char.mix "|TeX|LaTeX|LaTeXe|BibTeX|LyX">
<!ENTITY % local.smallcptr.char.mix "|TeX|LaTeX|LaTeXe|BibTeX|LyX">

<!-- 7. Add document type values to bibliographic entries so they can
       be passed to a formatter. This set is a subset of BibTeX's. -->

<!ENTITY % local.biblioentry.attrib
        "type (article|book|booklet|inbook|incollection|inproceedings|manual|mastersthesis|misc|phdthesis|proceedings|techreport|unpublished|webpage) #REQUIRED">

<!-- 8. Provide a new element in mixed content for describing examples
       of typesetting so that you can SPECIFY, eg, 24pt bold italic.
       This is probably the only class of book where you MUST have
       font spec control in the document markup.
       [3.6] Removed the fake element SPAN to allow HTML versions to use
       preformatted LaTeX etc logos, and used elements instead -->

<!ENTITY % local.title.char.mix "|format|TeX|LaTeX|LaTeXe|BibTeX|LyX">
<!ENTITY % local.para.char.mix "|format|TeX|LaTeX|LaTeXe|BibTeX|LyX">
<!ELEMENT format (#PCDATA|methodname|command|literal|literallayout|emphasis|TeX|LaTeX)*>
<!ATTLIST format fontencoding (OT1|T1|TS1|OML|OMS|OMX|OT4|LY1|U|Z) #IMPLIED
                fontfamily CDATA #IMPLIED
                fontseries (l|m|b|bx|k) #IMPLIED
                fontshape (it|n|sl|ui|sc) #IMPLIED
                fontdefault (rm|sf|tt) #IMPLIED
                fontstep (tiny|scriptsize|footnotesize|small|normalsize|
                          large|Large|LARGE|huge|Huge) #IMPLIED
                fontsize CDATA #IMPLIED
                leading CDATA #IMPLIED
                colourmodel (named|rgb|cmyk|pantone) #IMPLIED
                colour CDATA #IMPLIED
                colourcode CDATA #IMPLIED
                background CDATA #IMPLIED
                lining (under|through|wavy) #IMPLIED
                image CDATA #IMPLIED
                frame (yes|no) "no"
                paragraph (yes|no) "no"
                struts (horiz|vert|both) #IMPLIED
                condition (LaTeX|HTML|both) "both">

<!-- obsolete as of 3.6 -->
<![IGNORE[
<!ENTITY % local.title.char.mix "|span">
<!-- local.docinfo.char.mix is done elsewhere -->
<!ENTITY % local.ndxterm.char.mix "|span">
<!ENTITY % local.smallcptr.char.mix "|span">
<!ELEMENT span (#PCDATA|span)*>
<!ATTLIST span class CDATA #REQUIRED>
]]>

<!-- 8a. Add sidebars to the types of elements available in examples
        and a cross-ref ability to footnotes -->

<!ENTITY % local.example.mix "|sidebar">
<!ENTITY % local.footnote.attrib "usenote IDREF #IMPLIED">

<!-- 9. Add switch for lists to enable automated Boolean phrasing.
       This allows lists within paragraphs to (a) add punctuation
       correctly; and (b) to make them "and" or "or" lists. -->

<!ENTITY % local.orderedlist.attrib "boolean (and|or) 'and'">
<!ENTITY % local.itemizedlist.attrib "boolean (and|or) 'or'">

<!-- 10. Supply switches and entity declarations for LaTeX and HTML -->

<![%latex;[
<!ENTITY AElig "\AE ">
<!ENTITY Aring "\AA ">
<!ENTITY EUR "\EUR{}">
<!-- obsolete as of 3.6
<!ENTITY TeX "\TeX{}">
<!ENTITY LaTeX "\LaTeX{}">
<!ENTITY tLaTeX "\sfLaTeX{}">
<!ENTITY LaTeXe "\LaTeXe{}">
<!ENTITY BibTeX "\BibTeX{}">
<!ENTITY LyX "\LyX{}">
-->
<!ENTITY Lstrok "\L{}">
<!ENTITY OElig "\OE ">
<!ENTITY Oslash "\O ">
<!ENTITY aelig "\ae ">
<!ENTITY ampers "\amp ">
<!ENTITY apos "'">
<!ENTITY aring "\aa ">
<!ENTITY bsol "$\backslash$">
<!ENTITY bull "\textbullet{}">
<!ENTITY caret "{\char'136}">
<!ENTITY ccaron "\v c">
<!ENTITY ccedil "\c c">
<!ENTITY cdot "\.c">
<!ENTITY chi "\chi">
<!ENTITY copyleft "\textcopyleft{}">
<!ENTITY dagger "\dag ">
<!ENTITY darr "\DOWNarrow">
<!ENTITY ditto '\dito{}'>
<!ENTITY dollar "\$">
<!ENTITY eacute "\'e">
<!ENTITY eg "e.g.">
<!ENTITY emsp "\quad ">
<!ENTITY epsilon "\epsilon">
<!ENTITY eta "\eta">
<!ENTITY etc "etc.">
<!ENTITY euro "\euro{}">
<!ENTITY frac16 "\Frac16">
<!ENTITY frac13 "\Frac13">
<!ENTITY grave "\`{}">
<!ENTITY greaterthan "$>$">
<!ENTITY gtilde "\~g">
<!ENTITY hash "\#">
<!ENTITY hellip "\dots ">
<!ENTITY ie "i.e.">
<!ENTITY inch "$''$">
<!ENTITY inodot "{\fontfamily{cmr}\selectfont\i}">
<!ENTITY iacute "{\fontfamily{cmr}\selectfont\'\i}">
<!ENTITY jnodot "{\fontfamily{cmr}\selectfont\j}">
<!ENTITY lb "\break ">
<!ENTITY lbrace "{\ttfamily\char'173}">
<!ENTITY ldquo "``">
<!ENTITY lessthan "$&lt;$">
<!ENTITY lsquo "`">
<!ENTITY lstrok "\l{}">
<!ENTITY mdash "\mdash{}">
<!ENTITY mrule "---">
<!ENTITY mdot "\.m">
<!ENTITY metafont "\mf{}">
<!ENTITY minus "\ifmmode-\else$-$\fi{}">
<!ENTITY nbar "\bar n">
<!ENTITY ndash "\ndash{}">
<!ENTITY nu "\nu">
<!ENTITY oelig "\oe ">
<!ENTITY ohbar "\b o">
<!ENTITY olong "\H o">
<!ENTITY omacr "\=o">
<!ENTITY ootie "\t oo">
<!ENTITY oslash " \o ">
<!ENTITY percnt "&#x005C;&#x0025;">
<!ENTITY pi "\pi">
<!ENTITY quot '"'>
<!ENTITY rarr "$\rarr$">
<!ENTITY rbrace "{\ttfamily\char'175}">
<!ENTITY rdquo "''">
<!ENTITY rmfont "\rmfontfamilyname{}">
<!ENTITY rsquo "'">
<!ENTITY sdot "\d s">
<!ENTITY sect "\S{}">
<!ENTITY sffont "\sffontfamilyname{}">
<!ENTITY shy "\-">
<!ENTITY smiley "\smiley{}">
<!ENTITY sterm "\char'215 ">
<!ENTITY szlig "\ss ">
<!ENTITY tau "\tau">
<!ENTITY thinsp "\thinspace{}">
<!ENTITY tilde "{\char'176}">
<!ENTITY times "$\times$">
<!ENTITY trade "\texttrademark{}">
<!ENTITY ttfont "\ttfontfamilyname{}">
<!ENTITY uarr "\UParrow">
<!ENTITY ubreve "\u u">
<!ENTITY ucaron "\v u">
<!ENTITY uline "{\ttfamily\char'137}">
<!ENTITY vbar "$|$">
<!ENTITY wcirc "\^w">
]]>

<![%html;[
<!ENTITY EUR "&#x20AC;">
<!-- obsolete as of 3.6
<!ENTITY TeX SYSTEM "texlogo.ent">
<!ENTITY BIBTeX "BIB&TeX;">
<!ENTITY LaTeX SYSTEM "latexlogo.ent">
<!ENTITY tLaTeX SYSTEM "latexlogo.ent">
<!ENTITY LaTeXe SYSTEM "latexelogo.ent">
<!ENTITY LyX "LyX">
-->
<!ENTITY ampers "&#38;#38;">
<!ENTITY apos "&#x2019;">
<!ENTITY bull "&#x8226;"><!-- DocBook says 2022 but that's an asterisk -->
<!ENTITY caret "^">
<!ENTITY chi "&#x003C7;">
<!ENTITY copyleft "&#x00A9;">
<!ENTITY ditto '&#x201D;'>
<!ENTITY eacute "&#x00E9;">
<!ENTITY eg "e.g.">
<!ENTITY emsp "&#x00A0;&#x00A0;">
<!ENTITY epsilon "&#x003B5;">
<!ENTITY eta "&#x003B7;">
<!ENTITY etc "etc.">
<!ENTITY euro "&#x20AC;">
<!ENTITY frac16 "1/6">
<!ENTITY greaterthan "&#38;gt;">
<!ENTITY gtilde "g&#x02DC;">
<!ENTITY hash "#">
<!ENTITY hellip "...">
<!ENTITY ie "i.e.">
<!ENTITY inch "&#x2033;">
<!ENTITY jnodot "j">
<!ENTITY lb "<br/>">
<!ENTITY ldquo "&#x2018;&#x2018;">
<!ENTITY lessthan "&#38;lt;">
<!ENTITY rdquo "&#x2019;&#x2019;">
<!ENTITY lsquo "&#x2018;">
<!ENTITY lstrok  "&#x0142;">
<!ENTITY rsquo "&#x2019;">
<!ENTITY mdash "&#x00A0;&#x2014; ">
<!ENTITY mrule "&#x2014;">
<!ENTITY mdot "mh">
<!ENTITY metafont "METAFONT">
<!ENTITY minus "&#x2212;">
<!ENTITY nbar "n">
<!ENTITY ndash "&#x2013;">
<!ENTITY nu "&#x003BD;">
<!ENTITY ohbar "o">
<!ENTITY olong '&#x0151;'>
<!ENTITY ootie "oo">
<!ENTITY pi "&#x03C0;">
<!ENTITY quot '"'>
<!ENTITY rarr   "&#x2192;">
<!ENTITY rmfont "your current browser serif font">
<!ENTITY sect "#167;">
<!ENTITY sffont "your current browser sans-serif font">
<!ENTITY smiley "&#x2323;">
<!ENTITY shy "&#x00AD;">
<!ENTITY sterm "s">
<!ENTITY tau "&#x003C4;">
<!ENTITY thinsp "&#x2009;">
<!ENTITY trade "&#x2122;">
<!ENTITY ttfont "your current browser monospace font">
<!ENTITY ucaron "&#x016D;">
<!ENTITY uline "_">
<!ENTITY vbar "|">
<!ENTITY wcirc "&#x0175;">
]]>

<!-- 11. Add MathML to inline and display equations -->

<!ENTITY % MATHML.prefixed "INCLUDE">
<!ENTITY % mathml SYSTEM "/dtds/mathml/mathml2.dtd">
%mathml;
<!ENTITY % inlineequation.content "(%MathExpression;)">
<!ENTITY % equation.content "(%MathExpression;)">

<!-- 12. Now invoke DocBook -->

%docbook;

<!-- 13. Finally, implement the attributes required for firstterm -->

<!ATTLIST firstterm
               %linkend.attrib;                %idreq.common.attrib;
               %firstterm.role.attrib;
               %local.firstterm.attrib;
>

<!ATTLIST colspec %role.attrib;>

<!-- 14. NEW. Empty elements for the logos so that XSLT can produce
        better quality output. -->

<!ELEMENT TeX EMPTY>
<!ELEMENT LaTeX EMPTY>
<!ELEMENT LaTeXe EMPTY>
<!ELEMENT BibTeX EMPTY>
<!ELEMENT LyX EMPTY>

<!ENTITY alphabet "The quick brown fox jumps over the lazy dog">
<!ENTITY uc.alphabet "THE QUICK BROWN FOX JUMPS OVER THE LAZY DOG">
<!ENTITY ie.alphabet "N&iacute;l aon tinte&aacute;n mar do thinte&aacute;n f&eacute;in">
<!ENTITY de.alphabet "Fuch&sterm;, Du hast die Gan&sterm; gestohlen, gib sie wieder her!">

<!-- That's all, folks! -->