lilypond-user
[Top][All Lists]
Advanced

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

MetronomeMark customization


From: foxfanfare
Subject: MetronomeMark customization
Date: Fri, 11 Oct 2019 05:55:07 -0700 (MST)

Hi all,

I wanted to customize the default appearance of the MetronomeMark. I wrote
some little functions to achieve that and I used them a lot in my recent
works. 

But now, I have in mind to prepare a new style sheet for which I would like
to avoid as much as possible my customized function, but use instead the
orginial lilypond syntax with a corrected appearance. This kind of subject
has been discussed recently about the ottava marks:
http://lilypond.1069038.n5.nabble.com/ottava-signs-td224009.html

I would like to do the same now with MetronomeMarks. Here is the exemple to
demonstrate what I would like to achieve:

\version "2.19.82"

#(define-markup-command (metronomeText layout props text note number)
                          (string? string? string?)
    (interpret-markup layout props
      #{
         \markup {
           #text
           \hspace #0.25
           \medium {
             \general-align #Y #DOWN
             \fontsize #-4 \note #note #1
             \fontsize #-2 \sans \raise #0.2 =
             \hspace #-0.2
             \fontsize #-2 \bold #number
           }
         }
      #}))

\paper {

  % uncomment if you have Old Standard TT installed
  % Global Fonts
  %{
  #(define fonts
    (set-global-fonts
      #:roman "Old Standard TT"
  ))
  %}

  #(set-paper-size "a6")

}

\score {
  \relative c' {
    \tempo "Presto" 4 = 100
    c2^"default" e4 g
    c1
  }
}

\score {
  \relative c' {
    \tempo \markup \metronomeText "Presto" "4" "100"
    c2 e4 g
    c1
  }
}

metronome.pdf
<http://lilypond.1069038.n5.nabble.com/file/t5604/metronome.pdf>  

---

I personally change the roman font to Old Standard and the default result
for the MetronomeMark is quite ugly (in my opinion):
  1. The Metronome indication is too big
  2. I don't necessary like the parentheses and it should be set as an
option
  3. The note is too big. A traditional practice seems to keep the notehead
big and shorten the stem in order that it doesn't raise too far above the
text. 
  4. The equal sign is too big

That's the reason I tried to write the small function above "metronomeText"
but I would like to know if it is possible to incorporate this better in LP
code, which will allow the use of the standard \tempo command ? It would
also be possible for the midi to interpret it because now it cannot. This
force me to use two separate \tempo command, combined with specific tags,
one for the layout and one for the midi which is kind of annoying...

I looked in the .ly repertory but I wasn't able to find where those \tempo
shortcuts were defined... A little help would be muchly appreciated, thanks!



--
Sent from: http://lilypond.1069038.n5.nabble.com/User-f3.html



reply via email to

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