|
|
@ -84,6 +84,7 @@ def lilyfy(string): |
|
|
|
if string.startswith("\\markup"): |
|
|
|
return string #trust the user |
|
|
|
|
|
|
|
string = string.replace('\\n', '\n') #replace the user newline with actual one |
|
|
|
string = string.replace('"', '\\"') |
|
|
|
return string |
|
|
|
|
|
|
@ -132,7 +133,8 @@ def fromTemplate(session, data, meta, tempoStaff): |
|
|
|
templateString = templateString.replace("%$$GLOBAL-STAFF-SIZE$$", str(meta["global-staff-size"])) |
|
|
|
templateString = templateString.replace("%$$FILENAME$$", session.sessionPrefix) |
|
|
|
templateString = templateString.replace("%$$HEADER$$", processMeta(meta)) |
|
|
|
templateString = templateString.replace("%$$SUBTEXT$$", '"' + lilyfy(meta["subtext"]) + '"') |
|
|
|
#templateString = templateString.replace("%$$SUBTEXT$$", '"' + lilyfy(meta["subtext"]) + '"') |
|
|
|
templateString = templateString.replace("%$$SUBTEXT$$", lilyfy(meta["subtext"]) ) |
|
|
|
voicesString, structureString = processData(data) |
|
|
|
templateString = templateString.replace("%$$VOICES$$", voicesString) |
|
|
|
templateString = templateString.replace("%$$STRUCTURE$$", structureString) |
|
|
|