.TH "ABCM2PS" "1" .SH "NAME" abcm2ps \(em translate ABC music notation to PostScript .SH "SYNOPSIS" .PP \fBabcm2ps\fR [\fIoptions\fR] [\fIabc-file\fR \fI[file-options]\fR] [...] .PP \fBabcm2ps\fR [\fB-h\fP] .SH "DESCRIPTION" .PP \fBabcm2ps\fR translates tunes written in the ABC music notation format to customary sheet music scores in PostScript. It is based on \fBabc2ps\fR 1.2.5 and was developed mainly to print Baroque organ scores that have independent voices played on multiple keyboards and a pedal-board. The program has since been extended to support various other notation conventions in use for sheet music. .PP Options given immediately after the command name apply to the run as a whole; options given after an ABC file name apply to that file. .PP Formatting parameters can also be set in `format files' and in the ABC files themselves. .SH "OPTIONS" .IP "\fB-0\fP" 10 Split tunes across page breaks if necessary. .IP "\fB+0\fP" 10 Start a new page if a tune doesn't fit on the current one (default). .IP "\fB-1\fP" 10 Output one tune per page. .IP "\fB+1\fP" 10 Output multiple tunes per page (default). .IP "\fB-a \fIa\fR\fP" 10 Maximal horizontal compression when staff breaks are chosen automatically. Must be between 0 and 1. This corresponds to the `\fB%%maxshrink\fP \fIa\fR' formatting parameter (default: 0.65) .IP "\fB-A\fP" 10 This option inserts reference elements in the PostScript or SVG output. .IP "\fB-B \fIb\fR\fP" 10 Try to typeset \fIb\fR bars on each staff line. This corresponds to the `\fB%%barsperstaff\fP \fIb\fR' formatting parameter. .IP "\fB+B\fP" 10 Don't try to typeset a fixed number of bars on each staff line (default). This corresponds to the `\fB%%barsperstaff\fP \fB0\fP' formatting parameter. .IP "\fB-b \fIb\fR\fP" 10 Start measure numbering at \fIb\fR. .IP "\fB-c\fP" 10 The continuation symbol is implicitly appended to each music line. This amounts to automatic line breaking. .IP "\fB+c\fP" 10 Automatic line breaking is turned off (default). .IP "\fB-D \fIdirectory\fR\fP" 10 Search format files in \fIdirectory\fR. .IP "\fB-d \fIlength\fR\fP" 10 Set the vertical interstaff space to \fIlength\fR. This corresponds to the `\fB%%staffsep\fP \fIlength\fR' formatting parameter (default: 46pt) .IP "\fB-E\fP" 10 Output is generated in EPS format, one file per page. .IP "\fB-e \fIlist\fR\fP" 10 Select which tunes from an ABC file to print. \fIlist\fR is either a comma-separated list of tune numbers (as per the `X:' header), or a regular expression which will be matched against the tune headers as a whole. The \fB-e\fP option must occur after an ABC file name and applies to that file. .IP "" 10 Ranges of tune numbers may be specified like \fIt1\fR-\fIt2\fR; \fIt2\fR may be omitted which means `all remaining tunes until the end of file'. Note that filtering may cause problems, e.g., with global (non-tune) definitions in the ABC file. .IP "\fB-F \fIfile\fR\fP" 10 Read the format file \fIfile\fR.fmt. .IP "\fB+F\fP" 10 Do not read the default format file. .IP "\fB-f\fP" 10 Enable flat beams (useful for bagpipe tunes). This corresponds to the `\fB%%flatbeams\fP \fB1\fP' formatting parameter. .IP "\fB-G\fP" 10 Omit slurs on grace notes. This corresponds to the `\fB%%graceslurs\fP \fB0\fP' formatting parameter. .IP "\fB+G\fP" 10 Draw slurs on grace notes (default). This corresponds to the `\fB%%graceslurs\fP \fB1\fP' formatting parameter. .IP "\fB-g\fP" 10 Produce SVG output instead of EPS. In this mode, each tune goes to a separate file whose name is `Out\fInnn\fR.svg' (see option \fB-O\fP). .IP "" 10 If output is directed to stdout (`\fB-O-\fP'), all SVG images are output without an XML header. .IP "\fB-H\fP" 10 Display the current values of the formatting parameters. .IP "\fB-h\fP" 10 Display program usage hints and quit. .IP "\fB-I \fIlength\fR\fP" 10 Indent the first line of the tune by \fIlength\fR (default: 0). This corresponds to the `\fB%%indent\fP \fIlength\fR' formatting parameter. .IP "\fB-i\fP, \fB+i\fP" 10 Insert a red circle around errors in the PostScript output. .IP "\fB-j\fIb\fR\fI[b]\fR\fP" 10 Output a measure number every \fIb\fR measures. If \fIb\fR is 0, the measure number appears at the left of each staff. The trailing \fBb\fP causes a box to be drawn around each measure number (default: no measure numbering). This corresponds to the \fB%%measurenb\fP formatting parameter. .IP "\fB+j\fP" 10 Don't output measure numbers. This corresponds to the `\fB%%measurenb\fP \fB-1\fP' formatting parameter. .IP "\fB-k\fP" 10 Sets the size of the PostScript output buffer in kibibytes. Specifying a higher value permits the generation of big tunes with \fB-E\fP or \fB-g\fP (default: 64). .IP "\fB-l\fP" 10 Generate landscape output. This corresponds to the `\fB%%landscape\fP \fB1\fP' formatting parameter. .IP "\fB+l\fP" 10 Generate portrait output (default). This corresponds to the `\fB%%landscape\fP \fB0\fP' formatting parameter. .IP "\fB-M\fP" 10 Suppress lyrics. See the \fB%%writefields\fP formatting parameter. .IP "\fB+M\fP" 10 Include lyrics (default). See the \fB%%writefields\fP formatting parameter. .IP "\fB-m \fIlength\fR\fP" 10 Set the left margin to \fIlength\fR (default: 1.8cm). This corresponds to the `\fB%%leftmargin\fP \fIlength\fR' formatting parameter. .IP "\fB-N\fI[mode]\fR\fP" 10 Number pages according to the \fImode\fR: .RS .IP "\fB0\fP" 10 no page numbers .IP "\fB1\fP" 10 page numbers at top left of page .IP "\fB2\fP" 10 page numbers at top right of page .IP "\fB3\fP" 10 page numbers at top left of even-numbered pages, top right of odd-numbered pages .IP "\fB4\fP" 10 page numbers at top right of even-numbered pages, top left of odd-numbered pages .RE .IP "" 10 For compatibility, \fB-N\fP is equivalent to \fB-N2\fP (default: \fB-N0\fP). .IP "" 10 If a header is defined using `\fB%%header\fP', this option is ignored. .IP "\fB+N\fP" 10 Equivalent to \fB-N0\fP (no page numbering). .IP "\fB-n\fP" 10 Include notes and history from ABC tune `N:' fields. See the \fB%%writefields\fP formatting parameter. .IP "\fB+n\fP" 10 Omit notes and history from ABC tune `N:' fields (default). See the \fB%%writefields\fP formatting parameter. .IP "\fB-O \fIname\fR\fP" 10 Define the output file name. By default, the output file name is `Out.ps' for PostScript output, `Out\fInnn\fR.eps' for EPS output (see \fB-E\fP), or `Out\fInnn\fR.svg' for SVG output (see \fB-g\fP), where \fInnn\fR is a sequence number. If this option is given, the output name will be \fIname\fR (for PostScript output), or \fIname\fR will replace `Out' in the output file name (for EPS and SVG output), respectively. If \fIname\fR is `=', the output file name will be the name of the ABC source file with the extension `.ps', `.eps', or `.svg'. If \fIname\fR is `\-', the output is written to stdout. .IP "\fB+O\fP" 10 Revert to the default output file name (`Out.ps' or `Out\fInnn\fR.eps') .IP "\fB-q\fP" 10 Quiet mode, only error messages will be shown. .IP "\fB-S\fP" 10 Secure mode; disables file inclusion via \fB%%format\fP and \fB%%EPS\fP and disallows direct PostScript injection via \fB%%beginps\fP and \fB%%postscript\fP. .IP "\fB-s \fIscale\fR\fP" 10 Set the page scale factor to \fIscale\fR. Note that the header and footer are not scaled (default: 0.75). This corresponds to the `\fB%%scale\fP \fIscale\fR' formatting parameter. .IP "\fB-T\fIn\fR[\fIvoice\fR]\fP, \fB+T\fIn\fR[\fIvoice\fR]\fP" 10 Activate (or deactivate) tabulature drawing. \fIn\fR is the tabulature number as defined in \fB%%tabulature\fP (up to a maximum of 8 tabulatures), and \fIvoice\fR is the voice name, full name or subname as found in \fBV:\fP. When this is absent, the option applies to all voices. Up to 4 such options may be given. See also \fBformat.txt\fP. .IP "\fB-V\fP" 10 Output version number and quit. .IP "\fB-v\fP" 10 Produce SVG output instead of simple PS. In this mode, each page goes to a separate output file called `Out\fInnn\fR.svg' (see option \fB-O\fP). .IP "\fB-w \fIlength\fR\fP" 10 Adjust the right margin such that the staff width is \fIlength\fR (default: none). This corresponds to the `\fB%%staffwidth\fP \fIlength\fR' formatting parameter. .IP "\fB-X\fP" 10 Produce XML+SVG output instead of simple PS. The default file name is `Out.xhtml' (see option `\-O'). .IP "\fB-x\fP" 10 Include the `X:' tune number in the title. See the \fB%%writefields\fP formatting parameter. .IP "\fB+x\fP" 10 Do not include the `X:' tune number in the title (default). See the \fB%%writefields\fP formatting parameter. .SH "FORMATTING PARAMETERS" .PP Abcm2ps supports a vast number of formatting parameters that govern the appearance of the typeset output. Please refer to the \fB/usr/share/doc/abcm2ps/format.txt\fP file or the formatting parameter documentation on the \fIofficial abcm2ps web site (link to URL http://moinejf.free.fr/abcm2ps-doc/index.html) \fR. .SH "ADDITIONAL FEATURES" .SS "Clefs" .PP Clefs can be given in \fBK:\fP and \fBV:\fP headers. The full syntax is .PP .nf [\fBclef=\fP]\fItype\fR[\fIline\fR][\fB+8\fP|\fB-8\fP] [\fBmiddle=\fP\fIpitch\fR] .fi .PP The `\fBclef=\fP' can be omitted when the \fItype\fR is a clef name. .PP \fItype\fR denotes the clef type. It may be: .IP "A note pitch (\fBG\fP, \fBC\fP, or \fBF\fP)" 10 The pitch indicates which clef is meant: \fBG\fP is the treble clef, \fBC\fP the alto clef and \fBF\fP the bass clef. It also gives the name of the note that appears on the clef's line. .IP "A clef name" 10 The available clef names are \fBtreble\fP (clef gives the pitch for \fBG\fP), \fBalto\fP or \fBtenor\fP (\fBC\fP), and \fBbass\fP (\fBF\fP) .IP "\fBperc\fP or \fBP\fP" 10 In percussion mode, accidentals change the glyphs used for note heads. By default, sharp notes are drawn as `x' and flat notes as circled `x'. This may be changed by redefining the PostScript functions \fBpshhd\fP and \fBpflhd\fP. .IP "\fBnone\fP" 10 No clef will be displayed. .PP The \fIline\fR gives the number of the line within the staff that the base clef will be written on. The default values are 2 for the treble clef, 3 for the alto clef, and 4 for the tenor and bass clefs. .PP The \fB+8\fP and \fB-8\fP options draw an 8 above or below the staff, respectively. `\fBmiddle=\fP\fIpitch\fR' (or `\fBm=\fP\fIpitch\fR', for short) is an alternative way of defining the line number of the clef: The \fIpitch\fR indicates what note will be displayed on the middle line of the staff. .PP When no clef is specified, clef changes between \fBbass\fP and \fBtreble\fP will be inserted automatically. .SS "Multi-voice typesetting" .PP Multiple voices may be defined within the header or the tune using .PP .nf \fBV:\fP\fIname\fR \fIdefinition\fR ... .fi .PP where \fIname\fR is a word consisting of letters and digits only (like \fBviolin1\fP). In the tune body, the following notes refer to this voice until another \fBV:\fP is encountered. A \fIdefinition\fR can be one of: .IP "\fBclef=\fP..." 10 See above .IP "\fBname=\fP\fIname\fR or \fBnm=\fP\fIname\fR" 10 The \fIname\fR will be displayed at the beginning of the first staff. It can contain \fB\\n\fP sequences which will force line breaks. If it contains whitespace it must be double-quoted. .IP "\fBsubname=\fP\fIname\fR or \fBsnm=\fP\fIname\fR" 10 The \fIname\fR will be displayed at the beginning of all staves except for the first. It can contain \fB\\n\fP sequences which will force line breaks. If it contains whitespace it must be double-quoted. .IP "\fBmerge\fP" 10 The voice goes on the same staff as the previous voice. .IP "\fBup\fP or \fBdown\fP" 10 Forces the direction of the stems for the voice. .IP "\fBdyn=up\fP or \fBdyn=down\fP or \fBdyn=auto\fP" 10 Forces positioning of dynamic marks (above or below the staff) or reverts to automatic positioning (the default) .IP "\fBgstem=up\fP or \fBgstem=down\fP or \fBgstem=auto\fP" 10 Forces the direction of the stems of grace notes (always up or always down) or reverts to automatic positioning (the default) .IP "\fBstem=auto\fP" 10 Reverts to automatic positioning of note stems (up or down) (the default) .IP "\fBlyrics=up\fP or \fBlyrics=down\fP or \fBlyrics=auto\fP" 10 Places lyrics above or below the staff or reverts to automatic positioning (the default) .IP "\fBgchord=up\fP or \fBgchord=down\fP" 10 Places guitar chords above (the default) or below the staff. .IP "\fBstafflines=\fP\fIvalue\fR" 10 Sets the number of lines on the staff in question. (default: 5) .IP "\fBstaffscale=\fP\fIvalue\fR" 10 Sets the scale of the associated staff up to 3. (default: 1) All other definitions are ignored. .PP By default, each voice goes on its own staff. The `%%staves \fIdefinition\fR' pseudo-comment can be used to control staff assignment. The \fIdefinition\fR consists of voice names (from \fBV:\fP) and pairs of parentheses, braces or brackets. .IP " \(bu" 6 When a voice name is not within a pair of special characters, it goes on a separate staff. .IP " \(bu" 6 For voice names enclosed in brackets, a bracket is displayed at the beginning of each line that joins the staves of the voices in question. .IP " \(bu" 6 For voice names enclosed in braces, all the voices go on two staves (keyboard score). There can be at most four voices between a single pair of braces. .IP " \(bu" 6 For voice names enclosed in parentheses, all the voices appear on a single staff. .PP The `\fB|\fP' character prevents measure bars from being drawn between two staves. .PP If `%%staves' occurs in a tune, all the voices not mentioned will not be output at all. .SS "The \fB%%score\fP directive" .PP The \fB%%score\fP directive occurs in the ABC draft 2.0 standard and is similar to the \fB%%staves\fP specification described earlier. The rules are: .IP " \(bu" 6 Voice names within parentheses form a "voice group" and go on a single staff. A voice name that is not within parentheses forms its own voice group and goes on a staff by itself. .IP " \(bu" 6 Voice groups within braces form a "voice block" and are preceded by a big brace in the output. This is especially useful for keyboard music. .IP " \(bu" 6 Voice groups or voice blocks within brackets form a "voice block" and will be preceded by a big bracket in the output. .IP " \(bu" 6 If a `\fB|\fP' character occurs between two voice groups or voice blocks, the bar lines in all of the associated staves will be continuous. .IP " \(bu" 6 A single voice surrounded by two voice groups can be preceded by an asterisk to make it into a `floating' voice. This means that, for each note of the voice, a separate decision is made whether it is printed on the preceding or the following voice group's staff. .IP " \(bu" 6 Voices that appear in the tune body but not in the \fB%%score\fP directive will not be output at all. If there is no \fB%%score\fP directive, each voice will be output on its own staff. .IP " \(bu" 6 A \fB%%score\fP directive inside a tune resets the mechanism so voices can be removed or added. .SS "Voice overlay" .PP You can add notes to a staff without introducing a complete extra voice by using the ampersand (\fB&\fP). A single measure can be split into two voices like .PP .nf |F2A2Bc&F2c2bc| .fi .PP The \fB(&...&...&)\fP construction allows splitting multiple measures: .PP .nf |!f!(&GG for the \fBDebian\fP system (but may be used by others). Permission is granted to copy, distribute and/or modify this document as long as its origin is not misrepresented. .\" created by instant / docbook-to-man, Sat 18 Oct 2014, 23:40