Kstars

TutorialPopup.qml
1// SPDX-FileCopyrightText: 2016 Artem Fedoskin <afedoskin3@gmail.com>
2// SPDX-License-Identifier: GPL-2.0-or-later
3
4import QtQuick 2.7
5
6import QtQuick.Controls 2.0
7import QtQuick.Controls.Material 2.0
8import QtQuick.Controls.Universal 2.0
9
10import QtQuick.Window 2.2 as Window
11import QtQuick.Layouts 1.1
12
13import "../../constants" 1.0
14import "../../modules"
15
16Popup {
17 id: studyMode
18 contentWidth: parent.width * 0.75
19
20 focus: true
21 modal: true
22
23 background: Rectangle {
24 color: Num.sysPalette.base
25 }
26
27 Column {
28 id: studyCol
29 width: parent.width
30 height: childrenRect.height
31
32 KSLabel {
33 width: parent.width
34 wrapMode: Text.Wrap
35 horizontalAlignment: Text.AlignHCenter
36 text: xi18n("Welcome to KStars Lite")
37 font.pointSize: 20
38 }
39
40 KSText {
41 width: parent.width
42 wrapMode: Text.Wrap
43 horizontalAlignment: Text.AlignHCenter
44 text: xi18n("KStars Lite is a free, open source, cross-platform Astronomy Software designed for mobile devices.")
45 }
46
47 KSText {
48 width: parent.width
49 wrapMode: Text.Wrap
50 horizontalAlignment: Text.AlignHCenter
51 text: xi18n("A quick tutorial will introduce you to main functions of KStars Lite")
52 }
53
54 Flow {
55 property int buttonWidth: children[0].width + children[1].width + spacing * 2
56 width: parent.width > buttonWidth ? buttonWidth : parent.width
57 spacing: 5
58 anchors.horizontalCenter: parent.horizontalCenter
59
60 Button {
61 text: xi18n("Close")
62 onClicked: askExitTutorial()
63 }
64
65 Button {
66 text: xi18n("Start tutorial")
67 onClicked: {
68 studyMode.close()
69 step1 = true
70 }
71 }
72 }
73 }
74}
QString xi18n(const char *text, const TYPE &arg...)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:04:46 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.