Re: [frogs] Re: convert-ly keySignautre issue nearly solved

[ Thread Index | Date Index | More lilynet.net/frogs Archives ]


Quoting "Carl D. Sorensen" <c_sorensen@xxxxxxx>:




On 5/12/09 11:14 PM, "Andrew Hawryluk" <ahawryluk@xxxxxxxxx> wrote:

I think I have figured out issue 708:
http://code.google.com/p/lilypond/issues/detail?id=708
Before I submit a patch, how do I decide which LP version this goes
under for convert-ly?

You will want to see where the keySignature syntax changed.

No it's not that simple. The solution proposed in the bug tracker is really only relevant for scores older than version 2.0 (I haven't checked exactly which 1.9 version the change happened), when the internal representation for accidentals changed to be able to handle quarter tones. In version 1.8 and earlier, the alteration +1 meant sharp and -1 meant flat, whereas from version 2.0 to version 2.10, +1 meant semi-sharp, +2 meant sharp, -2 meant flat and so on.

If you check the example called key-signature-scordatura.ly in the Regression t Tests documents of version 1.8 and 2.0, you can easily notice the change, since the input file stayed the same but the output changed. (If you check the documentation of the Key engraver in the program references, you will notice that the documentation wasn't updated until version 2.2).

However, as you can see from the above mentioned regression test example, LilyPond still produced reasonable output for input of the type mentioned in the bug report.

However, in version 2.11.6, the next change happened to the internal representation of alterations. From then, a sharp is represented by +1/2, a flat by -1/2 and so on. For all the people who had already used the macros SHARP, FLAT, DOUBLE-FLAT and so on, this didn't cause any problems, but for those who had kept the numeric representation, you all of a sudden end up with a "missing glyph" error if you for example specify +2 or -2.

To conclude, if you want to do a convert-ly rule that converts
+1 -> SHARP
+2 -> DOUBLE-SHARP
....

that it should apply to some 1.9 version. On the other hand, if you do a convert-ly rule that converts
+2 -> SHARP
+1 -> SEMI-SHARP
+4 -> DOUBPLE-SHARP
....
then it should apply to version 2.11.6.

I would actually propose that you take the effort to include both these conversion rules.

   /Mats


---

----
Join the Frogs!


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/