Overview

The general layout of the scores generated by abcm2ps or abc2svg may be changed in many ways thanks to StyleSheet directives. These ones are named 'parameters' or 'commands' in the documentation.

Parameters inside ABC files

Parameters may be specified inside ABC tunes in one of two ways:
Pseudo-comments
These are lines starting with '%%'. The syntax is simply:
	%%parameter_name new_value
'I:' information field
This syntax permits the inclusion of parameters inside music lines. For example:
	CDEF | [I:annotationfont Arial 13] "^bla" GABc |
The keyword "lock" may appear at the end of a parameter value. After such a keyword has been found, the parameter will not be changed anymore unless "lock" appears again.

Parameters as command line arguments

Alternatively one or more format parameters may be specified directly as run time argument pairs using the following syntax: the first argument is the format parameter name preceded by two dashes (eg. --vocalfont) and the second argument is the new value.

If the value contains spaces, it should be enclosed by quotes when the program is run from a shell. For example, the following command will run abcjsc on the file myfile.abc changing the format parameter 'vocalfont' to 'sans-serif 13':

	abcjsc --vocalfont 'sans-serif 13' myfile.abc

The keyword "lock" is implicitly appended in the command line arguments so that these parameters take precedence and override any other changes.
Example:

	abcm2ps --vocalfont 'Arial 13' myfile.abc
in myfile.abc:
	%%vocalfont Times-Roman *		% <- ignored
	%%vocalfont Helvetica * lock		% <- vocalfont = 'Helvetica 13'

Parameters in format files (abcm2ps only)

A format file is a sequence of lines containing a pair of parameter name and the associated value(s) (no "%%" or "I:" prefix).
Empty lines and lines beginning with a '%' are ignored.

When running the program, one or more format files may be specified using the command line option '-F' (see the file options.txt).

Default parameters

By default, abcm2ps loads the format file default.fmt. This file is searched (in order) in:

By default, the command line scripts of abc2svg load the ABC file default.abc. This file is searched in the current directory only. There is no default parameter file in a web context.