After I send out the email, I search LSR and found the solution. Thank you
very much for your help.
Blessing in+,
Ming.
>________________________________
> From: MING TSANG <[email protected]>
>To: Gilles <[email protected]>; David Nalesnik
><[email protected]>
>Cc: "[email protected]" <[email protected]>
>Sent: Monday, April 30, 2012 4:00:43 PM
>Subject: Re: lilypond-user Digest, Vol 113, Issue 99
>
>
>Thank you Gilles and David: One more thing - how to put a box or circle to
>the bar number that are now multiple of 5's?
>
>
>Blessing in+,
>
>
>>________________________________
>> From: Gilles <[email protected]>
>>To: David Nalesnik <[email protected]>; MING TSANG
>><[email protected]>
>>Cc: "[email protected]" <[email protected]>
>>Sent: Monday, April 30, 2012 3:21:21 PM
>>Subject: Re: lilypond-user Digest, Vol 113, Issue 99
>>
>>> Can I just print the multiple of fifth's (or 10's) only - the in between
>>> nar number should be blank?
>>
>>
>>%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
>>\version "2.15.37"
>>%%% solution 1
>>\relative c'' {
>> \override Score.BarNumber #'break-visibility = #'#(#f #t #t)
>> \override Score.BarNumber #'stencil =
>> #(lambda (grob)
>> (let* ((stil (ly:text-interface::print grob))
>> (text (ly:grob-property grob 'text))
>> (nmbr (string->number (markup->string text))))
>>
(if (= (remainder nmbr 5) 0)
>> (ly:grob-set-property! grob 'color red)
>> (ly:grob-suicide! grob))
>> stil))
>>
>> \repeat unfold 41 { c1 }
>>}
>>%%% solution 2 % easier
>>\relative c'' {
>> \override Score.BarNumber #'break-visibility = #'#(#f #t #t)
>> \set Score.barNumberVisibility = #(every-nth-bar-number-visible 5)
>> \override Score.BarNumber #'color = #red
>>
>> \repeat unfold 41 { c1 }
>>}
>>%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
>>
>>Gilles
>>
>>
>>
>
>_______________________________________________
lilypond-user mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/lilypond-user