fix instrument name format in score file
This commit is contained in:
parent
a87e541933
commit
aa107645aa
9 changed files with 17 additions and 16 deletions
|
@ -143,7 +143,7 @@ StringData *InstrumentData::stringData() const
|
|||
void StaffName::write(Xml& xml, const char* tag) const
|
||||
{
|
||||
if (!name.isEmpty())
|
||||
xml.tag(QString("%1 pos=\"%2\"").arg(tag).arg(pos), name);
|
||||
xml.writeXml(QString("%1 pos=\"%2\"").arg(tag).arg(pos), name);
|
||||
}
|
||||
|
||||
//---------------------------------------------------------
|
||||
|
|
|
@ -689,8 +689,9 @@ QString XmlReader::readXml()
|
|||
// writeXml
|
||||
//---------------------------------------------------------
|
||||
|
||||
void Xml::writeXml(const char* name, QString s)
|
||||
void Xml::writeXml(const QString& name, QString s)
|
||||
{
|
||||
QString ename(name.split(' ')[0]);
|
||||
putLevel();
|
||||
for (int i = 0; i < s.size(); ++i) {
|
||||
ushort c = s.at(i).unicode();
|
||||
|
@ -699,7 +700,7 @@ void Xml::writeXml(const char* name, QString s)
|
|||
}
|
||||
*this << "<" << name << ">";
|
||||
*this << s;
|
||||
*this << "</" << name << ">\n";
|
||||
*this << "</" << ename << ">\n";
|
||||
}
|
||||
|
||||
//---------------------------------------------------------
|
||||
|
|
|
@ -155,7 +155,7 @@ class Xml : public QTextStream {
|
|||
void tag(const char* name, const QString& s) { tag(name, QVariant(s)); }
|
||||
void tag(const char* name, const QWidget*);
|
||||
|
||||
void writeXml(const char* tag, QString s);
|
||||
void writeXml(const QString&, QString s);
|
||||
void dump(int len, const unsigned char* p);
|
||||
|
||||
static QString xmlString(const QString&);
|
||||
|
|
|
@ -79,8 +79,8 @@
|
|||
</Staff>
|
||||
<trackName>Flute</trackName>
|
||||
<Instrument>
|
||||
<longName pos="0"><font face="Times New Roman"/>Flute</longName>
|
||||
<shortName pos="0"><font face="Times New Roman"/>Fl.</shortName>
|
||||
<longName pos="0"><font face="Times New Roman"/>Flute</longName>
|
||||
<shortName pos="0"><font face="Times New Roman"/>Fl.</shortName>
|
||||
<trackName>Flute</trackName>
|
||||
<minPitchP>59</minPitchP>
|
||||
<maxPitchP>98</maxPitchP>
|
||||
|
|
|
@ -81,8 +81,8 @@
|
|||
</Staff>
|
||||
<trackName>Piano</trackName>
|
||||
<Instrument>
|
||||
<longName pos="0"><font face="Times New Roman"/>Piano</longName>
|
||||
<shortName pos="0"><font face="Times New Roman"/>Pno.</shortName>
|
||||
<longName pos="0"><font face="Times New Roman"/>Piano</longName>
|
||||
<shortName pos="0"><font face="Times New Roman"/>Pno.</shortName>
|
||||
<trackName>Piano</trackName>
|
||||
<minPitchP>21</minPitchP>
|
||||
<maxPitchP>108</maxPitchP>
|
||||
|
|
|
@ -87,8 +87,8 @@
|
|||
</Staff>
|
||||
<trackName>Piano</trackName>
|
||||
<Instrument>
|
||||
<longName pos="0"><font face="Times New Roman"/>Piano</longName>
|
||||
<shortName pos="0"><font face="Times New Roman"/>Pno.</shortName>
|
||||
<longName pos="0"><font face="Times New Roman"/>Piano</longName>
|
||||
<shortName pos="0"><font face="Times New Roman"/>Pno.</shortName>
|
||||
<trackName>Piano</trackName>
|
||||
<minPitchP>21</minPitchP>
|
||||
<maxPitchP>108</maxPitchP>
|
||||
|
|
|
@ -83,8 +83,8 @@
|
|||
</Staff>
|
||||
<trackName>Voice</trackName>
|
||||
<Instrument>
|
||||
<longName pos="0"><font face="Times New Roman"/>Voice</longName>
|
||||
<shortName pos="0"><font face="Times New Roman"/>Vo.</shortName>
|
||||
<longName pos="0"><font face="Times New Roman"/>Voice</longName>
|
||||
<shortName pos="0"><font face="Times New Roman"/>Vo.</shortName>
|
||||
<trackName>Voice</trackName>
|
||||
<minPitchP>36</minPitchP>
|
||||
<maxPitchP>94</maxPitchP>
|
||||
|
|
|
@ -83,8 +83,8 @@
|
|||
</Staff>
|
||||
<trackName>Voice</trackName>
|
||||
<Instrument>
|
||||
<longName pos="0"><font face="Times New Roman"/>Voice</longName>
|
||||
<shortName pos="0"><font face="Times New Roman"/>Vo.</shortName>
|
||||
<longName pos="0"><font face="Times New Roman"/>Voice</longName>
|
||||
<shortName pos="0"><font face="Times New Roman"/>Vo.</shortName>
|
||||
<trackName>Voice</trackName>
|
||||
<minPitchP>36</minPitchP>
|
||||
<maxPitchP>94</maxPitchP>
|
||||
|
|
|
@ -85,8 +85,8 @@
|
|||
</Staff>
|
||||
<trackName>Piano</trackName>
|
||||
<Instrument>
|
||||
<longName pos="0"><font face="Times New Roman"/>Piano</longName>
|
||||
<shortName pos="0"><font face="Times New Roman"/>Pno.</shortName>
|
||||
<longName pos="0"><font face="Times New Roman"/>Piano</longName>
|
||||
<shortName pos="0"><font face="Times New Roman"/>Pno.</shortName>
|
||||
<trackName>Piano</trackName>
|
||||
<minPitchP>21</minPitchP>
|
||||
<maxPitchP>108</maxPitchP>
|
||||
|
|
Loading…
Reference in a new issue