8.1.5 Including typographic tags and character formats

Many configuration settings allow you to specify text values that will appear in output. You can surround the text with any character format (including formats not defined elsewhere; DITA2Go defines them), or with one or more of the following typographic tags: 

b

Bold

i

Italic

q

Quote

u

Underline

tt

Monospace

sup

Superscript

sub

Subscript

You can use typographic tags in the definitions of format components, and also in settings in the Languages configuration files. Most text-value configuration settings are included in each of the language configuration files, where they have default values appropriate to the language in question; see §8.9 Localizing output headings, labels, and names.

And you can nest tags. For example:

[StopHead]
form = <b><i>Stop!</i></b>

DITA2Go automatically terminates any typographic tag at the end of the text, unless you terminate it earlier with a closing tag.

You can also define a character format and use its name in the definition of a format component. For example, in a Formats configuration file:

[Attention]
based = char
font weight = bold
font style = italic

And in a Subformats configuration file:

[StopHead]
form = <Attention>Stop!</Attention>

You can mix format tags and typographic tags in the same format component definition; however, best practice is to assign the typographic tags to the format itself.

Note:  Do not try to assign more than one <format> tag to a format component.

Quote styles

To specify quote styles for the <q> typographic element, in a language configuration file:

[ElementText]
; Quotes = left double, right double, left single, and right single,
; in a space-delimited list, for <q> element, nested alternately.
Quotes= “ ” ‘ ’

DITA2Go recognizes either the Windows code page or the UTF-8 characters. Quote characters are inserted literally in the encoding specified for the output type. Default values for quote characters are provided in each of the language configuration files; see §8.5 Configuring output numbering properties. The values shown here are the default values specified in d2g_lang_en.ini. You can override the default values in a general configuration file.

Previous Topic:  8.1.4 Understanding format-component name lookups

Next Topic:  8.2 Defining border format components

Parent Topic:  8.1 Managing format components

Sibling Topics:

8.1.1 Understanding where to define format components

8.1.2 Basing format component properties on other components

8.1.3 Assigning additional names to format components

8.1.4 Understanding format-component name lookups

Table of ContentsIndex