@ -16,6 +16,7 @@
* You should have received a copy of the GNU General Public License
* along with Calamares . If not , see < http: / / w w w . g n u . o r g / l i c e n s e s / > .
* /
import io . calamares . core 1.0
import io . calamares . ui 1.0
import QtQuick 2.10
@ -29,21 +30,21 @@ Page
{
id: welcome
header: Item
{
header: Item {
width: parent . width
height: parent . height
Text
{
Text {
id: welcomeTopText
anchors.horizontalCenter: parent . horizontalCenter
anchors.top: parent . top
horizontalAlignment: Text . AlignHCenter
padding: 40
/ / I n Q M L , Q S t r i n g : : a r g ( ) o n l y t a k e s o n e a r g u m e n t
text: qsTr ( "<h3>Welcome to the %1 <quote>%2</quote> installer</h3>" ) . arg ( Branding . string ( Branding . ProductName ) ) . arg ( Branding . string ( Branding . Version ) )
text: qsTr ( " < h3 > Welcome to the % 1 < quote > % 2 < / q u o t e > i n s t a l l e r < / h 3 >
< p > This program will ask you some questions and set up % 1 on your computer . < / p > " ) . a r g ( B r a n d i n g . s t r i n g ( B r a n d i n g . P r o d u c t N a m e ) ) . a r g ( B r a n d i n g . s t r i n g ( B r a n d i n g . V e r s i o n ) )
}
Image
{
Image {
id: welcomeImage
anchors.centerIn: parent
/ / i m a g e P a t h ( ) r e t u r n s a f u l l p a t h n a m e , s o m a k e i t r e f e r t o t h e f i l e s y s t e m
@ -55,36 +56,31 @@ Page
fillMode: Image . PreserveAspectFit
}
RowLayout
{
RowLayout {
id: buttonBar
width: parent . width
width: parent . width / 1.5
height: 64
anchors.bottom: parent . bottom
anchors.horizontalCenter: parent . horizontalCenter
spacing: Kirigami . Units . largeSpacing * 2
/ * T r a d i t i o n a l l y C a l a m a r e s h a s h a d a n " A b o u t " b u t t o n t h a t t a l k s a b o u t
* Calamares itself , which just isn ' t a very useful thing in someone
* else ' s installation ISO .
* /
Button
{
Button {
Layout.fillWidth: true
text: qsTr ( "About" )
icon.name: "dialog-information"
Kirigami.Theme.backgroundColor: Qt . rgba ( Kirigami . Theme . backgroundColor . r , Kirigami . Theme . backgroundColor . g , Kirigami . Theme . backgroundColor . b , 0.4 )
Kirigami.Theme.textColor: Kirigami . Theme . textColor
visible: fals e
visible: tru e
onClicked: {
/ / o n C l i c k e d : l o a d . s o u r c e = " f i l e : / u s r / s h a r e / c a l a m a r e s / b r a n d i n g / ka o s _ b r a n d i n g / s h o w . q m l "
/ / o n C l i c k e d : l o a d . s o u r c e = " f i l e : / u s r / s h a r e / c a l a m a r e s / b r a n d i n g / de f a u l t / s h o w . q m l "
onClicked: load . source = "about.qml"
}
}
Button
{
Button {
Layout.fillWidth: true
text: qsTr ( "Support" )
icon.name: "system-help"
@ -94,8 +90,8 @@ Page
visible: config . supportUrl !== ""
onClicked: Qt . openUrlExternally ( config . supportUrl )
}
Button
{
Button {
Layout.fillWidth: true
text: qsTr ( "Known issues" )
icon.name: "tools-report-bug"
@ -105,8 +101,8 @@ Page
visible: config . knownIssuesUrl !== ""
onClicked: Qt . openUrlExternally ( config . knownIssuesUrl )
}
Button
{
Button {
Layout.fillWidth: true
text: qsTr ( "Release notes" )
icon.name: "folder-text"
@ -116,8 +112,8 @@ Page
visible: config . releaseNotesUrl !== ""
onClicked: Qt . openUrlExternally ( config . releaseNotesUrl )
}
Button
{
Button {
Layout.fillWidth: true
text: qsTr ( "Donate" )
icon.name: "taxes-finances"
@ -128,8 +124,41 @@ Page
onClicked: Qt . openUrlExternally ( config . donateUrl )
}
}
Loader
{
RowLayout {
id: languageBar
width: parent . width / 1.2
height: 48
anchors.bottom: parent . bottom
anchors.bottomMargin: parent . height / 7
anchors.horizontalCenter: parent . horizontalCenter
spacing: Kirigami . Units . largeSpacing * 4
Rectangle {
width: parent . width
Layout.fillWidth: true
focus: true
Image {
id: image
height: 48
fillMode: Image . PreserveAspectFit
source: "img/language-icon-48px.png"
}
ComboBox {
id: languages
anchors.left: image . right
width: languageBar . width / 1.1
textRole: "label"
currentIndex: 4 / / m o d e l . c u r r e n t I n d e x
model: config . languagesModel
onCurrentIndexChanged: console . debug ( currentText , currentIndex )
}
}
}
Loader {
id:load
anchors.fill: parent
}