Re: [PATCH] musicxml2ly: Make sure movement_title exists before using it

2015-12-15 Thread James
Hello,

On 13/12/15 21:32, Thomas Weber wrote:
> fixed problem and was generated by Sibelius' internal MusicXML export 
> functionality (not Dolet).
Ticket created at:
https://sourceforge.net/rest/p/testlilyissues/issues/4699/

Thanks

James

___
lilypond-devel mailing list
lilypond-devel@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-devel


[PATCH] musicxml2ly: Make sure movement_title exists before using it

2015-12-13 Thread Thomas Weber
Here's a little trivial patch to musicxml2ly.  The attached MusicXML file 
triggers the fixed problem and was generated by Sibelius' internal MusicXML 
export functionality (not Dolet).

Best,
Thomas Weber
>From 12576c27e26693832659602bf883a3d08b04fa78 Mon Sep 17 00:00:00 2001
From: Thomas Weber <t...@notabit.eu>
Date: Sun, 13 Dec 2015 17:12:57 +0100
Subject: [PATCH] musicxml2ly: Make sure movement_title exists before using it

---
 scripts/musicxml2ly.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/musicxml2ly.py b/scripts/musicxml2ly.py
index dda374d..5cf5333 100644
--- a/scripts/musicxml2ly.py
+++ b/scripts/musicxml2ly.py
@@ -178,7 +178,7 @@ def extract_score_information (tree):
 if work:
 work_title = work.get_work_title ()
 set_if_exists ('title', work_title)
-if work_title == '':
+if work_title == '' and movement_title :
 set_if_exists ('title', movement_title.get_text ())
 elif movement_title:
 set_if_exists ('subtitle', movement_title.get_text ())
-- 
1.9.1


http://www.musicxml.org/dtds/partwise.dtd;>

 
  
 
 
  Copyright © 
  
   2015-12-13
   tom
   Sibelius 8.0.0
   Direct export, not from Dolet
   Sibelius / MusicXML 3.0
   
   
   
   
   
  
 
 
  
   210
   1200
  
  
   1697
   1200
   
72
72
72
72
   
  
  
   
22
0
   
   92
  
  
   0.9375
   5
   0.9375
   1.5625
   5
   1.5625
   1.5625
   1.25
   0.9375
   1.25
   5
   1.5625
   0.9375
   1.5625
   1.5625
   1.5625
   0.625
   1.5625
   0.625
   75
   60
  
  
  
  
 
 
  
   P1
   
 

 General MIDI
 Bright Piano

   
  
 
 
  
  
   

 
  22
  0
 
 218

   
   
256

 0
 major


 4
 4

1

 G
 2


   
   

1024

1
whole
1
   
   
light-heavy
   
  
 

___
lilypond-devel mailing list
lilypond-devel@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-devel