From 02a4693145fa9a28092b4e19a4b717bec28c4030 Mon Sep 17 00:00:00 2001 From: Klaus Rettinghaus Date: Mon, 18 Nov 2024 13:38:24 +0100 Subject: [PATCH 1/6] adjust customization to latest build process --- libmei/mei/mei-verovio.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libmei/mei/mei-verovio.xml b/libmei/mei/mei-verovio.xml index 3d2a80d1fee..cb51c50714d 100644 --- a/libmei/mei/mei-verovio.xml +++ b/libmei/mei/mei-verovio.xml @@ -54,7 +54,7 @@ - + From 4c7c766b27eb2a0b5f8f8b98f432b6b928e4a92f Mon Sep 17 00:00:00 2001 From: Klaus Rettinghaus Date: Mon, 18 Nov 2024 16:23:41 +0100 Subject: [PATCH 2/6] make bracketSpanLog_FUNC closed list --- libmei/datatypes.yml | 5 --- libmei/dist/attconverter.cpp | 4 +++ libmei/dist/atttypes.h | 2 ++ libmei/mei/mei-verovio.xml | 32 ++++++++++++++++-- libmei/mei/mei-verovio_compiled.odd | 52 ++++++++++------------------- src/iomusxml.cpp | 4 +-- 6 files changed, 56 insertions(+), 43 deletions(-) diff --git a/libmei/datatypes.yml b/libmei/datatypes.yml index 4586cc27674..165866c920e 100644 --- a/libmei/datatypes.yml +++ b/libmei/datatypes.yml @@ -187,11 +187,6 @@ defaults: data_STAFFREL() modules: - cmn: - att.bracketSpan.log: - func: - type: bracketSpanLog_FUNC - externalsymbols: att.extsym: glyphnum: diff --git a/libmei/dist/attconverter.cpp b/libmei/dist/attconverter.cpp index d97e5b5a880..c55294f2735 100644 --- a/libmei/dist/attconverter.cpp +++ b/libmei/dist/attconverter.cpp @@ -3994,6 +3994,8 @@ std::string AttConverterBase::BracketSpanLogFuncToStr(bracketSpanLog_FUNC data) case bracketSpanLog_FUNC_coloration: value = "coloration"; break; case bracketSpanLog_FUNC_cross_rhythm: value = "cross-rhythm"; break; case bracketSpanLog_FUNC_ligature: value = "ligature"; break; + case bracketSpanLog_FUNC_analytical: value = "analytical"; break; + case bracketSpanLog_FUNC_uspecified: value = "uspecified"; break; default: LogWarning("Unknown value '%d' for att.bracketSpan.log@func", data); value = ""; @@ -4007,6 +4009,8 @@ bracketSpanLog_FUNC AttConverterBase::StrToBracketSpanLogFunc(const std::string if (value == "coloration") return bracketSpanLog_FUNC_coloration; if (value == "cross-rhythm") return bracketSpanLog_FUNC_cross_rhythm; if (value == "ligature") return bracketSpanLog_FUNC_ligature; + if (value == "analytical") return bracketSpanLog_FUNC_analytical; + if (value == "uspecified") return bracketSpanLog_FUNC_uspecified; if (logWarning && !value.empty()) LogWarning("Unsupported value '%s' for att.bracketSpan.log@func", value.c_str()); return bracketSpanLog_FUNC_NONE; diff --git a/libmei/dist/atttypes.h b/libmei/dist/atttypes.h index 7d15953404c..cf3c7c6347f 100644 --- a/libmei/dist/atttypes.h +++ b/libmei/dist/atttypes.h @@ -1872,6 +1872,8 @@ enum bracketSpanLog_FUNC : int8_t { bracketSpanLog_FUNC_coloration, bracketSpanLog_FUNC_cross_rhythm, bracketSpanLog_FUNC_ligature, + bracketSpanLog_FUNC_analytical, + bracketSpanLog_FUNC_uspecified, bracketSpanLog_FUNC_MAX }; diff --git a/libmei/mei/mei-verovio.xml b/libmei/mei/mei-verovio.xml index cb51c50714d..b3f64eee16b 100644 --- a/libmei/mei/mei-verovio.xml +++ b/libmei/mei/mei-verovio.xml @@ -125,6 +125,34 @@ + + + + + + + + + Represents coloration in the mensural notation source material. + + + Marks a sequence which does not match the current meter. + + + Represents a ligature in the mensural notation source material. + + + + Represents a ligature in the mensural notation source material. + + + Represents a ligature in the mensural notation source material. + + + + + + @@ -522,8 +550,8 @@ - - In string tablature, the number of the course to be played, i.e., [1-9]+. + + In string tablature, the number of the course to be played. diff --git a/libmei/mei/mei-verovio_compiled.odd b/libmei/mei/mei-verovio_compiled.odd index a3ca3632df4..1ddd4ca4356 100644 --- a/libmei/mei/mei-verovio_compiled.odd +++ b/libmei/mei/mei-verovio_compiled.odd @@ -1,4 +1,4 @@ - + @@ -50,7 +50,7 @@ - + Written accidental values. @@ -4190,35 +4190,19 @@ - - Logical domain attributes. - - - - - - - - - function - Describes the function of the bracketed event sequence. - - - - - - Represents coloration in the mensural notation source material. - - - Marks a sequence which does not match the current meter. - - - Represents a ligature in the mensural notation source material. - - - - - + Logical domain attributes.functionDescribes the function of the bracketed event sequence. + + + Represents coloration in the mensural notation source material. + + Marks a sequence which does not match the current meter. + + Represents a ligature in the mensural notation source material. + + Represents a ligature in the mensural notation source material. + + Represents a ligature in the mensural notation source material. + Logical domain attributes. @@ -20435,8 +20419,8 @@ - - In string tablature, the number of the course to be played, i.e., [1-9]+. + + In string tablature, the number of the course to be played. @@ -20498,7 +20482,7 @@ foo informationDummy element for enforcing that the att classes are used. - + \ No newline at end of file diff --git a/src/iomusxml.cpp b/src/iomusxml.cpp index 2ef83d1258d..86cb54613d9 100644 --- a/src/iomusxml.cpp +++ b/src/iomusxml.cpp @@ -2008,7 +2008,7 @@ void MusicXmlInput::ReadMusicXmlDirection( bracketSpan->SetLform( bracketSpan->AttLineRendBase::StrToLineform(bracket.attribute("line-type").as_string())); // bracketSpan->SetPlace(bracketSpan->AttPlacementRelStaff::StrToStaffrel(placeStr.c_str())); - // bracketSpan->SetFunc("unclear"); + bracketSpan->SetFunc(bracketSpanLog_FUNC_uspecified); bracketSpan->SetLstartsym(ConvertLineEndSymbol(bracket.attribute("line-end").as_string())); bracketSpan->SetTstamp(timeStamp); m_controlElements.push_back({ measureNum, bracketSpan }); @@ -2433,7 +2433,7 @@ void MusicXmlInput::ReadMusicXmlDirection( musicxml::OpenSpanner openBracket(voiceNumber, m_measureCounts.at(measure)); bracketSpan->SetColor(lead.attribute("color").as_string()); // bracketSpan->SetPlace(bracketSpan->AttPlacementRelStaff::StrToStaffrel(placeStr.c_str())); - // bracketSpan->SetFunc("analytical"); + bracketSpan->SetFunc(bracketSpanLog_FUNC_analytical); bracketSpan->SetLstartsym(ConvertLineEndSymbol(lead.attribute("symbol").as_string())); bracketSpan->SetTstamp(timeStamp); bracketSpan->SetType("principal-voice"); From 15e9b1f773d318d90fbf2e30524a8631940174ec Mon Sep 17 00:00:00 2001 From: Klaus Rettinghaus Date: Thu, 21 Nov 2024 21:19:32 +0100 Subject: [PATCH 3/6] fix description --- libmei/mei/mei-verovio.xml | 2 +- libmei/mei/mei-verovio_compiled.odd | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/libmei/mei/mei-verovio.xml b/libmei/mei/mei-verovio.xml index b3f64eee16b..6a26f1b542a 100644 --- a/libmei/mei/mei-verovio.xml +++ b/libmei/mei/mei-verovio.xml @@ -570,7 +570,7 @@ Open D tuning for guitars. D2 A2 D3 F3s A3 D4. - Open G tuning for guitars. D2 G2 D2 G2 B3 D4. + Open G tuning for guitars. D2 G2 D3 G3 B3 D4. Open A tuning for guitars. E2 A2 E3 A3 C4s E4. diff --git a/libmei/mei/mei-verovio_compiled.odd b/libmei/mei/mei-verovio_compiled.odd index 1ddd4ca4356..d74d8f2355f 100644 --- a/libmei/mei/mei-verovio_compiled.odd +++ b/libmei/mei/mei-verovio_compiled.odd @@ -20438,7 +20438,7 @@ Open D tuning for guitars. D2 A2 D3 F3s A3 D4. - Open G tuning for guitars. D2 G2 D2 G2 B3 D4. + Open G tuning for guitars. D2 G2 D3 G3 B3 D4. Open A tuning for guitars. E2 A2 E3 A3 C4s E4. From 7aa9b638b230ddf9fcd8ad97ceac54c3838c3562 Mon Sep 17 00:00:00 2001 From: Klaus Rettinghaus Date: Mon, 25 Nov 2024 12:43:06 +0100 Subject: [PATCH 4/6] add phrasing bracket --- libmei/mei/mei-verovio.xml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/libmei/mei/mei-verovio.xml b/libmei/mei/mei-verovio.xml index 6a26f1b542a..f9b6b3f3bbb 100644 --- a/libmei/mei/mei-verovio.xml +++ b/libmei/mei/mei-verovio.xml @@ -143,10 +143,13 @@ - Represents a ligature in the mensural notation source material. + Highlights a grouping of some sort. + + + Marks a phrase. - Represents a ligature in the mensural notation source material. + Unspecified bracket. From a2f0d987cb90af45196ef18c30697f2928492805 Mon Sep 17 00:00:00 2001 From: Klaus Rettinghaus Date: Mon, 25 Nov 2024 12:57:02 +0100 Subject: [PATCH 5/6] update libmei --- libmei/dist/attconverter.cpp | 2 ++ libmei/dist/atttypes.h | 1 + libmei/mei/mei-verovio_compiled.odd | 6 ++++-- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/libmei/dist/attconverter.cpp b/libmei/dist/attconverter.cpp index c55294f2735..513853fcca7 100644 --- a/libmei/dist/attconverter.cpp +++ b/libmei/dist/attconverter.cpp @@ -3995,6 +3995,7 @@ std::string AttConverterBase::BracketSpanLogFuncToStr(bracketSpanLog_FUNC data) case bracketSpanLog_FUNC_cross_rhythm: value = "cross-rhythm"; break; case bracketSpanLog_FUNC_ligature: value = "ligature"; break; case bracketSpanLog_FUNC_analytical: value = "analytical"; break; + case bracketSpanLog_FUNC_phrase: value = "phrase"; break; case bracketSpanLog_FUNC_uspecified: value = "uspecified"; break; default: LogWarning("Unknown value '%d' for att.bracketSpan.log@func", data); @@ -4010,6 +4011,7 @@ bracketSpanLog_FUNC AttConverterBase::StrToBracketSpanLogFunc(const std::string if (value == "cross-rhythm") return bracketSpanLog_FUNC_cross_rhythm; if (value == "ligature") return bracketSpanLog_FUNC_ligature; if (value == "analytical") return bracketSpanLog_FUNC_analytical; + if (value == "phrase") return bracketSpanLog_FUNC_phrase; if (value == "uspecified") return bracketSpanLog_FUNC_uspecified; if (logWarning && !value.empty()) LogWarning("Unsupported value '%s' for att.bracketSpan.log@func", value.c_str()); diff --git a/libmei/dist/atttypes.h b/libmei/dist/atttypes.h index cf3c7c6347f..89c73a8369b 100644 --- a/libmei/dist/atttypes.h +++ b/libmei/dist/atttypes.h @@ -1873,6 +1873,7 @@ enum bracketSpanLog_FUNC : int8_t { bracketSpanLog_FUNC_cross_rhythm, bracketSpanLog_FUNC_ligature, bracketSpanLog_FUNC_analytical, + bracketSpanLog_FUNC_phrase, bracketSpanLog_FUNC_uspecified, bracketSpanLog_FUNC_MAX }; diff --git a/libmei/mei/mei-verovio_compiled.odd b/libmei/mei/mei-verovio_compiled.odd index d74d8f2355f..11f33ab283e 100644 --- a/libmei/mei/mei-verovio_compiled.odd +++ b/libmei/mei/mei-verovio_compiled.odd @@ -4199,9 +4199,11 @@ Represents a ligature in the mensural notation source material. - Represents a ligature in the mensural notation source material. + Highlights a grouping of some sort. + + Marks a phrase. - Represents a ligature in the mensural notation source material. + Unspecified bracket. Logical domain attributes. From 1dca434550e345782d79e2a6fc61f5074e7a1f8a Mon Sep 17 00:00:00 2001 From: Klaus Rettinghaus Date: Mon, 25 Nov 2024 12:57:45 +0100 Subject: [PATCH 6/6] set phrase in humdrum --- src/iohumdrum.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/iohumdrum.cpp b/src/iohumdrum.cpp index 1a7373ae923..5e9e6b5b554 100644 --- a/src/iohumdrum.cpp +++ b/src/iohumdrum.cpp @@ -21245,6 +21245,7 @@ void HumdrumInput::processPhrases(hum::HTp phraseend) insertPhrase(bracket, phrasestart, phraseend, startmeasure, startchordsorted, endchordsorted, phrasestartnoteinfo, phraseendnoteinfo, ndex, phraseindex, i, j, startpitches, endpitches, indexused); + bracket->SetFunc(bracketSpanLog_FUNC_phrase); } } }