5
5
* MuseScore Studio
6
6
* Music Composition & Notation
7
7
*
8
- * Copyright (C) 2021 MuseScore Limited
8
+ * Copyright (C) 2025 MuseScore Limited
9
9
*
10
10
* This program is free software: you can redistribute it and/or modify
11
11
* it under the terms of the GNU General Public License version 3 as
@@ -98,9 +98,9 @@ uint32_t TablEdit::readUInt32()
98
98
99
99
// read sized and null-terminated utf8 text from the current position
100
100
101
- string TablEdit::readUtf8Text ()
101
+ std:: string TablEdit::readUtf8Text ()
102
102
{
103
- string result;
103
+ std:: string result;
104
104
uint16_t size = readUInt16 ();
105
105
for (uint16_t i = 0 ; i < size - 1 ; ++i) {
106
106
result += readUInt8 ();
@@ -113,7 +113,7 @@ string TablEdit::readUtf8Text()
113
113
// read sized and null-terminated utf8 text
114
114
// input is the position where the text's position in the file is stored
115
115
116
- string TablEdit::readUtf8TextIndirect (uint32_t positionOfPosition)
116
+ std:: string TablEdit::readUtf8TextIndirect (uint32_t positionOfPosition)
117
117
{
118
118
_file->seek (positionOfPosition);
119
119
uint32_t position = readUInt32 ();
@@ -184,17 +184,17 @@ static muse::draw::Color toColor(const int)
184
184
185
185
// create a VoiceAllocator for every instrument
186
186
187
- void TablEdit::initializeVoiceAllocators (vector<VoiceAllocator>& allocators)
187
+ void TablEdit::initializeVoiceAllocators (std:: vector<VoiceAllocator>& allocators)
188
188
{
189
189
for (size_t i = 0 ; i < tefInstruments.size (); ++i) {
190
190
VoiceAllocator allocator;
191
191
allocators.push_back (allocator);
192
192
}
193
193
}
194
194
195
- void TablEdit::allocateVoices (vector<VoiceAllocator>& allocators)
195
+ void TablEdit::allocateVoices (std:: vector<VoiceAllocator>& allocators)
196
196
{
197
- vector<const TefNote*> column;
197
+ std:: vector<const TefNote*> column;
198
198
int currentPosition { -1 };
199
199
engraving::part_idx_t currentPart { 0 };
200
200
for (const TefNote& tefNote : tefContents) {
@@ -308,7 +308,7 @@ void TablEdit::createContents()
308
308
return ;
309
309
}
310
310
311
- vector<VoiceAllocator> voiceAllocators;
311
+ std:: vector<VoiceAllocator> voiceAllocators;
312
312
initializeVoiceAllocators (voiceAllocators);
313
313
allocateVoices (voiceAllocators);
314
314
@@ -321,7 +321,7 @@ void TablEdit::createContents()
321
321
for (size_t k = 0 ; k < voiceContent.size (); ++k) {
322
322
LOGD (" - chord %zu" , k);
323
323
// tefNotes is either a rest or a chord of one or more notes
324
- const vector<const TefNote*>& tefNotes { voiceContent.at (k) };
324
+ const std:: vector<const TefNote*>& tefNotes { voiceContent.at (k) };
325
325
326
326
if (tefNotes.size () == 0 ) {
327
327
continue ; // shouldn't happen
@@ -505,7 +505,7 @@ void TablEdit::createNotesFrame()
505
505
vbox->setTick (mu::engraving::Fraction (0 , 1 )); // TODO find correct value (0/1 seems to work OK)
506
506
score->measures ()->add (vbox);
507
507
Text* s = Factory::createText (vbox, TextStyleType::FRAME);
508
- s->setPlainText (String::fromUtf8 (tefHeader.notes .c_str ()));
508
+ s->setPlainText (muse:: String::fromUtf8 (tefHeader.notes .c_str ()));
509
509
vbox->add (s);
510
510
}
511
511
}
@@ -515,7 +515,7 @@ void TablEdit::createParts()
515
515
for (const auto & instrument : tefInstruments) {
516
516
Part* part = new Part (score);
517
517
score->appendPart (part);
518
- String staffName { String::fromUtf8 (instrument.name .c_str ()) };
518
+ muse:: String staffName { muse:: String::fromUtf8 (instrument.name .c_str ()) };
519
519
part->setPartName (staffName);
520
520
part->setPlainLongName (staffName);
521
521
@@ -543,19 +543,19 @@ void TablEdit::createParts()
543
543
void TablEdit::createProperties ()
544
544
{
545
545
if (!tefHeader.title .empty ()) {
546
- score->setMetaTag (u" workTitle" , String::fromUtf8 (tefHeader.title .c_str ()));
546
+ score->setMetaTag (u" workTitle" , muse:: String::fromUtf8 (tefHeader.title .c_str ()));
547
547
}
548
548
if (!tefHeader.subTitle .empty ()) {
549
- score->setMetaTag (u" subtitle" , String::fromUtf8 (tefHeader.subTitle .c_str ()));
549
+ score->setMetaTag (u" subtitle" , muse:: String::fromUtf8 (tefHeader.subTitle .c_str ()));
550
550
}
551
551
if (!tefHeader.comment .empty ()) {
552
- score->setMetaTag (u" comment" , String::fromUtf8 (tefHeader.comment .c_str ()));
552
+ score->setMetaTag (u" comment" , muse:: String::fromUtf8 (tefHeader.comment .c_str ()));
553
553
}
554
554
if (!tefHeader.internetLink .empty ()) {
555
- score->setMetaTag (u" source" , String::fromUtf8 (tefHeader.internetLink .c_str ()));
555
+ score->setMetaTag (u" source" , muse:: String::fromUtf8 (tefHeader.internetLink .c_str ()));
556
556
}
557
557
if (!tefHeader.copyright .empty ()) {
558
- score->setMetaTag (u" copyright" , String::fromUtf8 (tefHeader.copyright .c_str ()));
558
+ score->setMetaTag (u" copyright" , muse:: String::fromUtf8 (tefHeader.copyright .c_str ()));
559
559
}
560
560
}
561
561
@@ -655,12 +655,12 @@ void TablEdit::createTitleFrame()
655
655
score->measures ()->add (vbox);
656
656
if (!tefHeader.title .empty ()) {
657
657
Text* s = Factory::createText (vbox, TextStyleType::TITLE);
658
- s->setPlainText (String::fromUtf8 (tefHeader.title .c_str ()));
658
+ s->setPlainText (muse:: String::fromUtf8 (tefHeader.title .c_str ()));
659
659
vbox->add (s);
660
660
}
661
661
if (!tefHeader.subTitle .empty ()) {
662
662
Text* s = Factory::createText (vbox, TextStyleType::SUBTITLE);
663
- s->setPlainText (String::fromUtf8 (tefHeader.subTitle .c_str ()));
663
+ s->setPlainText (muse:: String::fromUtf8 (tefHeader.subTitle .c_str ()));
664
664
vbox->add (s);
665
665
}
666
666
}
@@ -936,7 +936,7 @@ void TablEdit::readTefTexts()
936
936
_file->seek (position);
937
937
uint16_t numberOfTexts = readUInt16 ();
938
938
for (uint16_t i = 0 ; i < numberOfTexts; ++i) {
939
- string text { readUtf8Text () };
939
+ std:: string text { readUtf8Text () };
940
940
LOGD (" i %d text '%s'" , i, text.c_str ());
941
941
tefTexts.push_back (text);
942
942
}
0 commit comments