\layout {
\context {
\Score
- noteToFretFunction = #(determine-frets #t)
+ supportNonIntegerFret = ##t
}
}
Un @code{TabStaff} peut contenir des micro-intervalles tels les quarts
de ton, qui interveiennent dans les chutes ou sauts. L'assertion
-@w{@code{noteToFretFunction = #(determine-frets #t)}} devra se placer au
+@w{@code{supportNonIntegerFret = ##t}} devra se placer au
niveau du contexte @code{Score}. Les micro-intervalles ne sont
toutefois pas pris en charge dans un contexte @code{FretBoards}.
\layout {
\context {
\Score
- noteToFretFunction = #(determine-frets #t)
+ supportNonIntegerFret = ##t
}
}
@code{TabStaff} may support micro-tones like quarter-tones, which
can be played using bendings.
-@code{noteToFretFunction = #(determine-frets #t)} needs to be set in
+@code{supportNonIntegerFret = ##t} needs to be set in
Score-context. However, micro-tones are not supported in @code{FretBoards}.
@lilypond[quote,ragged-right,verbatim]
\layout {
\context {
\Score
- noteToFretFunction = #(determine-frets #t)
+ supportNonIntegerFret = ##t
}
}
\header {
texidoc = "The @code{TabStaff} will print micro-tones as mixed numbers of
fret-number and a fraction.
-@code{noteToFretFunction = #(my-determine-frets #t)} needs to be set in Score.
+The context-property @code{supportNonIntegerFret} needs to be set @code{#t}
+in @code{Score}-context.
@code{FretBoards} will print those micro-tones only if they can be found in the
chosen settings for @code{stringTunings}, otherwise a warning (surpressed here)
will be printed and an empty @code{FretBoard} returned. Which should be the
\layout {
\context {
\Score
- noteToFretFunction = #(determine-frets #t)
+ supportNonIntegerFret = ##t
}
}
\accepts "TabStaff"
\accepts "VaticanaStaff"
- %% (determine-frets #t) would support micro-tones
- noteToFretFunction = #(determine-frets)
+ noteToFretFunction = #determine-frets
predefinedDiagramTable = ##f
soloText = #"Solo"
soloIIText = #"Solo II"
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}.")
;; Create the dot-placement list for the grob
(set! (ly:grob-property grob 'dot-placement-list) placement-list)))
-(define*-public
- ((determine-frets #:optional (support-non-integer-fret? #f))
- context notes specified-info . rest)
+(define-public
+ (determine-frets context notes specified-info . rest)
"Determine string numbers and frets for playing @var{notes}
as a chord, given specified information @var{specified-info}.
@var{specified-info} is a list with two list elements,
@code{FretBoard} grob, and a fretboard will be
created. Otherwise, a list of @code{(string fret finger)} lists will
be returned.
-If the optional @var{support-non-integer-fret?} is set @code{#t}, micro-tones
-are supported for TabStaff, but not not for FretBoards."
+If the context-property @code{supportNonIntegerFret} is set @code{#t},
+micro-tones are supported for TabStaff, but not not for FretBoards."
;; helper functions
(and (or (and (not restrain-open-strings)
(zero? fret))
(>= fret minimum-fret))
- (if (and support-non-integer-fret? (null? rest))
+ (if (and
+ (ly:context-property context 'supportNonIntegerFret #f)
+ (null? rest))
(integer? (truncate fret))
(integer? fret))
(close-enough fret))))
(if (< this-fret 0)
(ly:warning (_ "Negative fret for pitch ~a on string ~a")
(car pitch-entry) string)
- (if (and (not (integer? this-fret)) (not support-non-integer-fret?))
+ (if (and
+ (not (integer? this-fret))
+ (not (ly:context-property context 'supportNonIntegerFret #f)))
(ly:warning (_ "Missing fret for pitch ~a on string ~a")
(car pitch-entry) string)))
(delete-free-string string)