From 1011966cfdc1d919dd9defc067cfd6670f8bd8bd Mon Sep 17 00:00:00 2001 From: Matthias Neeracher Date: Sun, 24 Feb 2008 20:14:43 +0000 Subject: [PATCH] Omit repeated chords. Fix omitted steps --- BUGS | 5 +++++ Filters/VLLilypondType.reader | 10 +++++----- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/BUGS b/BUGS index 03e3015..38d7286 100644 --- a/BUGS +++ b/BUGS @@ -10,5 +10,10 @@ * Prefer flats in C major * Walking syllables is not accurate +23Feb08 + +* Joy Spring: Import in 12ths +* Let's do it: C697 +* Let's Misbehave: Transposes wrong way diff --git a/Filters/VLLilypondType.reader b/Filters/VLLilypondType.reader index d189c15..98b2f07 100755 --- a/Filters/VLLilypondType.reader +++ b/Filters/VLLilypondType.reader @@ -186,7 +186,7 @@ def parseLilypond tokens = [] INFILE.each do |line| line.chomp!.sub!(/%.*/, "") - line.scan(%r$\G\s*(\{|\}|\(|\)|\||=|~|<<|>>|--|#'|#\(|##t|##f|\\\w+|\".*?\"|\w[-+\w\d.',:*/]+|.)$) do |token| + line.scan(%r$\G\s*(\{|\}|\(|\)|\||=|~|<<|>>|--|#'|#\(|##t|##f|\\\w+|\".*?\"|\w[-+^\w\d.',:*/]+|.)$) do |token| tokens.push(token[0]) end end @@ -237,7 +237,7 @@ def parseLilypond (\d+ # 1, 2, 4, 8, 16 ... \.*(?:\*\d+/\d+)? # ., *3/4 )? - (?:\:([-+^:.a-z\d]+)?)? # :maj9.7-^2 + (?:\:([-+^:.a-z\d]*))? # :maj9.7-^2 (?:/\+?( # /+ [a-g](?:[ei]?s)? # Root: a, bes, fis, as ))? @@ -476,9 +476,9 @@ def makeMeasures if len+chordLen > measureLen remLen = len+chordLen-measureLen chordLen -= remLen - remChord = chord.dup - remChord['durNum'] = remLen.num - remChord['durDenom'] = remLen.denom + remChord = { + 'pitch' => VL::NoPitch, 'root' => VL::NoPitch, + 'durNum' => remLen.num, 'durDenom' => remLen.denom} CHORDS.unshift(remChord) end mchords.push(chord)