Kieren MacMillan <kieren_macmil...@sympatico.ca> writes: > Hi all, > >> Here is my solution. > > In general, I prefer to avoid using a markup, and override the stencil of the > grob instead, i.e., > > prallSharp = { > \once \override Script #'stencil = #ly:text-interface::print > \once \override Script #'text = \markup { > \override #'(baseline-skip . 1.2) \center-column { > \fontsize #-4 \sharp > \musicglyph #"scripts.prall" > } > } > } > > prallFlat = { > \once \override Script #'stencil = #ly:text-interface::print > \once \override Script #'text = \markup { > \override #'(baseline-skip . 1.2) \center-column { > \fontsize #-4 \flat > \musicglyph #"scripts.prall" > } > } > } > > \relative c' { > \prallSharp f4^\prall \prallFlat f4^\prall > } > > This means that I end up using the correct grob (in this case, Script), as > opposed to faking it with a markup (TextScript). However, I don't like the > extra effort of writing > > \prallSharp f4^\prall > > Can this be done with a simple > > f4^\prallSharp > > and still use Script (as I've done)?
prallSharp = \single \override Script #'stencil = #ly:text-interface::print \single \override Script #'text = \markup { \override #'(baseline-skip . 1.2) \center-column { \fontsize #-4 \sharp \musicglyph #"scripts.prall" } } \prall \relative c' { f4\prallSharp } Except that for inexplicable reasons, this complains about \prall unless you write it as #prall instead or use prallSharp = \single { \override Script #'stencil = #ly:text-interface::print \override Script #'text = \markup { \override #'(baseline-skip . 1.2) \center-column { \fontsize #-4 \sharp \musicglyph #"scripts.prall" } } } \prall \relative c' { f4\prallSharp } I have no idea currently what the syntax error for the first is about (raise a bug, someone). Of course, you can easily write the tweak version instead: prallSharp = -\tweak Script.text \markup { \override #'(baseline-skip . 1.2) \center-column { \fontsize #-4 \sharp \musicglyph #"scripts.prall" } } -\tweak Script.stencil #ly:text-interface::print \prall And you probably don't even need the Script. here, so it should be easy to make this work pre-2.17. -- David Kastrup _______________________________________________ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user