Walt North <waltno...@gmail.com> writes: > ah = > #(define-music-function (sfrt note hfrt ) (number? ly:music? string? ) > #{ > % \harmonicByFret #sfrt g4\3 ^\markup { \center-align \teeny \concat {< > #hfrt > }} > \harmonicByFret #sfrt #note ^\markup { \center-align \teeny \concat {< > #hfrt > }} > #})
\harmonicByFret takes a possibly complex music expression and returns a definitely complex music expression. You cannot add a textscript with ^... to a complex music expression. You can get by here by writing \harmonicByFret #sfrt {#note ^\markup { \center-align \teeny \concat {< #hfrt > }}} This is not really pretty and works by first sweeping up #note and ^markup ... into a sequential music expression and combining them while doing so, then letting \harmonicByFret operate on that combined expression. If #note is already a complex music expression rather than a single note or rest (with possible post-events), then this will still fail. But it does not seem like this case would make a lot of sense anyway. -- David Kastrup