From b39fbbdb4efb3f7ec48cd2ab5699727d388f1d52 Mon Sep 17 00:00:00 2001 From: Arshia Cont Date: Thu, 9 Jan 2020 16:11:04 +0100 Subject: [PATCH] xml2guido: Fixed ordering of grace note tag creation + added unit test --- files/xml2guido/GUID-153-DoubleGraceNotes.xml | 713 ++++++++++++++++++ src/guido/xmlpart2guido.cpp | 4 +- 2 files changed, 715 insertions(+), 2 deletions(-) create mode 100644 files/xml2guido/GUID-153-DoubleGraceNotes.xml diff --git a/files/xml2guido/GUID-153-DoubleGraceNotes.xml b/files/xml2guido/GUID-153-DoubleGraceNotes.xml new file mode 100644 index 000000000..5f910128c --- /dev/null +++ b/files/xml2guido/GUID-153-DoubleGraceNotes.xml @@ -0,0 +1,713 @@ + + + + Introduction & Rondo Capriccioso + + Camille Saint-Saëns + Prénom Nom + www.antescofo.com + + Finale v25 for Mac + 2020-01-09 + + + + + + + + + + 6.4347 + 40 + + + 1846 + 1305 + + 93 + 93 + 93 + 93 + + + + + 0 + 0 + + 237 + 158 + + + 0.7487 + 5 + 0.7487 + 0.7487 + 5 + 0.7487 + 0.7487 + 0.7487 + 0.7487 + 0.7487 + 60 + 60 + 120 + 8 + + + + + + www.antescofo.com + + + Introduction & Rondo Capriccioso + + + Camille Saint-Saëns + + + + Violin + Vn. + + SmartMusic SoftSynth + strings.violin + + + + 3 + 15489 + 41 + 80 + 0 + + + + + + + + + 1846 + 1305 + + 93 + 93 + 93 + 81 + + + + + 73 + 0 + + 237 + + system + + + 4 + + 0 + major + + + + G + 2 + + + + + + B + 5 + + 4 + 1 + quarter + down + + + + A + 5 + + 2 + 1 + eighth + down + + + + + A + 5 + + 1 + 16th + up + begin + begin + + + + + + + + B + 5 + + 1 + 16th + up + end + end + + + + A + 5 + + 2 + 1 + eighth + down + begin + + + + + + + + + + G + 1 + 5 + + 2 + 1 + eighth + sharp + down + continue + + + + + + 1 + + + + + + A + 5 + + 2 + 1 + eighth + down + end + + + + + + 1 + + + + + + + + + 171 + + + + + E + 5 + + 4 + 1 + quarter + down + + + + D + 5 + + 2 + 1 + eighth + down + + + + + D + 5 + + 1 + 16th + up + begin + begin + + + + + + + + E + 5 + + 1 + 16th + up + end + end + + + + D + 5 + + 2 + 1 + eighth + down + begin + + + + + + + + + + cresc. + + + + + C + 1 + 5 + + 2 + 1 + eighth + sharp + down + continue + + + + + + 1 + + + + + + D + 5 + + 2 + 1 + eighth + down + end + + + + + + 1 + + + + + + + + + C + 4 + + 1 + 1 + 16th + up + begin + begin + + + + D + 4 + + 1 + 1 + 16th + up + continue + continue + + + + C + 4 + + 1 + 1 + 16th + up + continue + continue + + + + B + 3 + + 1 + 1 + 16th + up + continue + end + + + + A + 3 + + 2 + 1 + eighth + up + end + + + + + E + 6 + + 1 + 16th + up + begin + begin + + + + + + + + F + 6 + + 1 + 16th + up + end + end + + + + E + 6 + + 2 + 1 + eighth + down + begin + + + + + + + + + + D + 1 + 6 + + 2 + 1 + eighth + sharp + down + continue + + + + + + + + + E + 6 + + 2 + 1 + eighth + down + end + + + + + + + + + + + + 181 + + + + + B + 5 + + 4 + 1 + quarter + down + + + + A + 5 + + 2 + 1 + eighth + down + + + + + A + 5 + + 1 + 16th + up + begin + begin + + + + + + + + B + -1 + 5 + + 1 + 16th + flat + up + end + end + + + + cresc. + + + + + A + 5 + + 2 + 1 + eighth + down + begin + + + + + + + + + + G + 1 + 5 + + 2 + 1 + eighth + sharp + down + continue + + + + + + + + + A + 5 + + 2 + 1 + eighth + down + end + + + + + + + + + + + + E + 5 + + 4 + 1 + quarter + down + + + + D + 5 + + 2 + 1 + eighth + down + + + + + D + 5 + + 1 + 16th + up + begin + begin + + + + + + + + E + 5 + + 1 + 16th + up + end + end + + + + dim. + + + + + D + 5 + + 2 + 1 + eighth + down + begin + + + + + + + + + + C + 1 + 5 + + 2 + 1 + eighth + sharp + down + continue + + + + + + + + + D + 5 + + 2 + 1 + eighth + down + end + + + + + + + + light-heavy + + + + + diff --git a/src/guido/xmlpart2guido.cpp b/src/guido/xmlpart2guido.cpp index 52fc84029..7a542ca10 100755 --- a/src/guido/xmlpart2guido.cpp +++ b/src/guido/xmlpart2guido.cpp @@ -2221,6 +2221,8 @@ void xmlpart2guido::checkPostArticulation ( const notevisitor& note ) { if (nv.isGrace()) { if (!fInGrace) { + Sguidoelement tag = guidotag::create("grace"); + push(tag); /// GUID-153: Fetch directions after grace ctree::iterator nextnote = find(fCurrentMeasure->begin(), fCurrentMeasure->end(), nv.getSnote()); nextnote.forward_up(); // forward one element @@ -2251,8 +2253,6 @@ void xmlpart2guido::checkPostArticulation ( const notevisitor& note ) } /// End-of Guid-153 fInGrace = true; - Sguidoelement tag = guidotag::create("grace"); - push(tag); } } else if (fInGrace) {