From 691de7824d1924ffad2058d92c1f5d7556b60b59 Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Mon, 19 Aug 2019 15:52:13 +0800 Subject: Awal halaman masuk --- .gitignore | 1 + Login.qml | 6 ++++++ LoginForm.ui.qml | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ kelakon.pro | 6 ++++++ kelakon.qrc | 7 +++++++ main.cxx | 11 +++++++++++ main.qml | 11 +++++++++++ 7 files changed, 101 insertions(+) create mode 100644 .gitignore create mode 100644 Login.qml create mode 100644 LoginForm.ui.qml create mode 100644 kelakon.pro create mode 100644 kelakon.qrc create mode 100644 main.cxx create mode 100644 main.qml diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..dd07bff --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +build-* diff --git a/Login.qml b/Login.qml new file mode 100644 index 0000000..495df70 --- /dev/null +++ b/Login.qml @@ -0,0 +1,6 @@ +import QtQuick 2.12 + +LoginForm { + width: appWindow.width + height: appWindow.height +} diff --git a/LoginForm.ui.qml b/LoginForm.ui.qml new file mode 100644 index 0000000..1ee1bfb --- /dev/null +++ b/LoginForm.ui.qml @@ -0,0 +1,59 @@ +import QtQuick 2.12 +import QtQuick.Layouts 1.1 +import QtQuick.Controls 2.12 + +Rectangle { + width: 363 + height: 628 + color: "#ffffff" + property alias emailButton: emailButton + property alias googleButton: googleButton + border.width: 0 + + Label { + x: 124 + y: 158 + width: 74 + height: 28 + text: qsTr("kelakon") + font.pointSize: 16 + anchors.horizontalCenterOffset: 0 + anchors.horizontalCenter: parent.horizontalCenter + } + + RowLayout { + x: 34 + y: 419 + width: googleButton.width + height: googleButton.height + anchors.horizontalCenterOffset: 0 + anchors.horizontalCenter: parent.horizontalCenter + } + + Button { + id: googleButton + x: 31 + y: 419 + width: 296 + height: 50 + text: qsTr("Continue with Google") + spacing: 4 + anchors.bottomMargin: 31 + anchors.bottom: emailButton.top + anchors.horizontalCenterOffset: 0 + anchors.horizontalCenter: parent.horizontalCenter + } + + Button { + id: emailButton + x: 41 + y: 493 + width: 296 + height: 50 + text: qsTr("Continue with E-mail") + anchors.bottom: parent.bottom + anchors.bottomMargin: 80 + anchors.left: parent.left + anchors.leftMargin: 34 + } +} diff --git a/kelakon.pro b/kelakon.pro new file mode 100644 index 0000000..fb0d403 --- /dev/null +++ b/kelakon.pro @@ -0,0 +1,6 @@ +QT += quickcontrols2 + +SOURCES += \ + main.cxx + +RESOURCES += kelakon.qrc diff --git a/kelakon.qrc b/kelakon.qrc new file mode 100644 index 0000000..a2a6866 --- /dev/null +++ b/kelakon.qrc @@ -0,0 +1,7 @@ + + + main.qml + Login.qml + LoginForm.ui.qml + + diff --git a/main.cxx b/main.cxx new file mode 100644 index 0000000..94f8599 --- /dev/null +++ b/main.cxx @@ -0,0 +1,11 @@ +#include +#include + +int main(int argc, char* argv[]) +{ + QGuiApplication::setAttribute(Qt::AA_EnableHighDpiScaling); + QGuiApplication app(argc, argv); + QQmlApplicationEngine engine; + engine.load(QUrl(QStringLiteral("qrc:/main.qml"))); + return app.exec(); +} diff --git a/main.qml b/main.qml new file mode 100644 index 0000000..fcf3a4d --- /dev/null +++ b/main.qml @@ -0,0 +1,11 @@ +import QtQuick 2.12 +import QtQuick.Controls 2.12 + +ApplicationWindow { + id: appWindow + width: 362 + height: 628 + visible: true + + Login {} +} -- cgit v1.2.3