X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=scm%2Fdefine-music-types.scm;h=973e59a403872076ee125ec3505f82899d9c32ad;hb=c1aa65bb5ec974f01429f9ab3c2d8a4080a3ab3d;hp=0dc1c66bcf58c7c82077e9c484fd2444e2fc9a64;hpb=1c859650b6ff11a7dbe829328fd5cae3816b9231;p=lilypond.git diff --git a/scm/define-music-types.scm b/scm/define-music-types.scm index 0dc1c66bcf..973e59a403 100644 --- a/scm/define-music-types.scm +++ b/scm/define-music-types.scm @@ -1,9 +1,20 @@ -;;;; define-music-types.scm -- +;;;; This file is part of LilyPond, the GNU music typesetter. ;;;; -;;;; source file of the GNU LilyPond music typesetter -;;;; -;;;; (c) 1998--2009 Han-Wen Nienhuys +;;;; Copyright (C) 1998--2010 Han-Wen Nienhuys ;;;; Jan Nieuwenhuizen +;;;; +;;;; LilyPond is free software: you can redistribute it and/or modify +;;;; it under the terms of the GNU General Public License as published by +;;;; the Free Software Foundation, either version 3 of the License, or +;;;; (at your option) any later version. +;;;; +;;;; LilyPond is distributed in the hope that it will be useful, +;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;;;; GNU General Public License for more details. +;;;; +;;;; You should have received a copy of the GNU General Public License +;;;; along with LilyPond. If not, see . ;; TODO: should link back into user manual. @@ -405,6 +416,15 @@ Syntax: @code{\\unset @var{context}.@var{prop}}") (types . (music-wrapper-music general-music relative-octave-music)) )) + (RepeatedChord + . ((description . "A chord repetition") + (to-relative-callback . ,ly:music-sequence::repeated-chord-relative-callback) + (iterator-ctor . ,ly:music-wrapper-iterator::constructor) + (start-callback . ,ly:music-wrapper::start-callback) + (length-callback . ,ly:music-wrapper::length-callback) + (types . (general-music music-wrapper-music)) + )) + (RepeatedMusic . ((description . "Repeat music in different ways.") (types . (general-music repeated-music)) @@ -558,7 +578,7 @@ Syntax: @code{\\times @var{fraction} @var{music}}, e.g., @code{\\times 2/3 @{ @dots{} @}} for triplets.") (length-callback . ,ly:music-wrapper::length-callback) (start-callback . ,ly:music-wrapper::start-callback) - (iterator-ctor . ,ly:time-scaled-music-iterator::constructor) + (iterator-ctor . ,ly:tuplet-iterator::constructor) (types . (time-scaled-music music-wrapper-music general-music)) )) @@ -690,14 +710,14 @@ and values. E.g: m))) (define-public (make-repeated-music name) - (let* ((handle (assoc name '(("volta" . VoltaRepeatedMusic) - ("unfold" . UnfoldedRepeatedMusic) - ("percent" . PercentRepeatedMusic) - ("tremolo" . TremoloRepeatedMusic)))) - (music-name (if (pair? handle) - (cdr handle) - (begin - (ly:warning (_ "unknown repeat type `~S'") name) - (ly:warning (_ "See define-music-types.scm for supported repeats")) - 'VoltaRepeatedMusic)))) - (make-music music-name))) + (let* ((repeated-music (assoc-get name '(("volta" . VoltaRepeatedMusic) + ("unfold" . UnfoldedRepeatedMusic) + ("percent" . PercentRepeatedMusic) + ("tremolo" . TremoloRepeatedMusic)))) + (repeated-music-name (if repeated-music + repeated-music + (begin + (ly:warning (_ "unknown repeat type `~S'") name) + (ly:warning (_ "See define-music-types.scm for supported repeats")) + 'VoltaRepeatedMusic)))) + (make-music repeated-music-name)))