Commit ab82deb2 authored by Andreas Cord-Landwehr's avatar Andreas Cord-Landwehr

Get ready to show an empty window.

Without crashing \o/
parent 125cc87e
......@@ -43,6 +43,7 @@ find_package(Qt5 REQUIRED COMPONENTS
Widgets
Sql
XmlPatterns
Qml
Quick
QuickWidgets
Test
......
......@@ -121,6 +121,7 @@ target_link_libraries(artikulate
artikulatelearnerprofile
artikulatesound
artikulatecore
Qt5::Qml
Qt5::Quick
Qt5::QuickWidgets
KF5::ConfigWidgets
......
......@@ -18,7 +18,6 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "application.h"
#include "mainwindow.h"
......@@ -59,7 +58,7 @@
#include <KDeclarative/KDeclarative>
#include <QGraphicsDropShadowEffect>
Application::Application(int argc, char **argv)
Application::Application(int& argc, char** argv)
: QApplication(argc, argv)
{
registerQmlTypes();
......
......@@ -29,10 +29,10 @@ class Application : public QApplication
Q_OBJECT
public:
explicit Application(int argc, char **argv);
explicit Application(int &argc, char **argv);
private:
void registerQmlTypes();
};
#endif // APPLICATION_H
#endif
......@@ -53,7 +53,7 @@ int main(int argc, char **argv)
Application app(argc, argv);
MainWindow * mainWindow = new MainWindow();
MainWindow *mainWindow = new MainWindow();
QSize size(800, 600);
mainWindow->setMinimumSize(size);
mainWindow->show();
......
......@@ -107,11 +107,13 @@ MainWindow::MainWindow()
}
// set initial view
rootObject()->setProperty("viewMode", Trainer);
// rootObject()->setProperty("viewMode", Trainer); //FIXME
// set font for the phrase in trainer to default from kcfg file
QObject *phraseText = rootObject()->findChild<QObject*>("phraseText");
phraseText->setProperty("font", Settings::trainingPhraseFont());
if (phraseText) {
phraseText->setProperty("font", Settings::trainingPhraseFont());
}
}
MainWindow::~MainWindow()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment