From: fred Date: Wed, 27 Mar 2002 01:21:45 +0000 (+0000) Subject: lilypond-1.5.18 X-Git-Tag: release/1.5.59~538 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=044f1d7c305bfe6dc933fe5edff9ec02690ef1ae;p=lilypond.git lilypond-1.5.18 --- diff --git a/input/test/midi-tuplets.ly b/input/test/midi-tuplets.ly new file mode 100644 index 0000000000..875bc9775f --- /dev/null +++ b/input/test/midi-tuplets.ly @@ -0,0 +1,35 @@ +\version "1.3.146" + +\header { +texidoc = " + +Midi2ly tuplet test. + +@example + python scripts/midi2ly.py --duration-quant=32 \ + --allow-tuplet=4*2/3 \ + --allow-tuplet=8*2/3 \ + --allow-tuplet=4*3/5 \ + --allow-tuplet=8*3/5 \ + tu.midi +@end example +" + +} + + +\score { + \context Voice \notes { + + a1 a2 a2. a4 a4. a8 a8. a16 a16. a32 a32. a64 + + \times 2/3 { b4 b4 b4 } + \times 3/5 { b4 b4 b4 b4 b4 } + + \times 2/3 { c8 c8 c8 } + \times 3/5 { c8 c8 c8 c8 c8 } + + } + \paper { } + \midi { } +} diff --git a/lily/performance.cc b/lily/performance.cc index f77674fe55..cb16e8f751 100644 --- a/lily/performance.cc +++ b/lily/performance.cc @@ -81,9 +81,8 @@ Performance::output_header_track (Midi_stream& midi_stream) // perhaps multiple text events? String id_str; String str = String (_ ("Creator: ")); - id_str = String_convert::pad_to (gnu_lilypond_version_str (), 40); + id_str = String_convert::pad_to (gnu_lilypond_version_str (), 30); str += id_str; - str += "\n"; /* This seems silly, but in fact the audio elements should @@ -96,20 +95,22 @@ Performance::output_header_track (Midi_stream& midi_stream) /* Better not translate this */ str = "Generated automatically by: "; str += id_str; - str += _ (", at "); - time_t t (time (0)); - str += ctime (&t); - str = str.left_str (str.length_i () - 1); - - /* - Pad out time stamps to 120 chars. */ - - str = String_convert::pad_to (str, 120); Audio_text generate_a (Audio_text::TEXT, str); Midi_text generate (&generate_a); midi_track.add (Moment (0), &generate); + + str = _ ("at "); + time_t t (time (0)); + str += ctime (&t); + str = str.left_str (str.length_i () - 1); + str = String_convert::pad_to (str, 60); + + Audio_text at_a (Audio_text::TEXT, str); + Midi_text at (&at_a); + midi_track.add (Moment (0), &at); + str = _f ("from musical definition: %s", origin_str_); Audio_text from_a (Audio_text::TEXT, str);