-
Notifications
You must be signed in to change notification settings - Fork 0
/
naheaderwizard.cpp
executable file
·65 lines (60 loc) · 2.56 KB
/
naheaderwizard.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
#include "naheaderwizard.h"
#include "ui_naheaderwizard.h"
NAHeaderWizard::NAHeaderWizard(QWidget *parent) :
QWizard(parent),
ui(new Ui::NAHeaderWizard)
{
ui->setupUi(this);
}
NAHeaderWizard::~NAHeaderWizard()
{
delete ui;
}
void NAHeaderWizard::accept()
{
header.append("name:"+ui->nameE->text()+";");
if (!ui->commentaryE->text().isEmpty())
header.append("commentary:"+ui->commentaryE->text()+";");
if (!ui->annotation1E->text().isEmpty())
header.append("annotation:"+ui->annotation1E->text()+";");
if (!ui->annotation2E->text().isEmpty())
header.append("annotation:"+ui->annotation2E->text()+";");
header.append("gregoriotex-font:"+ui->fontBox->currentText()+";");
QString initialStyle = tr("initial-style:%1;").arg(ui->initialBox->currentIndex());
header.append(initialStyle);
if (!ui->occasionE->text().isEmpty())
header.append("occasion:"+ui->occasionE->text()+";");
if (!ui->officePartE->text().isEmpty())
header.append("office-part:"+ui->officePartE->text()+";");
if (!ui->modeE->text().isEmpty())
header.append("mode:"+ui->modeE->text()+";");
if (!ui->meterE->text().isEmpty())
header.append("meter:"+ui->meterE->text()+";");
if (!ui->authorE->text().isEmpty())
header.append("author:"+ui->authorE->text()+";");
if (!ui->dateE->text().isEmpty())
header.append("date:"+ui->dateE->text()+";");
if (!ui->manuscriptE->text().isEmpty())
header.append("manuscript:"+ui->manuscriptE->text()+";");
if (!ui->referenceE->text().isEmpty())
header.append("manuscript-reference:"+ui->referenceE->text()+";");
if (!ui->storageE->text().isEmpty())
header.append("manuscript-storage-place:"+ui->storageE->text()+";");
if (!ui->bookE->text().isEmpty())
header.append("book:"+ui->bookE->text()+";");
if (!ui->arrangerE->text().isEmpty())
header.append("arranger:"+ui->arrangerE->text()+";");
if (!ui->transcriberE->text().isEmpty())
header.append("transcriber:"+ui->transcriberE->text()+";");
if (!ui->transcriptiondateE->text().isEmpty())
header.append("transcription-date:"+ui->transcriptiondateE->text()+";");
if (!ui->usernotesE->text().isEmpty())
header.append("user-notes:"+ui->usernotesE->text()+";");
if (!ui->gabccE->text().isEmpty())
header.append("gabc-copyright:"+ui->gabccE->text()+";");
if (!ui->scorecE->text().isEmpty())
header.append("score-copyright:"+ui->scorecE->text()+";");
header.append("%%");
header.append("");
QDialog::accept();
}