Am Di., 27. Okt. 2020 um 10:17 Uhr schrieb Aaron Hill
<[email protected]>:
>
> On 2020-10-27 1:58 am, [email protected] wrote:
> > Hi all,
> >
> > I’m using  <http://lsr.di.unimi.it/LSR/Item?id=632> this barré-function
> > from
> > the LSR and I’m trying to make it work when the first note (or the last
> > one)
> > is a rest.
> >
> > Here’s the code:
> >
> > [...]
> >
> > What do I have to change or is there some other trick to make it work?
>
> Add RestEvent to the named music list:
>
> %%%%
> % . . .
> guitbarre =
> #(define-music-function (barre location str music) (string? ly:music?)
>     (let ((elts (extract-named-music music '(RestEvent NoteEvent
> EventChord))))
> % . . .
> %%%%
>
> Or switch out the logic to look for typed music:
>
> %%%%
> % . . .
> guitbarre =
> #(define-music-function (barre location str music) (string? ly:music?)
>     (let ((elts (extract-typed-music music '(rhythmic-event))))
> % . . .
> %%%%
>
>
> -- Aaron Hill
>

Hi Aaron,

I changed the LSR-snippet, following your suggestion, just dropping the list.
http://lsr.di.unimi.it/LSR/Snippet?id=632

Thanks,
  Harm

Reply via email to