lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: formatting rehearsal marks


From: Thomas Morley
Subject: Re: formatting rehearsal marks
Date: Tue, 4 Sep 2012 21:31:24 +0200

2012/9/4 Xavier Scheuer <address@hidden>:
> On 4 September 2012 03:04, Jeffrey Trevino <address@hidden> wrote:
>> Hi there,
>>
>> I'm having trouble finding the correct overrides to change rehearsal mark
>> formatting. I'd like to change the font name used for the marks, as well as
>> the amount of white space between the number and the drawn circle or box (so
>> that there is more white space between the number or letter and the
>> enclosing shape). Has anyone done this before?
>
> Hi,
>
> I would say something like
>
>   \layout {
>     \context {
>       \Score
>       \override RehearsalMark #'font-name = #"Bitstream Charter"
>       \override RehearsalMark #'padding = #2
>     }
>   }
>
> HTH,
>
> Cheers,
> Xavier
>
> --
> Xavier Scheuer <address@hidden>
>
> _______________________________________________
> lilypond-user mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/lilypond-user

Try:

\version "2.16.0"

\layout {
  \context {
    \Score
    \override RehearsalMark #'font-name = #"Purisa"
  }
}

#(define (format-mark-rounded-box-letters mark context)
 (make-bold-markup
   (make-rounded-box-markup
     (make-pad-markup-markup 2
       (make-markletter-markup
         (1- mark))))))

#(define-public (format-mark-rounded-box-numbers mark context)
  (make-bold-markup
    (make-rounded-box-markup
      (make-pad-markup-markup 2
        (number->string mark)))))

\relative c' {
\set Score.markFormatter = #format-mark-rounded-box-letters
c1 \mark \default
c1 \mark \default
c1 \mark \default
c1 \mark \default
c1
}

\relative c' {
\set Score.markFormatter = #format-mark-rounded-box-numbers
c1 \mark \default
c1 \mark \default
c1 \mark \default
c1 \mark \default
c1
}


You should adjust the number in `make-pad-markup-markup 2'

See also:
http://lilypond.1069038.n5.nabble.com/Default-Rehearsal-Mark-td55008.html#a55010

Examples of the default-code are to be found in /scm/translation-functions.scm


HTH,
  Harm



reply via email to

[Prev in Thread] Current Thread [Next in Thread]