Next / Previous / Contents / TCC Help System / NM Tech homepage

6. Inline markup

DocBook has a number of elements that are useful for marking up content within a paragraph. By inline markup, we refer to tags that appear within a paragraph and do not change or interrupt its basic paragraph shape.

The tables below show numerous tags useful for inline markup.

ElementDescription
<citetitle>Used for citing works by their title. Example: “Have you read <citetitle>Ringworld</citetitle>?” would display as: “Have you read Ringworld?”
<emphasis>Used for emphasized text. Example: “Don't <emphasis>do</emphasis> that then” would appear as “Don't do that then.” For boldface, use <emphasis role="strong">.
<quote> For in-line quotations. Example: “As Carol Schaffer used to say, <quote>common sense isn't</quote>” would appear as: As Carol Schaffer used to say, “common sense isn't”.
<firstterm>Use this to tag the first occurrence of a new term or concept. Example: “We call it a <firstterm>major win</firstterm> when...” would display as: “We call it a major win when...”
<subscript>Displays the contents below the baseline. Example: “Drink more H<subscript>2</subscript>O.” would appear as: “Drink more H2O.”
<superscript>Displays the contents raised above the baseline. Example: “Celebrate the 4 <superscript>th</superscript> of July.” would appear as: “Celebrate the 4th of July.”
<computeroutput>Computer-generated output. Example: “ <computeroutput>OA210I OLD PSW WAS FF04230C 1200234B</computeroutput>” would display as: “OA210I OLD PSW WAS FF04230C 1200234B
<application>Names of packages. Example: “To start <application>emacs</application>...” would display as: “To start emacs...”
<filename>For file names and path names. Example: “Packages live in <filename>/fs/packages/</filename>.” would display as: “Packages live in /fs/packages.”
<guibutton> or <guiicon>Used for the labels of clickable icons or buttons in a graphical user interface. Example: “To exit, click on the <guibutton>Quit</guibutton> button.” would display as: “To exit, click on the Quit button.”
<guilabel>Used for names of windows in a graphical user interface. Example: “This brings up the <guilabel>Gronk and Die</guilabel> window.” would display as: “This brings up the Gronk and Die window.”
<guimenu>Used for items in a menu bar of a graphical user interface. Example: “Pull down the <guimenu>Team</guimenu> menu...” would display as: “Pull down the Team menu...”
<keysym>For names of keys. Example: “Press <keysym>Enter</keysym>...” would display as: “Press Enter...”
<replaceable>Use this tag for parts of a template or pattern that will are to be replaced with specific items in practice. Example: “Call your input file <filename> <replaceable>f</replaceable>.tex</filename>, where <replaceable>f</replaceable> is some name...” would display as: “Call your input file f.tex, where f is some name...”
<sgmltag>For the display of any XML tag. Use the attribute class="starttag" for a starting tag, and class="endtag" for an ending tag. Example: “Enclose the page title within <sgmltag class="starttag">title</sgmltag>...<sgmltag class="endtag">title</sgmltag> tags.” would display as: “Enclose the page title within <title>...</title> tags.”
<userinput>For commands or other user input. Example: “Type the command <userinput>make trouble</userinput> to ...” would display as: “Type the command make trouble to ...”
<varname>For variable names in programs. Example: “Add one to <varname>sheepCount</varname>.” would display as: “Add one to sheepCount.”