make_percussion_note

scoretools.make_percussion_note(pitch, total_duration, max_note_duration=(1, 8))

Makes short note with max_note_duration followed by rests together totaling total_duration.

>>> leaves = scoretools.make_percussion_note(2, (1, 4), (1, 8))
>>> staff = Staff(leaves)
>>> show(staff) 
>>> leaves = scoretools.make_percussion_note(2, (1, 64), (1, 8))
>>> staff = Staff(leaves)
>>> show(staff) 
>>> leaves = scoretools.make_percussion_note(2, (5, 64), (1, 8))
>>> staff = Staff(leaves)
>>> show(staff) 
>>> leaves = scoretools.make_percussion_note(2, (5, 4), (1, 8))
>>> staff = Staff(leaves)
>>> show(staff) 

Returns list of newly constructed note followed by zero or more newly constructed rests.

Durations of note and rests returned will sum to total_duration.

Duration of note returned will be no greater than max_note_duration.

Duration of rests returned will sum to note duration taken from total_duration.

Useful for percussion music where attack duration is negligible and tied notes undesirable.