lilypond-user
[Top][All Lists]
Advanced

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

Re: lilypond-book and includes


From: TaoCG
Subject: Re: lilypond-book and includes
Date: Sat, 9 Aug 2014 07:11:29 -0700 (PDT)

Thanks, I tried the mentioned workaround but apparently this isn't the
problem.
Its not that the included file is not found. As I said, if I specify a
non-existant file with \include while using --include I get an error that
file is not found, but when I put the correct filename I get an empty staff
instead of the desired output.

The file I want to include contains some custom drum-definitions.
I post it, maybe someone can try to reproduce the problem.

### file to include: bata-def.ly ###
#(define (place-rests rest)
     (let* ((sp 0))
         (if
          (eq? (ly:grob-property-data rest 'duration-log) 1)
          (set! sp -2))
         sp))

drumPitchNames =
#'((enuopen . enuopen)
   (enumuff . enumuff)
   (chacha . chacha)
   (en . enuopen)
   (em . enumuff)
   (ch . chacha))

#(define bata-style
     '(
          (enuopen () #f -2)
          (enumuff cross #f -2)
          (chacha () #f 2)))

\layout {
    \context {
        \DrumStaff
        \name BataStaff
        drumStyleTable = #(alist->hash-table bata-style)
        \override StaffSymbol.line-positions = #'(-2 2)
        \override Rest.staff-position = #place-rests
        \override TimeSignature.style = #'numbered
        \override Stem.direction = #1
    }
    \context {
        \StaffGroup
        \accepts BataStaff
    }
}


### actual snippet ###
\include "bata-def.ly"

okonkolo = \drummode {
    eo2 ch
}

\score {
    \new StaffGroup
    <<
        \time 4/4
        \new BataStaff \okonkolo
    >>
}



--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/lilypond-book-and-includes-tp165429p165435.html
Sent from the User mailing list archive at Nabble.com.



reply via email to

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