Comment #5 on issue 2066 by mts...@gmail.com: Patch: Prevents accidentals
from hanging over barlines.
http://code.google.com/p/lilypond/issues/detail?id=2066
That's a good question.
I'm honestly not sure how to automate this (one could override the BarLine
#'extra-spacing-height, but this would likely cause too much shift-over in
the example above).
What would be ideal is to create a property separate from
extra-spacing-height called 'spacing-compress-rigidity. This property
would kick into gear of the height of an accidental went over that of a
barline. It'd be tacked onto inverse_compress_strength (or
inverse_stretch_strength...I have trouble remembering which one to set to
make it more difficult for springs to compress) in
Staff_spacing::get_spacing.
The solution may even be easier than this based on a strange caveat that
I'm researching a bit more. With this patch applied,
Paper_column::minimum_distance gives a distance that is larger than the
ideal_distance assigned to the variable `ideal' in
Staff_spacing::get_spacing. I believe that this is the only time I've ever
seen this happen: usually, minimum_distance is well under ideal. One could
say, then, that when the minimum distance between two paper columns is
greater than the ideal, that will result in an increase in
inverse_compress_strength (the idea is that the spring wants to reach its
ideal but cannot because it is blocked by a large minimum_distance). It is
a bit far fetched but would result in not having to add a new property and
would also mean less code.
Anyway, I'll chew on it...
_______________________________________________
bug-lilypond mailing list
bug-lilypond@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-lilypond