[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Time signatures at start of systems
From: |
Thomas Morley |
Subject: |
Re: Time signatures at start of systems |
Date: |
Wed, 10 Jul 2013 22:43:40 +0200 |
2013/7/10 Urs Liska <address@hidden>:
> Is there an easy way to automatically repeat the time signature at the
> beginning of each system?
> It should also work for ones with manual timesignaturefractions.
>
> TIA
> Urs
> --
> Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail gesendet.
Hi Urs,
currently I've not a proper solution.
Here some ideas.
Though, you need to insert manually the (redefined) \break or the
(redefined) pipeSymbol.
\version "2.16.2"
repeatTimeSignature =
\applyContext #(lambda (ctx)
(let* ((context
(ly:context-property-where-defined ctx 'timeSignatureFraction))
(time-sig-frac
(ly:context-property context 'timeSignatureFraction))
;; Use a copy of @var{time-sig-frac}, otherwise a new
;; @code{TimeSignature} wouldn't be printed.
(repeated-time-sig-frac
(ly:music-deep-copy time-sig-frac)))
(ly:context-set-property! context 'timeSignatureFraction
repeated-time-sig-frac)))
%% Redefine \break
break = {
#(make-music 'LineBreakEvent 'break-permission 'force) \repeatTimeSignature
}
\new Staff
\with {
\override TimeSignature #'break-visibility = ##(#f #t #t)
instrumentName = \markup \center-column { "redefined " "\\break" }
}
\relative c' {
\time 8/16
c2
d
\break
e
\time 16/32
f
\break
c
d
\break
e
f
}
%% Redefine the pipeSymbol (BarCheck)
pipeSymbol = { \break \repeatTimeSignature #(make-music 'BarCheck) }
\new Staff
\with {
\override TimeSignature #'break-visibility = ##(#f #t #t)
instrumentName = \markup \center-column { "redefined " "\\pipeSymbol " }
}
\relative c' {
\time 8/16
c2
d |
e2
\time 16/32
f |
c
d |
e
f
}
HTH a bit,
Harm