A footer can be printed on the Printer, Full Screen and HTML output destinations. The footer text can be set separately for all of these output destinations on their respective property pages in the Options Dialog.
The behavior of the footer is limited or changes in certain ways depending on the output destination, as follows:
When this box is checked, footers and page numbers will apply only to physical pieces of paper. That is, in the Two and Four Discrete Cells per Page layouts, only one footer will be printed, at the bottom of the page. Additionally, a physical piece of paper counts as just one page number.
When this box is not checked, footers and page numbers apply to each cell in the Two and Four Discrete Cells per Page layouts. This can be used to create a half-page-sized songbook; each cell receives its own footer and page number.The font and its style can be set in the printer Font Dialog. The text is automatically placed a small amount inside the top of the bottom margin area, and will wrap as needed.
<body>
.
Its appearance is controlled by the {sg_footer} style tag.
The page number (%p) and total number of pages (%n) control codes do not function
in this mode.Any text can be used, but the following control codes can also be used to format the footer:
Code | Description | Example Output |
---|---|---|
%l (lowercase 'L') | Left-justify text following (printer & full screen only) | |
%c | Center-justify text following (printer & full screen only) | |
%r | Right-justify text following (printer & full screen only) | |
%p | Current page number | |
%n | Total number of pages | |
%P | Current page number of song. | |
%N | Total number of pages of song. | |
%t | Song title | My Song |
%T | Song title, with subtitle, if it exists (in parenthesis) | My Song (Reprise) |
%s | Song subtitle. | Reprise |
%f | Song filename | my_song.txt |
%F | Song filename (complete path) | C:\songs\my_song.txt |
%x | Song transpose (in half-steps; if the value is zero: nothing, not even a blank, will be printed). | +3 |
%k | Song key (transposition will apply). | |
%k-n | nth key signature in the song (transposition will apply). | |
%dy | Two-digit representation of current year | 04 |
%dY | Four-digit representation of current year | 2004 |
%dm | Numeric representation of current month, with leading zeros | 01 to 12 |
%dn | Numeric representation of current month, without leading zeros | 1 to 12 |
%dM | Short textual representation of current month, three letters | Jan to Dec (localized) |
%dF | Full textual representation of current month | January to December (localized) |
%dd | Current day of the month, 2 digits, with leading zeros | 01 to 31 |
%dj | Current day of the month, 2 digits, without leading zeros | 1 to 31 |
%dD | Short textual representation of the current day of the week | Sun through Sat (localized) |
%dl (lowercase 'L') | Full textual representation of the current day of the week | Sunday through Saturday (localized) |
%dr | RFC 2822 formatted date | Thu, 21 Dec 2000 16:01:07 +0200 |
%’abc’ | Data key value (abc is a key; xyz, its value, will be printed). Note: the quotes are required! | |
%?jkl"xyz" | Value query jkl is a format code; if the value of jkl is not empty, then xyz will be evaluated and printed; xyz may contain nested format codes). Note: the quotes are required! | |
%?!jkl"xyz" | Value query (negative) jkl is a format code; if the value of jkl is empty, then xyz will be evaluated and printed; xyz may contain nested format codes). Note: the quotes are required! | |
%% | Percent sign ('%') |
Here are some examples of standard footer formatting:
Footer Text | Output Result |
---|---|
%cPage %p of %n | Page 3 of 5 (centered) |
%l%dy‑%dm‑%dd%cCCLI#666‑666%r(%f) |
04‑02‑20 (left‑justified) CCLI#666‑666 (centered) (my_song.txt) (right‑justified) |
|
The footer text is normally set in the Options Dialog, but it can be overridden on a per-song basis by adding a special directive to the song file, as follows:
{footer: xyz}
This directive will cause the footer text to always be set to xyz for the given song. The same footer syntax can be used in xyz as can be used in the footer in the Options Dialog.
If a song defines multiple key signatures, the various key signatures may be printed by
using the key signature code followed by a dash and the 1-based index of the key signature in the song:
%k-1
prints out the first key signature in the song,
%k-2
prints out the second key signature in the song, and so on.
%k-1
produces the same result as %k
.
The %?
and %?!
codes provide special functionality.
These codes will query the value that immediately follows them, and optionally print some footer text.
The code %?jkl"xyz"
%?!jkl"xyz"
will print the text xyz only if the value of jkl is empty.
Conditional formatting allows some interesting footers based on certain aspects of the song (for instance, transposition).
Here are some conditional formatting examples:
Footer Text | Output Result |
---|---|
%?x"Transpose: %x" | Transpose: +3 (if the transpose value is 3) |
(nothing—blank—if the transpose value is 0) | |
%?!x"Original key" | (nothing—blank—if the transpose value is 3) |
Original key (if the transpose value is 0) | |
%l%dy‑%dm‑%dd%cCCLI#666‑666%r(%f) |
04‑02‑20 (left‑justified) CCLI#666‑666 (centered) (my_song.txt) (right‑justified) |
|