;; This works for single-note and multi-note tremolos!
(let* ((children (if (music-is-of-type? main 'sequential-music)
;; \repeat tremolo n { ... }
- (length (ly:music-property main 'elements))
+ (length (extract-named-music main 'EventChord))
;; \repeat tremolo n c4
1))
;; # of dots is equal to the 1 in bitwise representation (minus 1)!
(define (calc-repeat-slash-count music)
"Given the child-list @var{music} in @code{PercentRepeatMusic},
calculate the number of slashes based on the durations. Returns @code{0}
-if durations in in @var{music} vary, allowing slash beats and double-percent
+if durations in @var{music} vary, allowing slash beats and double-percent
beats to be distinguished."
(let* ((durs (map (lambda (elt)
(duration-of-note elt))
Slur
Stem
TextScript
- Tie))
+ Tie
+ TupletBracket))
(define-safe-public (make-voice-props-set n)
(make-sequential-music
(equal? laziness #t)
(<= bar-number (+ (cadr alteration-def) laziness))))
-(define (accidental-voided? alteration-def)
- "Checks an alteration entry for being voided.
+(define (accidental-invalid? alteration-def)
+ "Checks an alteration entry for being invalid.
-Non-key alterations are voided when tying into the next bar or when
-there is a clef change, since neither repetition nor cancellation can
-be omitted when the same note occurs again.
+Non-key alterations are invalidated when tying into the next bar or
+when there is a clef change, since neither repetition nor cancellation
+can be omitted when the same note occurs again.
-Returns @code{#f} or the reason for the voiding, a symbol."
+Returns @code{#f} or the reason for the invalidation, a symbol."
(let* ((def (if (pair? alteration-def)
(car alteration-def)
alteration-def)))
(from-key-sig
(set! previous-alteration from-key-sig)))
- (if (accidental-voided? previous-alteration)
+ (if (accidental-invalid? previous-alteration)
(set! need-accidental #t)
(let* ((prev-alt (extract-alteration previous-alteration))
(begin
(set! need-accidental #t)
(if (and (not (= this-alt 0))
- (or (< (abs this-alt) (abs prev-alt))
- (< (* prev-alt this-alt) 0)))
+ (and (< (abs this-alt) (abs prev-alt))
+ (> (* prev-alt this-alt) 0)))
(set! need-restore #t))))))
(cons need-restore need-accidental)))
(lambda (entry)
(let* ((localalt (key-entry-alteration entry))
(localoct (key-entry-octave entry)))
- (if (or (accidental-voided? localalt)
+ (if (or (accidental-invalid? localalt)
(not localoct)
(= localalt
(key-entry-alteration