Part II(c): Inline Elements

Structure Guidelines for DAISY/NISO
Last Revised: September 10, 2005

Inline elements are the structures that occur inside the block elements described in the previous chapter. For example, the inline element <sent> (sentence) would occur inside the block element <p> (paragraph), and the inline tags <abbr> (abbreviation) and <acronym> would occur inside the inline element <sent> (or inside <p> if sentences were not tagged).

IMPORTANT: Page numbers and references to notes are items that provide navigation points for the end user. There is no requirement to provide these, but it is strongly recommended that these be included for text books.


Information Object: Anchor

Definition: An anchor points to another place within the document (as identified by an ID attribute), to another document, or to a specific point in another document. A link is made up of a pair of anchors, with one being the "source" anchor, and the other being the "destination" anchor.

When using an anchor to reference another location within the same document, the anchor must include a pound sign (#) followed by the name of an identifier unique in that document. When using a link to reference a location within a different document, the href attribute must include the name of an external document or file, or the name of an external file followed by a pound sign (#) followed by a unique identifier in the external document. External links without the pound sign and unique identifier will open the document and position the user at the beginning.

Syntax:

     Link Anchor: <a href="uri">Text of reference</a>
    

Example: 1 - Internal Reference
The beginning of a recipe might be marked as follows so it could be easily referenced from other parts of the book:


      <level3>
          <h3><a id="red_sauce">Classic Red Sauce</a></h3>
          ...<
      /level3>
      

A cross-reference to this recipe would be tagged as follows:


      <p>For a simple, delicious alternative, try the <a href="#red_sauce">Classic Red Sauce</a> on page 109.</p>
    

Selecting the text "Classic Red Sauce" of the link anchor would position the user at the beginning of the heading of that recipe.

Example: 2 - External File Reference

Assuming that a large cookbook was published in two volumes, a reference from Volume One to Volume Two would be marked as follows:


      <p>The basic recipes that every aspiring Italian cook should know will 
      be found in <a href="italian_cooking/vol2.xml">Volume Two.</a></p>
      

Selecting the anchor text "Volume Two" would open that volume and position the user at its beginning.

Example: 3 - External File Reference With A Unique Identifier
Referencing a specific recipe in Volume Two, for example, Classic Red Sauce, from a point in Volume One would be marked as shown below.
The recipe in Volume Two would be marked exactly as shown in Example 1 above:


      <level3>
      <h3><a id="red_sauce">Classic Red Sauce</a></h3>
      ...</level3>
      

The cross-reference in Volume One would be marked:


      <p>See <a href="italian_cooking/vol2.xml#red_sauce">Classic 
      Red Sauce</a> in Volume II, page 109.</p>
    

Selecting the anchor "Classic Red Sauce" will open Volume Two and position the user at the beginning of the heading of the recipe.

New in DAISY/NISO, Release 2005: The "external" attribute, which can hold values of "true" or the default "false," indicates whether the external media must be rendered by an external application.

Example 4 would launch the given address in a web browser when selected:


      <a href="http://www.daisy.org/" external="true">DAISY homepage</a>
    

Information Object: Abbreviation

Definition: A shortened form of a word. For example: amt for amount, rec'd for received, mlle. for mademoiselle, doz. for dozen, oz. for ounce, cwt for hundred-weight. (See also Information Object: Acronym).

Syntax:

<abbr>...</abbr>

Example:


      <p>His letter of March 4, 1816 to Thornton indicates that he did, in 
      fact, receive the disputed shipment of grain: <abbr>Rec'd</abbr> 
      today 500 <abbr>lbs.</abbr> barley delivered by your carter. 
      Payment in <abbr>amt</abbr> of 3 dollars will be forwarded in the 
      care of <abbr>M.</abbr> de la Grange.</p>
      

Information Object: Acronym

Definition: A word formed from the initial letter or letters of a group of words. For example: UNESCO, NATO, XML, EU, A.D.A., URI, MPEG, SCSI.. (See also Information Object: Abbreviation)

Markup: In a given language some acronyms are normally pronounced (e.g., UNESCO and NATO in English), while others are spelled out letter by letter (XML, EU, and A.D.A., again in English). Some acronyms are partly spelled and partly pronounced (MPEG, in English). Many braille codes require acronyms to be identified for proper translation. Speech synthesizers may benefit from marking up acronyms as normally pronounced or normally spelled out, in a given language. Use the "pronounce" attribute to identify an acronym as normally pronounced in the language of the target audience (pronounce="yes") or not normally pronounced in that language (spelled out instead) (pronounce="no"). Acronyms that are, in the target language, commonly partially spelled and partially pronounced (MPEG) or pronounced in a way that is not easily derivable from the acronym (SCSI), should be marked as not pronounced (pronounce="no"). Words which were originally acronyms but have become words in their own right need not be marked (e.g., radar, scuba).

Syntax:

<acronym>...</acronym>

Example:


      <p>Although the passage of the <acronym pronounce="no">A.D.A.</acronym> promised great benefits to 
      disabled Americans, many of those benefits have been slow to materialize 
      in the <acronym pronounce="no">U.S.</acronym></p>
      
      <p>There are those who maintain that the impact of <acronym
      pronounce="no">XML</acronym> on the World Wide Web (<acronym
      pronounce="no">WWW</acronym>) in comparison with <acronym
      pronounce="no">HTML</acronym> will be comparable to the advances 
      in personal computing made possible by the move from <acronym
      pronounce="yes">DOS</acronym> to Windows.</p>
    

Information Object: Computer Code

Definition: Computer code in a computer programming language.

Markup: Computer code, which is usually displayed in the printed book in Courier bold print, is marked with the <code> tag. This tag can be used in either block or inline settings.

Syntax:

<code>...</code>

Example:


      <p>For example, <code>printf("--hello, world-- \n");</code> would
      display "--hello, world--" on the screen, followed by a carriage return.</p>
    

See also Information Object: Keyboard Input and Information Object: Sample

Playback devices can be configured so that text tagged as <code> will preserve all white space (line breaks, indentation, etc.).


Information Object: Defining Instance

Definition: The first occurrence of a word or term that is defined or explained elsewhere in the book.

Markup: Use this element to mark the first occurrence of a word or term that is defined later in a book. Include in the tag a link to the definition, located perhaps in a glossary.

Syntax:

    <dfn>...</dfn>
    

Example:


        <p>Some of the most versatile materials are made of <dfn><a
        href="#polymer">polymers.</a></dfn></p>
    

Information Object: Emphasis

Definition: A word or series of words that the author has emphasized through the use of some typographical convention such as italic or boldface type or underlining.

Markup: The <em> and <strong> tags are relative indicators of emphasis. The <em> tag indicates moderate emphasis and the <strong> tag heavier emphasis. These tags must be used with care since their application will depend upon the types of emphasis employed in a document. In a book in which italics and boldface are used for emphasis, <em> would mark the former, and <strong> the latter. However, if a book used boldface in some situations and underlined boldface in other, <em> would mark the first type of emphasis and <strong> the second.

Syntax:

    <strong>...</strong> or <em>...</em>
    

Example:

The following paragraph would be marked up as shown below:

"When pressing the blue button, hold down for two full seconds. And remember, DO NOT PRESS THE RED BUTTON!"


    <p>When pressing the blue button, <em>hold down for two full
    seconds.</em> And remember, <strong>DO NOT PRESS THE RED
    BUTTON!</strong></p>
    

Information Object: Horizontal Rule

New in DAISY/NISO, Release 2005: The <hr /> element has been removed from the DTD and the content model.


Information Object: Keyboard Input

Definition: Information that the reader of the book is to input directly into a computer using the keyboard.

Markup: Content that is to be entered into a computer via a keyboard is to be marked with the <kbd> tag. This tag can be used in either block or inline settings.

Syntax:

<kbd>...</kbd>

Example:


    <p>To copy the selection to the clipboard, press <kbd>CTRL+C</kbd>.</p>
    

See also Information Object: Computer Code and Information Object: Sample


Information Object: Line Break

Definition: A line break constitutes the forcible division of text onto separate lines. Text is sometimes presented with no punctuation separating different segments but with each segment appearing on a line by itself. When it is necessary to preserve these separations a line break should be forced.

Syntax:

    <br />
    

Markup: This is an empty element (i.e., only a single tag ending in "/" is used, rather than the usual start and end tags).

Example:


    <code>while( i &lt; limit ) <br/>
    i++;<br />
    </code>
    

Information Object: Page Number

Definition: A number printed on a page of a document to uniquely identify it. Most contemporary books are paginated consecutively and pages are generally accounted for in the pagination sequence even if a number is not actually printed on the page.

Bibliographic Reference

Markup: The intent of using markup to indicate page numbers is to provide direct navigation to a page. It is strongly recommended that pages be individually and uniquely tagged in text books, and recommended that wherever possible, they be included in all DTBs. All page tags must have a unique id attribute.

Page numbers are marked with the <pagenum> tag. There are three types of page which are distinguished in the markup through use of the "page" attribute. page="normal" is used to indicate that the content of the number is the standard arabic numeral used in the body and rear matter of most books. page="front" is used to mark the page numbers used in the front matter of most books (most often roman numerals but sometimes arabic). Finally, page="special" is used to indicate variant pagination schemes used in some books, for example hyphenated numbers often used in appendices (A-1, A-2, etc.).

The <pagenum> tag must be placed at the top of a page, regardless of where the page is located on the print page, so that the end user will be positioned at the beginning of the page when he or she navigates to it. To ensure accurate navigation, the markup at the beginning of a major structure (part, chapter, section, etc.) must follow a precise order. The order should always be: level1-6 tag, pagenum, heading. This will ensure that if end users navigate to the beginning of the major structure (as marked by the level1-6 tag) and begin playback, they will hear both the page number and the heading of the major structure. If they navigate to the page number, they will still hear both page number and heading.

When pages are being included in a DTB, all pages, including blank ones, must be marked. In a DTD with audio, the end user should receive aural confirmation of the existence of blank pages, e.g., "Page 43 -- blank page." Pages that are part of the pagination sequence but have no page number printed on them should be tagged and the page number included. Unnumbered pages (those that are not included in the pagination sequence) should be tagged but no page number should be included within the tag, allowing navigation by "next" and "previous" page controls.

Syntax:

    <pagenum page="normal" id="...">...</pagenum>
    <pagenum page="front" id="...">...</pagenum>
    <pagenum page="special" id="...">...</pagenum>
    

Examples: page="front" and page="normal"


      <frontmatter>
      
       <level1 class="preface" id="pf">
           <pagenum page="front" id="fm-3">iii</pagenum>
       <h1 class="preface">Preface, Acknowledgments and a Note on Structure</h1>
       <p>This is not a conventional cookbook. Though I should straightaway attach 
       a disclaimer to my disclaimer and say that I have nothing but the highest regard
       for the traditional collection of recipes, arranged by ingredient under broad,
       usually geographical categories.</p>
      </level1>
      </frontmatter>
      <bodymatter>
      <level1 class="chapter">
      <pagenum page="normal" id="ch3-43">43</pagenum>
      <h1>A Winter Menu</h1>
      <p>Winston Churchill was fond of saying that the Chinese ideogram for crisis
      is composed of the two characters which separately mean "danger" and
      "opportunity".</p>
      </level1>
      </bodymatter>
    

Example: page="special"

<bodymatter>
<level1 class="chapter">
<pagenum id="pt3-ch4-app1-1" page="special">W-1</pagenum>
<h1>Welcome to ClarisImpact</h1>
<p>ClarisImpact is a smart, integrated business graphics program that allows you to create, edit, and communicate attractive, professional - looking business graphics quickly and easily.</p>
. . .
<level2 class="section">
<pagenum id="pt3-ch4-app1-2" page="special">W-2</pagenum>
<h2>Onscreen Help</h2>
<p>ClarisImpact Help provides onscreen, step-by-step instructions and reference information as you work in ClarisImpact. You can easily search for topics and move from one topic to another. </p>
. . .
</level2>
. . .
</level1>
</bodymatter>

Example: page="normal" -- blank page

<bodymatter>
<level1 class="chapter">
<pagenum id="pt3-ch5" page="normal">104</pagenum>
<prodnote render="optional">blank page</prodnote>
</level1>
</bodymatter>

Information Object: Producer's Note

Definition: Language added to the DTB by the producing organization; commonly used to provide verbal descriptions of visual elements such as charts, graphs, etc., supply operating instructions, or describe differences between the print book and the DTB. Traditionally, this has been called a transcriber's note, reader's note, or editor's note.

Markup: Producer's notes are marked with the <prodnote> tag and must be identified as "required" or "optional" using the "render" attribute. Optional producer's notes may be turned on or off by the end user; that is, the playback device or browser includes settings that either automatically play all producer's notes as they are encountered or play only those marked as "required." The producer must decide for each <prodnote> whether it contains critical information and is thus marked as "required" or merely contains helpful information that an end user could skip without harm. If there's uncertainty whether to use the "optional" or "required" attribute, use "required".

The showin attribute can be used to control in which of three media types a given <prodnote> will be displayed. The allowable values for showin are xxx, xxp, xlx, xlp, bxx, bxp, blx, and blp, where x = inappropriate, b = braille, l = large print, and p = print. Thus the value "xlp" would prompt a player to display the prodnote in large print or print versions, but not in braille.

Note: See Information Object: Producer's Note in Part II(b): Block Elements for examples of <prodnote> used as a block element.

Syntax:

<prodnote render="required">..</prodnote>
or
<prodnote render="optional">..</prodnote>

New in DAISY/NISO, Release 2005: The "render" attribute is required, and must have a value of either "optional" or "required."

Example:

<p>The twenty-first century began in 1999. <prodnote render="optional">This sentence has been read exactly as it appears in the print book.</prodnote></p>

Information Object: Quotation

Definition: A quotation is a written passage drawn verbatim from another work. An inline (or text level) quotation is integrated into the text. This process is used for short quotations which don't require paragraph breaks. For longer quotations set off from surrounding text by paragraph breaks, see Block Structures Information Object: Quotation .

Markup: Inline or text level quotations are marked with the <q> element. (When quotation marks are used only for emphasis, rather than to indicate an actual quotation, no markup is necessary.)

Syntax:

<q>...</q>

Example:

<p>Sir Walter Scott said it best when he wrote, <q>"Oh, what a tangled web we weave, When first we practice to deceive!" </q>.</p>

Information Object: Sample

Definition: A sample of work created by the author and used as an example or template within the text.

Markup: Items that the author has placed in the text as sample work or examples to follow should be marked with the <samp> tag.

Syntax:

 
<samp>...</samp>

Example:

<p>The output of the above script would appear as follows on the screen: <samp>As of today, June 1, 2001, sales volume is 2,045,660 units per month.</samp> and the date and sales volume would be automatically updated.</p>

See also Information Object: Computer Code and Information Object: Keyboard Input


Information Object: Sentence

Definition: A grammatically self-contained unit that is usually smaller than a paragraph and larger than a single word.

Markup: Tagging of individual sentences would normally be done by a production tool (if at all), rather than by hand.

Syntax:

<sent>...</sent>

Example:

<p><sent>The disturbance which took place at Boston at the commencement of the revolutionary war, was at first considered only a riot; but it shortly began to assume a more formidable aspect.</sent> <sent>The insurgents were soon embodied throughout all the Colonies, and the insurrection became general.</sent> <sent>Between them and the loyal party no neutrality was allowed.</sent></p>

Information Object: Span

Definition: A generic tag to define a section of inline text. The <span> element can be used to tag one or more letters or words, a phrase, a sentence, or even a series of sentences, but not an entire paragraph, which comprises a block of text. (The <div> element is the generic counterpart to <span> for block use.) <span> is often used to mark inline text to which styles are to be applied. The class attribute may be used to provide detail on its use, as in the example below.

Markup: Use when no suitable tag exists for an unusual situation.

Syntax:

<span>...</span>

Assume the print book includes occasional letters or words that are printed in red, while the rest of the text is in black, and it is important for these letters to be identified as they are examples of typographical errors. The <span> tag could be used to mark these letters and identify them as errors.


Example:


<p>The most common errors are repeti<span class="typo">i</span>tions of letters and <span class="typo">and</span> words.</p>

Information Object: Strong Emphasis

See Information Object: Emphasis. A class attribute may be used to identify the degree of emphasis: <em class='x'>.


Information Object: Subscript and Superscript

Definition: Subscript and superscript characters are those, in 'Western scripts', written below or above 'normal' text, respectively.

Markup: These elements can be used recursively, that is you may use <sup> inside <sup>, for example; they can also be intermixed (e.g., <sub> inside <sup>).

Syntax:

<sub>...</sub> or <sup>...</sup>

Example 1:

<p>Scientists maintain that global warming is due primarily to an increase in atmospheric concentrations of CO<sub>2</sub>.</p>


Example 2:

<p>Perhaps the best-known formula of our day is Einstein's E=mc<sup>2</sup>.</p>


Example 3:

<p>As an example of recursive use, the expression e to the x squared would be rendered as: e<sup>x<sup>2</sup></sup>.</p>

Information Object: Word

Definition: A character or group of characters enclosed by two spaces.

Markup: This element can be used to mark each word in a digital talking book so that the audio and text files can be synchronized at the word level. Tagging of individual words would normally be done by a production tool (if at all), rather than by hand.

Syntax:

<w>...</w>

Example:

<p><sent><w>On</w> <w>the</w> <w>thirteenth</w> <w>of</w> <w>January</w>, <w>1422</w>, <w>the</w> <w>two</w> <w>armies</w> <w>met</w> <w>on</w> <w>a</w> <w>spacious</w> <w>plain</w> <w>near</w> <w>Kamnitz</w>.</sent> <sent><w>Zisca</w> <w>appeared</w> <w>in</w> <w>the</w> <w>centre</w> <w>of</w> <w>his</w> <w>front</w> <w>line</w>, <w>guarded</w>, <w>or</w> <w>rather</w> <w>conducted</w>, <w>by</w> <w>a</w> <w>horseman</w> <w>on</w> <w>each</w> <w>side</w>, <w>armed</w> <w>with</w> <w>a</w> <w>pole</w> <w>axe</w>.</sent></p>

Copyright 2005 DAISY Consortium