Hi all,
I want to implement a function to display a modified barnumber in a box.
This is (can be) used in sketch edition to indicate that the barnumber
of the printed sketch doesn't match the one in the final composition.
This is what I came up with so far:
\version "2.19.37"
\layout {
\context {
\Score
\override BarNumber.break-visibility = ##(#t #t #t)
}
}
offsetBarnumber =
#(define-music-function (offset)(integer?)
#{
\override Score.BarNumber.stencil
= #(make-stencil-boxer 0.1 0.25 ly:text-interface::print)
#})
\relative g' {
\set Score.barNumberVisibility = #all-bar-numbers-visible
\bar ""
\repeat unfold 12 g4
\offsetBarnumber 2
\repeat unfold 12 g4
}
\offsetBarnumber will create the box.
But I don't have a clue how I can make the barnumber *print* a barnumber
that is offset by the argument. I do *not* want to change the
currentBarNumber as I would consider this semantically wrong.
Any hints or solutions appreciated
Thanks
Urs
PS: I don't seem to find how I can use the newer syntax for \override so
I don't have to use #{ #}
(override) is not defined so it must be some different approach
_______________________________________________
lilypond-user mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/lilypond-user