Customization Precedence
Prev | Chapter 4. Customization | Next

## Customization Precedence

All the customization queries are translated to the corresponding command line options. Thus, using several customization methods can be unconsistent because each of them override the same option with another value.

For instance, you can specify the use of a specification file in which it is said to use a latex style (parameter TexStyle) and explicitely use the `--texstyle` command line option. So, what is the behaviour?

The options order is the following:

- If a specification file is used (`-S` option), the options are set to the specification file parameters.

- The options explicitely passed override the specification file setting, whatever is the position of the options (i.e. before or after the `-S` option).

- If an option is passed several times, this is the last occurence that is used.

Example 4.4. Customization Precedence

Let's consider the specification file containing the following parameters:

    XslParam: file3.xsl
    Options: -b pdftex
    TexStyle: mystyle1

And now the command line:

    dblatex -b dvips -p file1.xsl -p file2.xsl -S file.specs -s mystyle2 mydoc.xml

The setting used is the following:

- “-b dvips” overrides “-b pdftex” set by the spec file.

- “-p file2.xsl” overrides “-p file1.xsl” since it is defined after, and overrides “file3.xsl” set by the spec file.

- “-s mystyle2” override “mystyle1” set by the spec file.

Prev | Up | Next
Dblatex Configuration File | Home | Chapter 5. FAQ