Kieren MacMillan <kieren_macmil...@sympatico.ca> writes:

> Hi David,
>
>> Uh, a markuplist typically _is_ a list of markups.  Except when it isn't
>> (like when it is the result of calling a markup list command).  But when
>> it isn't, you can only turn it into a list of stencils.
>
> Hmmm… So in my function
>
> #(define-markup-list-command (diffints layout props mus) (ly:music?)
>    (interpret-markup-list layout props
>      (map (lambda (d) (if (zero? d) "0" (format #f "~@d" d)))
>        (let ((muspst (map ly:pitch-semitones (music-pitches mus))))
>          (map - (cdr muspst) muspst)))))
>
> how can I output something where I can throw it into a Lyrics context and 
> have it spaced out one element per note?

Oh.  One element per note is tricky.  How about making this a music
function instead that outputs lyrics?

diffints =
#(define-music-function (mus) (ly:music?)
  #{ \lyricmode { $@(map ...) } #})

That's what I can suggest for now.  But that request seems legitimate
enough that I'll see what it takes to make lyricmode accept a markup
list.  You'd use it presumably as

\markuplist [optional duration]

But I have no idea what to do with things like hyphens at the end.
Probably attach them to the last element.  And the duration would likely
be for all of the syllables?  Or just the last?  Not that it would be
important since one would usually just use this in \lyricsto stuff where
the syllable length gets overridden.

-- 
David Kastrup

Reply via email to