X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=scm%2Fdefine-context-properties.scm;h=04b57afaceef21496507df5ab01a7a0d8ae9a759;hb=HEAD;hp=1aaf582cd724d352a87a6e8ace5210bec26992b3;hpb=01df8ad908c92687d0c352e5ad5f067e52809423;p=lilypond.git diff --git a/scm/define-context-properties.scm b/scm/define-context-properties.scm index 1aaf582cd7..04b57aface 100644 --- a/scm/define-context-properties.scm +++ b/scm/define-context-properties.scm @@ -1,6 +1,6 @@ ;;;; This file is part of LilyPond, the GNU music typesetter. ;;;; -;;;; Copyright (C) 1998--2012 Han-Wen Nienhuys +;;;; Copyright (C) 1998--2015 Han-Wen Nienhuys ;;;; Jan Nieuwenhuizen ;;;; ;;;; LilyPond is free software: you can redistribute it and/or modify @@ -21,14 +21,14 @@ (define (translator-property-description symbol type? description) (if (not (and - (symbol? symbol) - (procedure? type?) - (string? description))) + (symbol? symbol) + (procedure? type?) + (string? description))) (throw 'init-format-error)) (if (not (equal? #f (object-property symbol 'translation-doc))) - (ly:error (_ "symbol ~S redefined" symbol))) + (ly:error (_ "symbol ~S redefined") symbol)) (set-object-property! symbol 'translation-type? type?) (set-object-property! symbol 'translation-doc description) @@ -44,7 +44,13 @@ ;; TODO FIXME + (accidentalGrouping ,symbol? "If set to @code{'voice}, accidentals +on the same note in different octaves may be horizontally staggered +if in different voices.") (aDueText ,markup? "Text to print at a unisono passage.") + (additionalBassStrings ,list? "The additional tablature bass-strings, which +will not get a seprate line in TabStaff. It is a list of the pitches of each +string (starting with the lowest numbered one).") (additionalPitchPrefix ,string? "Text with which to prefix additional pitches within a chord name.") (alignAboveContext ,string? "Where to insert newly created context in @@ -57,7 +63,13 @@ vertical alignment.") numbers. Can be @code{numbers} for going back to the same number or @code{numbers-with-letters} for going back to the same number with letter suffixes. No setting will not go back in measure-number time.") - (associatedVoice ,string? "Name of the @code{Voice} that has the + (alternativeRestores ,symbol-list? "Timing variables that are +restored to their value at the start of the first alternative in +subsequent alternatives.") + (associatedVoice ,string? "Name of the context (see +@code{associatedVoiceType} for its type, usually @code{Voice}) that +has the melody for this @code{Lyrics} line.") + (associatedVoiceType ,symbol? "Type of the context that has the melody for this @code{Lyrics} line.") (autoAccidentals ,list? "List of different ways to typeset an accidental. @@ -129,16 +141,44 @@ number, measure position, and alternative number and returns a markup of the bar number to print.") (barNumberVisibility ,procedure? "A procedure that takes a bar number and a measure position and returns whether the corresponding -bar number should be printed.") +bar number should be printed. Note that the actual print-out of +bar numbers is controlled with the @code{break-visibility} property. + +The following procedures are predefined: + +@table @code +@item all-bar-numbers-visible +Enable bar numbers for all bars, including the first one and broken +bars (which get bar numbers in parentheses). + +@item first-bar-number-invisible +Enable bar numbers for all bars (including broken bars) except the +first one. If the first bar is broken, it doesn't get a bar number +either. + +@item first-bar-number-invisible-save-broken-bars +Enable bar numbers for all bars (including broken bars) except the +first one. A broken first bar gets a bar number. + +@item first-bar-number-invisible-and-no-parenthesized-bar-numbers +Enable bar numbers for all bars except the first bar and broken bars. +This is the default. + +@item (every-nth-bar-number-visible @var{n}) +Assuming @var{n} is value@tie{}2, for example, this enables bar numbers +for bars 2, 4, 6, etc. + +@item (modulo-bar-number-visible @var{n} @var{m}) +If bar numbers 1, 4, 7, etc., should be enabled, @var{n}@tie{}(the modulo) +must be set to@tie{}3 and @var{m}@tie{}(the division remainder) to@tie{}1. +@end table") + (baseMoment ,ly:moment? "Smallest unit of time that will stand on its own as a subdivided section.") (bassFigureFormatFunction ,procedure? "A procedure that is called to produce the formatting for a @code{BassFigure} grob. It takes a list of @code{BassFigureEvent}s, a context, and the grob to format.") - (bassStaffProperties ,list? "An alist of property settings to -apply for the down staff of @code{PianoStaff}. Used by -@code{\\autochange}.") (beamExceptions ,list? "An alist of exceptions to autobeam rules that normally end on beats.") (beamHalfMeasure ,boolean? "Whether to allow a beam to begin @@ -169,17 +209,29 @@ symbol and the prefix of a chord name.") (chordRootNamer ,procedure? "A function that converts from a pitch object to a text markup. Used for chords.") (clefGlyph ,string? "Name of the symbol within the music font.") - (clefOctavation ,integer? "Add this much extra octavation. + (clefTransposition ,integer? "Add this much extra transposition. Values of 7 and -7 are common.") - (clefOctavationFormatter ,procedure? "A procedure that takes the -Octavation number as a string and the style as a symbol and returns a markup.") - (clefOctavationStyle ,symbol? "Determines the way the octavateEight + (clefTranspositionFormatter ,procedure? "A procedure that takes the +Transposition number as a string and the style as a symbol and returns a +markup.") + (clefTranspositionStyle ,symbol? "Determines the way the ClefModifier grob is displayed. Possible values are @samp{default}, @samp{parenthesized} and @samp{bracketed}.") (clefPosition ,number? "Where should the center of the clef symbol go, measured in half staff spaces from the center of the staff.") (completionBusy ,boolean? "Whether a completion-note head is playing.") + (completionFactor ,rational-or-procedure? +"When @code{Completion_heads_engraver} and +@code{Completion_rest_engraver} need to split a note or rest with a +scaled duration, such as @code{c2*3}, this specifies the scale factor +to use for the newly-split notes and rests created by the engraver. + +If @code{#f}, the completion engraver uses the scale-factor of +each duration being split. + +If set to a callback procedure, that procedure is called with the +context of the completion engraver, and the duration to be split.") (completionUnit ,ly:moment? "Sub-bar unit of completion.") (connectArpeggios ,boolean? "If set, connect arpeggios across piano staff.") @@ -195,11 +247,12 @@ a hairpin crescendo is used.") (crescendoText ,markup? "The text to print at start of non-hairpin crescendo, i.e., @samp{cresc.}.") (cueClefGlyph ,string? "Name of the symbol within the music font.") - (cueClefOctavation ,integer? "Add this much extra octavation. + (cueClefTransposition ,integer? "Add this much extra transposition. Values of 7 and -7 are common.") - (cueClefOctavationFormatter ,procedure? "A procedure that takes the -Octavation number as a string and the style as a symbol and returns a markup.") - (cueClefOctavationStyle ,symbol? "Determines the way the octavateEight + (cueClefTranspositionFormatter ,procedure? "A procedure that +takes the Transposition number as a string and the style as a symbol +and returns a markup.") + (cueClefTranspositionStyle ,symbol? "Determines the way the ClefModifier grob is displayed. Possible values are @samp{default}, @samp{parenthesized} and @samp{bracketed}.") (cueClefPosition ,number? "Where should the center of the clef @@ -232,8 +285,8 @@ slurred note, one above and one below the chord.") instruments (symbols) to pitches.") (drumStyleTable ,hash-table? "A hash table which maps drums to layout settings. Predefined values: @samp{drums-style}, -@samp{timbales-style}, @samp{congas-style}, @samp{bongos-style}, and -@samp{percussion-style}. +@samp{agostini-drums-style}, @samp{timbales-style}, @samp{congas-style}, +@samp{bongos-style}, and @samp{percussion-style}. The layout style is a hash table, containing the drum-pitches (e.g., the symbol @samp{hihat}) as keys, and a list @@ -250,8 +303,8 @@ function for clef changes.") function for cue clef changes.") (explicitKeySignatureVisibility ,vector? "@samp{break-visibility} function for explicit key changes. @samp{\\override} of the -@code{break-visibility} property will set the visibility for normal -(i.e., at the start of the line) key signatures.") +@code{break-visibility} property will set the visibility for +normal (i.e., at the start of the line) key signatures.") (extendersOverRests ,boolean? "Whether to continue extenders as they cross a rest.") (extraNatural ,boolean? "Whether to typeset an extra natural sign @@ -286,10 +339,12 @@ containing, in the correct order, the labels to be used for lettered frets in tablature.") - (glissandoMap ,list? "A map in the form of '((source1 . target1) -(source2 . target2) (sourcen . targetn)) showing the glissandi to -be drawn for note columns. The value '() will default to '((0 . 0) -(1 . 1) (n . n)), where n is the minimal number of note-heads in + (glissandoMap ,list? "A map in the form of +'((source1 . target1) (source2 . target2) (sourcen . targetn)) +showing the glissandi to be drawn for note columns. +The value '() will default to +'((0 . 0) (1 . 1) (n . n)), +where n is the minimal number of note-heads in the two note columns between which the glissandi occur.") (gridInterval ,ly:moment? "Interval for which to generate @code{GridPoint}s.") @@ -315,23 +370,22 @@ string selector for tablature notation.") @rinternals{Lyrics} line.") (implicitBassFigures ,list? "A list of bass figures that are not printed as numbers, but only as extender lines.") - (implicitTimeSignatureVisibility ,vector? "break visibility for -the default time signature.") + (initialTimeSignatureVisibility ,vector? "break visibility for +the initial time signature.") (includeGraceNotes ,boolean? "Do not ignore grace notes for @rinternals{Lyrics}.") (instrumentCueName ,markup? "The name to print if another instrument is to be taken.") - (instrumentEqualizer ,procedure? "A function taking a string -(instrument name), and returning a @code{(@var{min} . @var{max})} pair -of numbers for the loudness range of the instrument.") + (instrumentEqualizer ,procedure? "A function taking a +string (instrument name), and returning a @code{(@var{min} . @var{max})} +pair of numbers for the loudness range of the instrument.") (instrumentName ,markup? "The name to print left of a staff. The @code{instrumentName} property labels the staff in the first system, and the @code{shortInstrumentName} property labels following lines.") - ;; the definition is reversed wrt traditional transposition - ;; otherwise \transpose { \transposition .. } won't work (instrumentTransposition ,ly:pitch? "Define the transposition of -the instrument. Its value is the pitch that sounds like middle@tie{}C. -This is used to transpose the MIDI output, and @code{\\quote}s.") +the instrument. Its value is the pitch that sounds when the instrument +plays written middle C. This is used to transpose the MIDI output, +and @code{\\quote}s.") (internalBarNumber ,integer? "Contains the current barnumber. This property is used for internal timekeeping, among others by the @code{Accidental_engraver}.") @@ -341,14 +395,16 @@ This property is used for internal timekeeping, among others by the interfaces that are worth keeping a staff with @code{remove-empty} set around for.") (keyAlterationOrder ,list? "An alist that defines in what order -alterations should be printed. The format is @code{(@var{step} -. @var{alter})}, where @var{step} is a number from 0 to@tie{}6 and +alterations should be printed. The format is +@code{(@var{step} . @var{alter})}, +where @var{step} is a number from 0 to@tie{}6 and @var{alter} from -2 (sharp) to 2 (flat).") - (keySignature ,list? "The current key signature. This is an alist -containing @code{(@var{step} . @var{alter})} or @code{((@var{octave} . -@var{step}) . @var{alter})}, where @var{step} is a number in the range -0 to@tie{}6 and @var{alter} a fraction, denoting alteration. For -alterations, use symbols, e.g. @code{keySignature = #`((6 . ,FLAT))}.") + (keyAlterations ,list? "The current key signature. This is an alist +containing @code{(@var{step} . @var{alter})} or +@code{((@var{octave} . @var{step}) . @var{alter})}, where @var{step} +is a number in the range 0 to@tie{}6 and @var{alter} a fraction, +denoting alteration. For alterations, use symbols, e.g. +@code{keyAlterations = #`((6 . ,FLAT))}.") (lyricMelismaAlignment ,number? "Alignment to use for a melisma syllable.") @@ -393,7 +449,27 @@ event when notes with the same pitch, in the same MIDI-file track, overlap.") @code{midiMinimumVolume}.") (midiMinimumVolume ,number? "Set the minimum loudness for MIDI. Ranges from 0 to@tie{}1.") - (midiChannelMapping ,symbol? "How to map MIDI channels: per @code{instrument} (default), @code{staff} or @code{voice}.") + (midiChannelMapping ,symbol? "How to map MIDI channels: per +@code{staff} (default), @code{instrument} or @code{voice}.") + (midiBalance ,number? "Stereo balance for the MIDI channel +associated with the current context. Ranges from@tie{}@w{-1} to@tie{}1, +where the values@tie{}@w{-1} (@code{#LEFT}),@tie{}0 (@code{#CENTER}) +and@tie{}1 (@code{#RIGHT}) correspond to leftmost emphasis, center +balance, and rightmost emphasis, respectively.") + (midiPanPosition ,number? "Pan position for the MIDI channel +associated with the current context. Ranges from@tie{}@w{-1} to@tie{}1, +where the values@tie{}@w{-1} (@code{#LEFT}),@tie{}0 (@code{#CENTER}) +and@tie{}1 (@code{#RIGHT}) correspond to hard left, center, and hard +right, respectively.") + (midiExpression ,number? "Expression control for the MIDI +channel associated with the current context. Ranges from 0 +to@tie{}1 (0=off,@tie{}1=full effect).") + (midiReverbLevel ,number? "Reverb effect level for the MIDI +channel associated with the current context. Ranges from 0 +to@tie{}1 (0=off,@tie{}1=full effect).") + (midiChorusLevel ,number? "Chorus effect level for the MIDI +channel associated with the current context. Ranges from 0 +to@tie{}1 (0=off,@tie{}1=full effect).") (minimumFret ,number? "The tablature auto string-selecting mechanism selects the highest string with a fret at least @code{minimumFret}.") @@ -411,7 +487,10 @@ ChordNames context.") defined strings to full list of strings and fret numbers. Parameters: The context, a list of note events, a list of tabstring events, and the fretboard grob if a fretboard is desired.") - + (nullAccidentals ,boolean? "The @code{Accidental_engraver} +generates no accidentals for notes in contexts were this is set. +In addition to supressing the printed accidental, this option removes +any effect the note would have had on accidentals in other voices.") (ottavation ,markup? "If set, the text for an ottava spanner. Changing this creates a new text spanner.") @@ -419,6 +498,9 @@ Changing this creates a new text spanner.") translator during music interpretation.") + (partCombineForced ,symbol? "Override for the partcombine +decision. Can be @code{apart}, @code{chords}, @code{unisono}, +@code{solo1}, or @code{solo2}.") (partCombineTextsOnNote ,boolean? "Print part-combine texts only on the next note rather than immediately on rests or skips.") (pedalSostenutoStrings ,list? "See @code{pedalSustainStrings}.") @@ -492,6 +574,8 @@ part-combining.") @rinternals{Pitch_squash_engraver}.") (staffLineLayoutFunction ,procedure? "Layout of staff lines, @code{traditional}, or @code{semitone}.") + (magnifyStaffValue ,positive? "The most recent value set with +@code{\\magnifyStaff}.") (stanza ,markup? "Stanza @q{number} to print before the start of a verse. Use in @code{Lyrics} context.") (startRepeatSegnoType ,string? "Set the default bar line for the @@ -517,6 +601,8 @@ one).") subdivided at @code{baseMoment} positions by only drawing one beam over the beat.") (suggestAccidentals ,boolean? "If set, accidentals are typeset as cautionary suggestions over the note.") + (supportNonIntegerFret ,boolean? "If set in @code{Score} the +@code{TabStaff} will print micro-tones as @samp{2½}") (systemStartDelimiter ,symbol? "Which grob to make for the start of the system/@/staff? Set to @code{SystemStartBrace}, @code{SystemStartBracket} or @code{SystemStartBar}.") @@ -549,11 +635,6 @@ position, bar number, etc.? Switch off for cadenzas.") (topLevelAlignment ,boolean? "If true, the @var{Vertical_align_engraver} will create a @var{VerticalAlignment}; otherwise, it will create a @var{StaffGrouper}") - (trebleStaffProperties ,list? "An alist of property settings to -apply for the up staff of @code{PianoStaff}. Used by -@code{\\autochange}.") - (tremoloFlags ,integer? "The number of tremolo flags to add if no -number is specified.") (tupletFullLength ,boolean? "If set, the tuplet is printed up to the start of the next note.") (tupletFullLengthNote ,boolean? "If set, end at the next note, @@ -592,6 +673,8 @@ Example: @noindent This will create a start-repeat bar in this staff only. Valid values are described in @file{scm/bar-line.scm}.") + (suspendRestMerging ,boolean? "When using the Merge_rest_engraver do not + merge rests when this is set to true.") ))) @@ -602,7 +685,6 @@ are described in @file{scm/bar-line.scm}.") (apply translator-property-description x)) `( - (EventClasses ,cheap-list? "The initial list of event classes.") (associatedVoiceContext ,ly:context? "The context object of the @code{Voice} that has the melody for this @code{Lyrics}.") @@ -636,14 +718,17 @@ proceeding to next time step. This is an internal variable.") should be manipulated through the @code{add-grace-property} function.") + (hasAxisGroup ,boolean? "True if the current context is contained +in an axis group.") (hasStaffSpacing ,boolean? "True if the current @code{CommandColumn} contains items that will affect spacing.") - (lastKeySignature ,list? "Last key signature before a key + (lastChord ,markup? "Last chord, used for detecting chord changes.") + (lastKeyAlterations ,list? "Last key signature before a key signature change.") - (localKeySignature ,list? "The key signature at this point in the -measure. The format is the same as for @code{keySignature}, but can + (localAlterations ,list? "The key signature at this point in the +measure. The format is the same as for @code{keyAlterations}, but can also contain @code{((@var{octave} . @var{name}) . (@var{alter} @var{barnumber} . @var{measureposition}))} pairs.") @@ -653,6 +738,9 @@ This can be used to signal melismas on top of those automatically detected.") + (partialBusy ,boolean? "Signal that \\partial acts at the current timestep.") + + (quotedCueEventTypes ,list? "A list of symbols, representing the event types that should be duplicated for @code{\\cueDuring} commands.") (quotedEventTypes ,list? "A list of symbols, representing the @@ -676,7 +764,7 @@ and subscripts. See @file{scm/@/script.scm} for more information.") (define-public all-translation-properties (append all-user-translation-properties - all-internal-translation-properties)) + all-internal-translation-properties)) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;