-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
28 lines (23 loc) · 722 Bytes
/
main.cpp
File metadata and controls
28 lines (23 loc) · 722 Bytes
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
#include "mainwindow.h"
#include <QApplication>
#include <QtAwesome.h>
#include "helpers/viewhelper.h"
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
QFontDatabase database;
int id = database.addApplicationFont(":/resource/fonts/FontAwesome.otf");
viewHelper::setQtAwesome(new QtAwesome(QApplication::instance()));
viewHelper::awesome->initFontAwesome();
MainWindow w;
w.show();
QFile file(":/stylesheets/stylesheet.css");
if(file.open(QIODevice::ReadOnly | QIODevice::Text))
{
QByteArray data = file.readAll();
a.setStyleSheet(data);
w.setStyleSheet(data);
file.close();
}
return a.exec();
}