1
Fork 0
mirror of https://github.com/redstrate/Astra.git synced 2025-04-21 20:27:45 +00:00

Add simple username/password field

This commit is contained in:
Joshua Goins 2022-06-08 12:55:22 -04:00
parent 83be40cce1
commit a007f8567e

View file

@ -1,5 +1,5 @@
import QtQuick 2.7
import QtQuick.Controls 2.1
import QtQuick.Controls 2.15
import QtQuick.Window 2.0
ApplicationWindow {
@ -11,9 +11,40 @@ ApplicationWindow {
visible: true
Label {
text: "Hello, world!"
id: usernameLabel
anchors.horizontalCenter: parent.horizontalCenter
anchors.verticalCenter: parent.verticalCenter
text: "Username"
}
TextField {
id: usernameField
anchors.top: usernameLabel.bottom
}
Label {
id: passwordLabel
text: "Password"
anchors.top: usernameField.bottom
}
TextField {
id: passwordField
echoMode: TextInput.Password
anchors.top: passwordLabel.bottom
}
Button {
id: loginButton
text: "Login"
anchors.top: passwordField.bottom
onClicked: print("Hooray!");
}
}