feat: add reusable AppWindow with theme defaults
This will simplify setup for any application without having to specify palette.
This commit is contained in:
@@ -0,0 +1,23 @@
|
|||||||
|
import QtQuick
|
||||||
|
import QtQuick.Controls.Basic
|
||||||
|
|
||||||
|
ApplicationWindow {
|
||||||
|
id: root
|
||||||
|
visible: true
|
||||||
|
|
||||||
|
palette {
|
||||||
|
accent: Theme.accent
|
||||||
|
dark: Theme.foreground
|
||||||
|
window: Theme.background
|
||||||
|
windowText: Theme.foreground
|
||||||
|
buttonText: Theme.foreground
|
||||||
|
base: Theme.muted
|
||||||
|
brightText: Theme.muted
|
||||||
|
text: Theme.foreground
|
||||||
|
button: Theme.accent
|
||||||
|
}
|
||||||
|
|
||||||
|
title: qsTr("Flowy")
|
||||||
|
width: 640
|
||||||
|
height: 480
|
||||||
|
}
|
||||||
@@ -19,6 +19,7 @@ set(plain_qml_files
|
|||||||
AppSubHeadline.qml
|
AppSubHeadline.qml
|
||||||
AppLabel.qml
|
AppLabel.qml
|
||||||
AppLogo.qml
|
AppLogo.qml
|
||||||
|
AppWindow.qml
|
||||||
)
|
)
|
||||||
set(qml_singletons
|
set(qml_singletons
|
||||||
Fonts.qml
|
Fonts.qml
|
||||||
|
|||||||
+1
-1
@@ -5,7 +5,7 @@ import DesignSystem
|
|||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import QtQuick.Controls.Basic
|
import QtQuick.Controls.Basic
|
||||||
|
|
||||||
ApplicationWindow {
|
AppWindow {
|
||||||
id: window
|
id: window
|
||||||
width: 640
|
width: 640
|
||||||
height: 480
|
height: 480
|
||||||
|
|||||||
Reference in New Issue
Block a user