On Wed, May 23, 2012 at 1:43 PM, Thomas Morley <thomasmorle...@googlemail.com> wrote: > I tried it similar to `overrideProperty' from `music-functions-init.ly' > But I didn't manage to get rid of the ""-signs, when specifying the > coctext. Is this possible? > > \version "2.15.38" > > offsetPositions = > #(define-music-function (parser location name offsets) (string? pair?) > > (let ((name-components (string-split name #\.)) > (context-name "Voice") > (grob-name #f)) > > (if (> 2 (length name-components)) > (set! grob-name (car name-components)) > (begin > (set! grob-name (list-ref name-components 1)) > (set! context-name (list-ref name-components 0)))) > #{ > \override $context-name . $grob-name #'positions = #(lambda (grob) > (let* ((func (assoc-get 'positions > (reverse(ly:grob-basic-properties grob)))) > (pos (func grob))) > (coord-translate pos offsets))) > #}))
Thank you! Making "" unnecessary would be great, but it's already excellent! Janek _______________________________________________ lilypond-devel mailing list lilypond-devel@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-devel