Re: Custom percussion staves

2021-01-28 Thread ebenezer

Thank you Aaron,

Ah, makes sense. I prefer the way you suggested and have it working.

Cheers.


On 2021-01-28 15:19, Aaron Hill wrote:

On 2021-01-28 4:35 am, ebenezer wrote:

Hello everyone,

I have noticed that use of a custom percussion staff is different from
the manner in which one of the pre-defined percussion staves is used:

partBongo = \new DrumStaff \with {
  drumStyleTable = #bongos-style
} \staffBongo

... compared to ...

partPercCustom = \new DrumStaff \with {
  % -- drumStyleTable = #defPercCustom  % -- this doesn't work
} <<
  \set DrumStaff.drumStyleTable = #(alist->hash-table defPercCustom)
% -- works this way




Is this just the way it is, or am I missing something?


bongos-style (and its kin) are hash tables, which is what 
drumStyleTable expects.  The documentation shows defining a custom 
drum style as an alist and then converting it to a hash table when you 
use it.  An alternative would be to do the conversion when you define 
the style:



\version "2.22.0"

custom-drum-style =
#(alist->hash-table
  '((bassdrum default "tenuto" -1)
(snare diamond #f 0)
(hihat cross #f 1)))

\new DrumStaff
\with { drumStyleTable = #custom-drum-style }
\drummode { bd4 hh8 8 sn2 }



-- Aaron Hill





Re: Custom percussion staves

2021-01-28 Thread Aaron Hill

On 2021-01-28 4:35 am, ebenezer wrote:

Hello everyone,

I have noticed that use of a custom percussion staff is different from
the manner in which one of the pre-defined percussion staves is used:

partBongo = \new DrumStaff \with {
  drumStyleTable = #bongos-style
} \staffBongo

... compared to ...

partPercCustom = \new DrumStaff \with {
  % -- drumStyleTable = #defPercCustom  % -- this doesn't work
} <<
  \set DrumStaff.drumStyleTable = #(alist->hash-table defPercCustom)
% -- works this way




Is this just the way it is, or am I missing something?


bongos-style (and its kin) are hash tables, which is what drumStyleTable 
expects.  The documentation shows defining a custom drum style as an 
alist and then converting it to a hash table when you use it.  An 
alternative would be to do the conversion when you define the style:



\version "2.22.0"

custom-drum-style =
#(alist->hash-table
  '((bassdrum default "tenuto" -1)
(snare diamond #f 0)
(hihat cross #f 1)))

\new DrumStaff
\with { drumStyleTable = #custom-drum-style }
\drummode { bd4 hh8 8 sn2 }



-- Aaron Hill



Custom percussion staves

2021-01-28 Thread ebenezer

Hello everyone,

I have noticed that use of a custom percussion staff is different from 
the manner in which one of the pre-defined percussion staves is used:


partBongo = \new DrumStaff \with {
  drumStyleTable = #bongos-style
} \staffBongo

... compared to ...

partPercCustom = \new DrumStaff \with {
  % -- drumStyleTable = #defPercCustom  % -- this doesn't work
} <<
  \set DrumStaff.drumStyleTable = #(alist->hash-table defPercCustom)  % 
-- works this way

>>

Is this just the way it is, or am I missing something?

Thank you.




about custom percussion staves?

2008-12-29 Thread coralline algae
In the Notation manual 2.5 custom percussion staves, I have used
the example shown.  But havent been able to find out what the third
column is supposed to do.   ie.   #f  or #t  doesn't seem to do much?
Although the pedalhihat line seems to code for the + above.

I would like to know where to look in the documentation that
explains that column.


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: about custom percussion staves?

2008-12-29 Thread Neil Puttock
Hi Coralline,

2008/12/29 coralline algae corall...@gmail.com:
 In the Notation manual 2.5 custom percussion staves, I have used
 the example shown.  But havent been able to find out what the third
 column is supposed to do.   ie.   #f  or #t  doesn't seem to do much?
 Although the pedalhihat line seems to code for the + above.

 I would like to know where to look in the documentation that
 explains that column.

It's only listed in the Internals Reference at the moment
(http://lilypond.org/doc/v2.12/Documentation/user/lilypond-internals/Tunable-context-properties#Tunable-context-properties),
since the Percussion chapter is still a work in progress.

The third column specifies a script to add to the notehead, which
would be one of the options listed here:
http://lilypond.org/doc/v2.12/Documentation/user/lilypond/List-of-articulations#List-of-articulations.
 If no script is required, #f should be used; though #t has the same
effect as #f, its use in the examples is likely to confuse users. :)

Regards,
Neil


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user