[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
collision-detecting engraver?
From: |
Kieren MacMillan |
Subject: |
collision-detecting engraver? |
Date: |
Sat, 15 Feb 2014 19:48:23 -0500 |
Hello all!
…and in particular David N., who I think will find this a fascinating puzzle :)
In the Piano/Conductor scores for my musicals, I like to include the chord
symbols for those who can use them. A survey of representative scores shows
that, while there is no defined standard as to placement, a significant portion
(~40%) place them where I prefer, i.e., between the two piano staves. (The
other popular spot is above the vocal staff, which is where they sit for nearly
100% of commercial “vocal selections” and “piano/guitar” songbooks.)
The problem, of course, is that dynamics sit in the same slot [between the
piano staves]. Therefore, there can be a lot of collisions. Lilypond does a
pretty remarkable job of vertical spacing when there are no horizontal
collisions. (Kudos to everyone involved in making that true!). However, when
there are collisions, they require [a lot of] manual tweaking, of three types:
1. Move the chord symbol slightly to the right of the “proper moment”. This
works especially for single, simple, absolute dynamic marks.
2. Skip the chord symbol entirely for that moment. This works when the chord is
obvious or repeated or whatever.
3. Juggle both dynamic(s) and chord symbol(s) along both axes. This happens
when both are necessary, and the dynamic is “long” (e.g., a hairpin, or “f,
molto marcatissimo”, etc.)
I would love Lilypond to automatically do #1 or #2 unless told otherwise.
(Well, actually, since #3 would be done manually anyway, Lilypond would be
expected to do #1 or #2 only, I suppose…)
Is such a thing possible?
If so, how much work would it take to make happen?
Thanks!
Kieren.
p.s. Here’s a minimal test case:
\version "2.19"
theNotes = {
\repeat unfold 3 { R1 }
}
theChords = \chordmode {
g1 g1:7 c1
}
theDynamics = {
s1 s\mf s
}
\score {
\new PianoStaff <<
\new Staff \theNotes
\new ChordNames \theChords
\new Dynamics \theDynamics
\new Staff \theNotes
>>
}
- collision-detecting engraver?,
Kieren MacMillan <=