| DocBook: The Definitive Guide Version 2.0.7 (Alpha)

# lineannotation

$Revision: 1.3 $

$Date: 2002/06/12 11:18:16 $

lineannotation — A comment on a line in a verbatim listing

## Synopsis

### Mixed Content Model

    lineannotation ::=
    (#PCDATA|footnoteref|xref|abbrev|acronym|citation|citerefentry|
     citetitle|emphasis|firstterm|foreignphrase|glossterm|footnote|
     phrase|quote|trademark|wordasword|personname|link|olink|ulink|
     action|application|classname|methodname|interfacename|
     exceptionname|ooclass|oointerface|ooexception|command|
     computeroutput|database|email|envar|errorcode|errorname|
     errortype|errortext|filename|function|guibutton|guiicon|guilabel|
     guimenu|guimenuitem|guisubmenu|hardware|interface|keycap|keycode|
     keycombo|keysym|literal|constant|markup|medialabel|menuchoice|
     mousebutton|option|optional|parameter|prompt|property|
     replaceable|returnvalue|sgmltag|structfield|structname|symbol|
     systemitem|token|type|userinput|varname|nonterminal|anchor|
     author|authorinitials|corpauthor|modespec|othercredit|
     productname|productnumber|revhistory|remark|subscript|
     superscript|inlinegraphic|inlinemediaobject|inlineequation|
     synopsis|cmdsynopsis|funcsynopsis|classsynopsis|fieldsynopsis|
     constructorsynopsis|destructorsynopsis|methodsynopsis|indexterm|
     beginpage)*

### Attributes

Common attributes

## Description

A `LineAnnotation` is an author or editor's comment on a line in one of the verbatim environments. These are annotations added by the documentor, not part of the original listing.

### Processing expectations

Formatted inline. In verbatim environments like `ProgramListing`, which are often presented in a fixed width font, they may get special typographic treatment, such as italics.

If several `LineAnnotations` occur in the same listing, they may be aligned horizontally.

### Future Changes

The `InterfaceDefinition` element will be discarded in DocBook V4.0. It will no longer be available in the content model of this element.

### Parents

These elements contain lineannotation: `classsynopsisinfo`, `funcsynopsisinfo`, `literallayout`, `programlisting`, `rhs`, `screen`, `synopsis`.

### Children

The following elements occur in lineannotation: `abbrev`, `acronym`, `action`, `anchor`, `application`, `author`, `authorinitials`, `beginpage`, `citation`, `citerefentry`, `citetitle`, `classname`, `classsynopsis`, `cmdsynopsis`, `command`, `computeroutput`, `constant`, `constructorsynopsis`, `corpauthor`, `database`, `destructorsynopsis`, `email`, `emphasis`, `envar`, `errorcode`, `errorname`, `errortext`, `errortype`, `exceptionname`, `fieldsynopsis`, `filename`, `firstterm`, `footnote`, `footnoteref`, `foreignphrase`, `funcsynopsis`, `function`, `glossterm`, `guibutton`, `guiicon`, `guilabel`, `guimenu`, `guimenuitem`, `guisubmenu`, `hardware`, `indexterm`, `inlineequation`, `inlinegraphic`, `inlinemediaobject`, `interface`, `interfacename`, `keycap`, `keycode`, `keycombo`, `keysym`, `link`, `literal`, `markup`, `medialabel`, `menuchoice`, `methodname`, `methodsynopsis`, `modespec`, `mousebutton`, `nonterminal`, `olink`, `ooclass`, `ooexception`, `oointerface`, `option`, `optional`, `othercredit`, `parameter`, `personname`, `phrase`, `productname`, `productnumber`, `prompt`, `property`, `quote`, `remark`, `replaceable`, `returnvalue`, `revhistory`, `sgmltag`, `structfield`, `structname`, `subscript`, `superscript`, `symbol`, `synopsis`, `systemitem`, `token`, `trademark`, `type`, `ulink`, `userinput`, `varname`, `wordasword`, `xref`.

## See Also

`computeroutput`, `literallayout`, `programlisting`, `screen`, `screenshot`, `synopsis`, `userinput`.

## Examples

The following example, from the description of `Entry`, shows how `LineAnnotation` can be used to annotate a `Screen` listing:

    <!DOCTYPE screen PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
              "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
    <screen>
    &lt;entry>                <lineannotation>Error, cannot have a line break before a block element</lineannotation>
    &lt;para>
    A paragraph of text.
    &lt;/para>&lt;/entry>
    </screen>

    <entry>                Error, cannot have a line break before a block element
    <para>
    A paragraph of text.
    </para></entry>

For additional examples, see also `productionset`.

lineage |  | link

Copyright © 1999, 2000, 2001, 2002 O'Reilly & Associates, Inc. All rights reserved.