Hi David,

On Tue, Jun 2, 2015 at 10:47 AM, David Sumbler <[email protected]> wrote:

> Thanks to all for your consideration of the problem I have been having
> in placing a dynamic at the end of a bar.
>
> Stephen's 2 solutions are quite effective in some cases, but so far as I
> can see cannot be made to work when there is a single note (e.g. a
> semibreve) which has to carry the hairpin.
>
> The solution using \afterGrace is not dissimilar (or so it seems to me)
> to David's original suggestion of using a parallel music expression with
> spacer rests to position the final dynamic.
>
> The trouble is, that these are all in one sense work-arounds, and might
> give problems where the music in question is to be used in both a score
> and parts.  Of course, this difficulty can easily be got around by using
> tags to create 2 different versions, one for the score and one for the
> part.
>
> Why do I refer to all of these as work-arounds?  It is because none of
> them actually directly achieves what we want.  Whether it is my dynamic
> at the end of a bar (which some people seem to consider unorthodox,
> though I disagree) or a pair of grace-notes after a trill, we know where
> the item should appear: it is just before the barline (or the following
> note, if it is not at the end of a bar).  All the work-arounds fake this
> by placing the object in relation to a note or rest which occurs near
> the end of the bar, and then if necessary adjusting the horizontal
> offset.  And, so far as I can see, we cam only find the correct values
> by trial and error.  Even then we might have to change them because of
> later editing.
>
> There is absolutely nothing at all wrong with this.  But it would be
> nice if we could just place the object where we actually want it, i.e.
> in relation to the bar-line, and know that that is where it is going to
> appear no matter what might happen with the spacing of the bar during
> editing or compilation.
>
>
The approach I suggested is of course faking what you want, .  Dynamics are
attached to notes, spacers by LilyPond's convention, so I introduce a
combination of spacers to allow me to attach a dynamic to a spacer which
will get the dynamic in the right spot.  Given LilyPond's spacing routines,
this placement will probably require tweaking.

The only alternative to placing the dynamic using spacers and
SimultaneousMusic I see would be to create an alternate routine for
typesetting such a combination.  In the case of a hairpin with dynamic on a
single, untied note, both would be attached to the note (rather than one to
s1*0 as you do above--which could suggest a multi-strand approach), but the
hairpin's length and the dynamic's X-offset from its parent would be
calculated in relation to each other.

David
_______________________________________________
lilypond-user mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to