lilypond-user
[Top][All Lists]
Advanced

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

Function for multiple tweaks


From: Andrew Bernard
Subject: Function for multiple tweaks
Date: Thu, 24 Jan 2019 22:51:32 +1100

I have many chords where a note is a harmonic. I use the following for the note inside the chord:

  \tweak NoteHead.stencil  #ly:text-interface::print
  \tweak NoteHead.font-size #1
  \tweak NoteHead.text #(markup #:musicglyph "noteheads.s0mi")

How can I make this into what I am tempted to call a macro (I know that is not lilypond terminology)?

I have always been confused about the dash '-' used with tweak, and when to use it and when not to. But my question is how to make this set of commands some osrt of function so I can just say \harmonicNote for example.

Doing this does not work:

harmonicNote = {
  \tweak NoteHead.stencil  #ly:text-interface::print
  \tweak NoteHead.font-size #1
  \tweak NoteHead.text #(markup #:musicglyph "noteheads.s0mi")
}

I am aware this is Dumb Question of the week, but something is stopping me seeing the answer.

Andrew



reply via email to

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