X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=scm%2Fharp-pedals.scm;h=9365f0a034f42294cc47dfe290c738a77fb0841f;hb=a7c154989b07dbd183289e228b4397fea3bd6d57;hp=c245c82477f92fa001c04c46f43c2582ec268b2a;hpb=bd751630011a6fbfcf069ec1fc41a8eaed8a6b87;p=lilypond.git diff --git a/scm/harp-pedals.scm b/scm/harp-pedals.scm index c245c82477..9365f0a034 100644 --- a/scm/harp-pedals.scm +++ b/scm/harp-pedals.scm @@ -1,6 +1,6 @@ ;;;; This file is part of LilyPond, the GNU music typesetter. ;;;; -;;;; Copyright (C) 2008--2012 Reinhold Kainhofer +;;;; Copyright (C) 2008--2015 Reinhold Kainhofer ;;;; ;;;; LilyPond is free software: you can redistribute it and/or modify ;;;; it under the terms of the GNU General Public License as published by @@ -124,15 +124,15 @@ spacing after the divider). (final-x (car result)) (stencils (cdr result))) ;; Add the horizontal line and combine all stencils: - (box-stencil - (apply ly:stencil-add - (cons - (make-line-stencil line-width 0 0 final-x 0) - stencils)) - 0.0 - 0.0))) + (apply ly:stencil-add + (make-line-stencil line-width 0 0 final-x 0) ; the horizontal line + (make-transparent-box-stencil ; space for absent boxes + (cons 0 final-x) + (interval-widen '(0 . 0) (+ box-hheight dy))) + stencils))) ;; Parse the harp pedal definition string into list of directions (-1/0/1), #\o and #\| +;; Whitespace is removed from definition string before the procedure applies. (define (harp-pedals-parse-string definition-string) "Parse a harp pedals diagram string and return a list containing 1, 0, -1, #\\o or #\\|" (map (lambda (c) @@ -142,7 +142,7 @@ spacing after the divider). ((#\-) 0) ((#\| #\o) c) (else c))) - (string->list definition-string))) + (string->list (remove-whitespace definition-string)))) ;; Analyze the pedal-list: Return (pedalcount . (divider positions))