Kstars

Splash.qml
1// SPDX-FileCopyrightText: 2016 Artem Fedoskin <afedoskin3@gmail.com>
2// SPDX-License-Identifier: GPL-2.0-or-later
3
4import QtQuick 2.6
5import QtQuick.Window 2.2
6import "../constants"
7
8//Rectangle - to allow z-index ordering (for some reason it doesn't work with plain Item)
9Rectangle {
10 id: splash
11 signal timeout
12 state: "Inivisble"
13
14 Image {
15 id: splashBG
16 source: "../images/splash_bg.jpeg"
17 anchors {
18 fill: parent
19 }
20
21 fillMode: Image.PreserveAspectCrop
22
23 width: sourceSize.width/Num.pixelRatio
24 height: sourceSize.height/Num.pixelRatio
25
26 Image {
27 id: kdeLogo
28 source: "../images/kde-logo.png"
29 anchors {
30 right: parent.right
31 top: parent.top
32 margins: 15
33 }
34 }
35
36 Image {
37 id: splashLogo
38 source: "../images/splash.png"
39 anchors.centerIn: parent
40 }
41
42 Text {
43 id: progress
44 color: "#999"
45
46 anchors {
47 bottom: parent.bottom
48 horizontalCenter: parent.horizontalCenter
49 margins: 5
50 }
51 }
52 }
53
55 target: KStarsData
57 progress.text = text
58 }
59 }
60
62 target: KStarsLite
64 splash.state = "Visible"
65 }
67 splash.timeout()
68 splash.state = "Invisible"
69 }
70 }
71
72 states: [
73 State{
74 name: "Visible"
75 PropertyChanges{target: splash; opacity: 1.0}
76 PropertyChanges{target: splash; visible: true}
77 },
78 State{
79 name:"Invisible"
80 PropertyChanges{target: splash; opacity: 0.0}
81 PropertyChanges{target: splash; visible: false}
82 }
83 ]
84
85 transitions: [
87 from: "Visible"
88 to: "Invisible"
89
92 target: splash
93 property: "opacity"
94 duration: 800
95 easing.type: Easing.InOutQuad
96 }
98 target: splash
99 property: "visible"
100 duration: 0
101 }
102 }
103 }
104 ]
105}
106
KStarsData is the backbone of KStars.
Definition kstarsdata.h:72
This class loads QML files and connects SkyMapLite and KStarsData Unlike KStars class it is not a mai...
Definition kstarslite.h:47
QString name(StandardAction id)
QTextStream & right(QTextStream &stream)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri May 24 2024 11:49:22 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.