Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(554)

Unified Diff: python/musicexp.py

Issue 558920043: Fix musicxml2ly.py python 2.4.5 compatibility issues
Patch Set: Last part of my musicxml2ly patch. Ready for review / release. Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | python/musicxml.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: python/musicexp.py
diff --git a/python/musicexp.py b/python/musicexp.py
index 2aba0e5d9343fb3e5dac9531a0fea597735b2691..c29b11b1543befc0aa6ea9fc843a336f519f0ca3 100644
--- a/python/musicexp.py
+++ b/python/musicexp.py
@@ -816,7 +816,7 @@ class Lyrics:
for l in self.lyrics_syllables:
lstr += l
#lstr += "\n}"
- return lstr
+ return lstr.encode('utf-8')
class Header:
@@ -1595,7 +1595,7 @@ class ChordNameEvent (Event):
if self.duration:
value += self.duration.ly_expression ()
if self.kind:
- value = self.kind.format(value)
+ value = value + self.kind
# First print all additions/changes, and only afterwards all subtractions
for m in self.modifications:
if m.type == 1:
@@ -2228,9 +2228,7 @@ class StaffGroup:
escape_instrument_string (self.short_instrument_name)))
printer.newline ()
if self.sound:
- printer.dump(
- r'\set {stafftype}.midiInstrument = "{sound}"'.format(
- stafftype=self.stafftype, sound=self.sound))
+ printer.dump (r'\set %s.midiInstrument = "%s"' % (self.stafftype, self.sound))
printer.newline ()
self.print_ly_contents (printer)
printer.newline ()
« no previous file with comments | « no previous file | python/musicxml.py » ('j') | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b