2015-01-22 2:09 GMT+01:00 tisimst <tisimst.lilyp...@gmail.com>: > I'd like to extract the current numerator and denominator of the time > signature at any point in time. How can I do this in scheme? A robust > solution (i.e., one that can handle compound time signatures) is always > preferred, but I can settle for "normal" time signatures with a single > numerator and denominator. > > Thanks, > Abraham
Maybe: \version "2.19.15" printTimeSignatureFraction = \applyContext #(lambda (ctx) (let* ((context (ly:context-property-where-defined ctx 'timeSignatureFraction)) (time-sig-frac (ly:context-property context 'timeSignatureFraction))) (display time-sig-frac))) \relative c' { \time 3/2 \printTimeSignatureFraction % => (3 . 2) c''1 \compoundMeter #'((1 4) (3 8)) \printTimeSignatureFraction % => (5 . 8) !! \repeat unfold 5 c8 \repeat unfold 10 c16 } Though the compound TimeSig will return "summarized" Cheers, Harm _______________________________________________ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user