native: add default qt projeckt
This commit is contained in:
parent
e93388066f
commit
d964cdfa4b
18 changed files with 852 additions and 0 deletions
19
native/QTprojeckt/NativGuiAlisa/content/App.qml
Normal file
19
native/QTprojeckt/NativGuiAlisa/content/App.qml
Normal file
|
@ -0,0 +1,19 @@
|
|||
// Copyright (C) 2021 The Qt Company Ltd.
|
||||
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
|
||||
|
||||
import QtQuick 6.2
|
||||
import NativGuiAlisa
|
||||
|
||||
Window {
|
||||
width: mainScreen.width
|
||||
height: mainScreen.height
|
||||
|
||||
visible: true
|
||||
title: "NativGuiAlisa"
|
||||
|
||||
Screen01 {
|
||||
id: mainScreen
|
||||
}
|
||||
|
||||
}
|
||||
|
14
native/QTprojeckt/NativGuiAlisa/content/CMakeLists.txt
Normal file
14
native/QTprojeckt/NativGuiAlisa/content/CMakeLists.txt
Normal file
|
@ -0,0 +1,14 @@
|
|||
### This file is automatically generated by Qt Design Studio.
|
||||
### Do not change
|
||||
|
||||
qt_add_library(content STATIC)
|
||||
qt6_add_qml_module(content
|
||||
URI "content"
|
||||
VERSION 1.0
|
||||
RESOURCE_PREFIX "/qt/qml"
|
||||
QML_FILES
|
||||
App.qml
|
||||
Screen01.ui.qml
|
||||
RESOURCES
|
||||
fonts/fonts.txt
|
||||
)
|
71
native/QTprojeckt/NativGuiAlisa/content/Screen01.ui.qml
Normal file
71
native/QTprojeckt/NativGuiAlisa/content/Screen01.ui.qml
Normal file
|
@ -0,0 +1,71 @@
|
|||
/*
|
||||
This is a UI file (.ui.qml) that is intended to be edited in Qt Design Studio only.
|
||||
It is supposed to be strictly declarative and only uses a subset of QML. If you edit
|
||||
this file manually, you might introduce QML code that is not supported by Qt Design Studio.
|
||||
Check out https://doc.qt.io/qtcreator/creator-quick-ui-forms.html for details on .ui.qml files.
|
||||
*/
|
||||
|
||||
import QtQuick 6.2
|
||||
import QtQuick.Controls 6.2
|
||||
import NativGuiAlisa
|
||||
|
||||
Rectangle {
|
||||
id: rectangle
|
||||
width: Constants.width
|
||||
height: Constants.height
|
||||
|
||||
color: Constants.backgroundColor
|
||||
|
||||
Button {
|
||||
id: button
|
||||
text: qsTr("Press me")
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
checkable: true
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
|
||||
Connections {
|
||||
target: button
|
||||
onClicked: animation.start()
|
||||
}
|
||||
}
|
||||
|
||||
Text {
|
||||
id: label
|
||||
text: qsTr("Hello NativGuiAlisa")
|
||||
anchors.top: button.bottom
|
||||
font.family: Constants.font.family
|
||||
anchors.topMargin: 45
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
|
||||
SequentialAnimation {
|
||||
id: animation
|
||||
|
||||
ColorAnimation {
|
||||
id: colorAnimation1
|
||||
target: rectangle
|
||||
property: "color"
|
||||
to: "#2294c6"
|
||||
from: Constants.backgroundColor
|
||||
}
|
||||
|
||||
ColorAnimation {
|
||||
id: colorAnimation2
|
||||
target: rectangle
|
||||
property: "color"
|
||||
to: Constants.backgroundColor
|
||||
from: "#2294c6"
|
||||
}
|
||||
}
|
||||
}
|
||||
states: [
|
||||
State {
|
||||
name: "clicked"
|
||||
when: button.checked
|
||||
|
||||
PropertyChanges {
|
||||
target: label
|
||||
text: qsTr("Button Checked")
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
1
native/QTprojeckt/NativGuiAlisa/content/fonts/fonts.txt
Normal file
1
native/QTprojeckt/NativGuiAlisa/content/fonts/fonts.txt
Normal file
|
@ -0,0 +1 @@
|
|||
Fonts in this folder are loaded automatically.
|
Loading…
Add table
Add a link
Reference in a new issue