1
0
Fork 0
mirror of https://github.com/kastdeur/bwwtolily.git synced 2024-12-05 01:13:31 +01:00

'^[abcdef]' ties are old ties

Do not look for the e tie, as this is the new 'end of tie'
This commit is contained in:
Eric Teunis de Boone 2019-02-11 00:51:47 +01:00
parent b9bfeed838
commit 9a43ba9688

View file

@ -52,8 +52,8 @@ class bwwtolily :
self.regex_strike = re.compile("str([h|l]*[abcdefg])") self.regex_strike = re.compile("str([h|l]*[abcdefg])")
#a regex to find dots #a regex to find dots
self.regex_dot = re.compile("'[h|l]*[abcdefg]") self.regex_dot = re.compile("'[h|l]*[abcdefg]")
#a regex to find note ties #a regex to find old note ties
self.regex_tie = re.compile("\^t[h|l]?[abcdefg]") self.regex_old_tie = re.compile("\^t[h|l]?[abcdfg]")
#a regex to find sub repeats #a regex to find sub repeats
self.regex_sub_repeat = re.compile("'([0-9]+)") self.regex_sub_repeat = re.compile("'([0-9]+)")
#a regex to find note slurs, not slur embellishments #a regex to find note slurs, not slur embellishments
@ -288,9 +288,9 @@ class bwwtolily :
self.tune_elements[self.most_recent_note]+="." self.tune_elements[self.most_recent_note]+="."
return return
#is the element a note tie #is the element an old note tie
tie_result = self.regex_tie.search(element) old_tie_result = self.regex_old_tie.search(element)
if tie_result: if old_tie_result:
self.tune_elements[self.most_recent_note]+="~" self.tune_elements[self.most_recent_note]+="~"
return return