-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstaffGamesConstants.h
95 lines (81 loc) · 2.55 KB
/
staffGamesConstants.h
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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
#ifndef STAFFGAMESCONSTANTS_H
#define STAFFGAMESCONSTANTS_H
#include <QString>
#include <QColor>
namespace titleStackedWidgetIndices{
const int title = 0;
const int users = 1;
const int userHome = 2;
const int shop = 3;
}
namespace gameStackedWidgetIndices{
const int game = 0;
const int won = 1;
}
namespace gamePrices{
const int noteFinderAll = 100;
const int noteFinderLines = 20;
const int noteFinderSpaces = 0;
}
namespace staffLayout{
const int blackLineHeight = 10;
const int whiteLineHeight = blackLineHeight*7;
}
namespace noteProperties{
const int noteDiameter = staffLayout::whiteLineHeight*1.1;
const int stemHeight = staffLayout::whiteLineHeight * 3;
const int noteThickness = staffLayout::blackLineHeight*0.8;
}
namespace staffLayout{
const int lineLength = 800;
const int ledgerLinelength = noteProperties::noteDiameter*4;
const int numStaffLines = 5;
const int onePixel = 1;
const int numBlackLedger = 3;
const int numLedgerNotes = numBlackLedger * 2; // number of black + white lines
const int upperBounds = -( (whiteLineHeight*numBlackLedger) + (blackLineHeight*numBlackLedger) );
const int lowerBounds = -upperBounds + ((whiteLineHeight*numStaffLines) + (blackLineHeight*numStaffLines));
}
namespace colours{
const QColor highlighted("lightseagreen");
const QColor incorrect(Qt::red);
const QColor correct(Qt::green);
const QColor crotchet(Qt::black);
const QColor note(Qt::white);
const QColor stem(Qt::black);
}
namespace trebleClef{
const int offsetX = -100;
const int offsetY = 50;
}
namespace propertyKeys{
const int type = 0;
const int name = type+1;
const int ledgerType = name+1;
const QString gameID = "gameID";
const QString userName = "userName";
const QString dynamicButton = "dynamicButton";
const QString titleLabel = "titleLabel";
}
namespace ledgerType{
const QString ledger = "ledger";
const QString stave = "stave";
}
namespace propertyTypes{
const QString whiteLineType = "whiteline";
const QString lineType = "line";
const QString noteType = "note";
const QString trebleType = "treble";
}
namespace gameIDs{
const int noteFinderAll = 0;
const int noteFinderLines = noteFinderAll + 1;
const int noteFinderSpaces = noteFinderLines + 1;
const int numGames = noteFinderSpaces + 1;
}
namespace userSettingsKeys{
const QString users = "users";
const QString totalBeats = "totalBeats";
const QString ownedGames = "ownedGames";
}
#endif // STAFFGAMESCONSTANTS_H