]> git.donarmstrong.com Git - lilypond.git/commitdiff
MusicXML: Use "None" voice only for notes w/o voice, not for directions or attrs
authorReinhold Kainhofer <reinhold@kainhofer.com>
Sat, 15 Nov 2008 23:43:06 +0000 (00:43 +0100)
committerReinhold Kainhofer <reinhold@kainhofer.com>
Sat, 15 Nov 2008 23:43:06 +0000 (00:43 +0100)
python/musicxml.py

index 3c9d8a0111da3e9f0a2f6d21c0dc9943aa8d0cf3..e9df0b30105d93ad61157de5ca11b71bdd63221a 100644 (file)
@@ -702,9 +702,11 @@ class Part (Music_xml_node):
         voice_to_staff_dict = {}
         for n in elements:
             voice_id = n.get_maybe_exist_named_child (u'voice')
-            vid = "None"
+            vid = None
             if voice_id:
                 vid = voice_id.get_text ()
+            elif isinstance (n, Note):
+                vid = "None"
 
             staff_id = n.get_maybe_exist_named_child (u'staff')
             sid = None