Improving ThanksTo (to add scrolling)
This commit is contained in:
parent
7b76a8fe08
commit
e3eea751cb
1 changed files with 260 additions and 237 deletions
|
@ -28,12 +28,13 @@ import QtQuick.Controls
|
||||||
\sa LogarithmPlotter
|
\sa LogarithmPlotter
|
||||||
*/
|
*/
|
||||||
BaseDialog {
|
BaseDialog {
|
||||||
id: about
|
id: thanks
|
||||||
title: qsTr("Thanks and Contributions - LogarithmPlotter")
|
title: qsTr("Thanks and Contributions - LogarithmPlotter")
|
||||||
width: 450
|
width: 450
|
||||||
minimumHeight: 710
|
minimumHeight: 600
|
||||||
|
|
||||||
|
ScrollView {
|
||||||
|
|
||||||
Column {
|
|
||||||
anchors {
|
anchors {
|
||||||
top: parent.top;
|
top: parent.top;
|
||||||
left: parent.left;
|
left: parent.left;
|
||||||
|
@ -41,10 +42,16 @@ BaseDialog {
|
||||||
right: parent.right;
|
right: parent.right;
|
||||||
topMargin: margin;
|
topMargin: margin;
|
||||||
leftMargin: margin;
|
leftMargin: margin;
|
||||||
bottomMargin: margin;
|
bottomMargin: margin+30;
|
||||||
rightMargin: margin;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Column {
|
||||||
|
|
||||||
|
anchors {
|
||||||
|
left: parent.left;
|
||||||
|
}
|
||||||
|
|
||||||
|
width: thanks.width - 2*margin
|
||||||
spacing: 10
|
spacing: 10
|
||||||
|
|
||||||
ListView {
|
ListView {
|
||||||
|
@ -199,51 +206,64 @@ BaseDialog {
|
||||||
|
|
||||||
model: ListModel {
|
model: ListModel {
|
||||||
Component.onCompleted: {
|
Component.onCompleted: {
|
||||||
append({
|
const authors = {
|
||||||
tranName: '🇬🇧 ' + qsTr('English'),
|
Ad5001: {
|
||||||
link: 'https://hosted.weblate.org/projects/logarithmplotter/logarithmplotter/en/',
|
|
||||||
authors: [{
|
|
||||||
authorLine: 'Ad5001',
|
authorLine: 'Ad5001',
|
||||||
email: 'mail@ad5001.eu',
|
email: 'mail@ad5001.eu',
|
||||||
website: 'https://ad5001.eu',
|
website: 'https://ad5001.eu',
|
||||||
websiteName: qsTr('Website')
|
websiteName: qsTr('Website')
|
||||||
}]
|
},
|
||||||
|
Ovari: {
|
||||||
|
authorLine: 'Óvári',
|
||||||
|
website: 'https://github.com/ovari',
|
||||||
|
websiteName: qsTr('Github')
|
||||||
|
},
|
||||||
|
comradekingu: {
|
||||||
|
authorLine: 'Allan Nordhøy',
|
||||||
|
website: 'https://github.com/comradekingu',
|
||||||
|
websiteName: qsTr('Github')
|
||||||
|
},
|
||||||
|
IngrownMink4: {
|
||||||
|
authorLine: 'IngrownMink4',
|
||||||
|
website: 'https://github.com/IngrownMink4',
|
||||||
|
websiteName: qsTr('Github')
|
||||||
|
},
|
||||||
|
gallegonovato: {
|
||||||
|
authorLine: 'gallegonovato',
|
||||||
|
website: '',
|
||||||
|
websiteName: ''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
append({
|
||||||
|
tranName: '🇬🇧 ' + qsTr('English'),
|
||||||
|
link: 'https://hosted.weblate.org/projects/logarithmplotter/logarithmplotter/en/',
|
||||||
|
authors: [authors.Ad5001]
|
||||||
})
|
})
|
||||||
append({
|
append({
|
||||||
tranName: '🇫🇷 ' + qsTr('French'),
|
tranName: '🇫🇷 ' + qsTr('French'),
|
||||||
link: 'https://hosted.weblate.org/projects/logarithmplotter/logarithmplotter/fr/',
|
link: 'https://hosted.weblate.org/projects/logarithmplotter/logarithmplotter/fr/',
|
||||||
authors: [{
|
authors: [authors.Ad5001]
|
||||||
authorLine: 'Ad5001',
|
|
||||||
website: 'https://ad5001.eu',
|
|
||||||
websiteName: qsTr('Website')
|
|
||||||
}]
|
|
||||||
})
|
})
|
||||||
append({
|
append({
|
||||||
tranName: '🇩🇪 ' + qsTr('German'),
|
tranName: '🇩🇪 ' + qsTr('German'),
|
||||||
link: 'https://hosted.weblate.org/projects/logarithmplotter/logarithmplotter/de/',
|
link: 'https://hosted.weblate.org/projects/logarithmplotter/logarithmplotter/de/',
|
||||||
authors: [{
|
authors: [authors.Ad5001]
|
||||||
authorLine: 'Ad5001',
|
|
||||||
website: 'https://ad5001.eu',
|
|
||||||
websiteName: qsTr('Website')
|
|
||||||
}]
|
|
||||||
})
|
})
|
||||||
append({
|
append({
|
||||||
tranName: '🇭🇺 ' + qsTr('Hungarian'),
|
tranName: '🇭🇺 ' + qsTr('Hungarian'),
|
||||||
link: 'https://hosted.weblate.org/projects/logarithmplotter/logarithmplotter/hu/',
|
link: 'https://hosted.weblate.org/projects/logarithmplotter/logarithmplotter/hu/',
|
||||||
authors: [{
|
authors: [authors.Ovari]
|
||||||
authorLine: 'Óvári',
|
|
||||||
website: 'https://github.com/ovari',
|
|
||||||
websiteName: qsTr('Github')
|
|
||||||
}]
|
|
||||||
})
|
})
|
||||||
append({
|
append({
|
||||||
tranName: '🇳🇴 ' + qsTr('Norwegian'),
|
tranName: '🇳🇴 ' + qsTr('Norwegian'),
|
||||||
link: 'https://hosted.weblate.org/projects/logarithmplotter/logarithmplotter/no/',
|
link: 'https://hosted.weblate.org/projects/logarithmplotter/logarithmplotter/no/',
|
||||||
authors: [{
|
authors: [authors.comradekingu, authors.Ad5001]
|
||||||
authorLine: 'Allan Nordhøy',
|
})
|
||||||
website: 'https://github.com/comradekingu',
|
append({
|
||||||
websiteName: qsTr('Github')
|
tranName: '🇳🇴 ' + qsTr('Spanish'),
|
||||||
}]
|
link: 'https://hosted.weblate.org/projects/logarithmplotter/logarithmplotter/es/',
|
||||||
|
authors: [authors.IngrownMink4, authors.gallegonovato]
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -305,7 +325,7 @@ BaseDialog {
|
||||||
Label {
|
Label {
|
||||||
id: tranAuthorName
|
id: tranAuthorName
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: buttons.left
|
//anchors.right: buttons.left
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
wrapMode: Text.WordWrap
|
wrapMode: Text.WordWrap
|
||||||
font.pixelSize: 14
|
font.pixelSize: 14
|
||||||
|
@ -314,13 +334,15 @@ BaseDialog {
|
||||||
|
|
||||||
Row {
|
Row {
|
||||||
id: buttons
|
id: buttons
|
||||||
anchors.right: parent.right
|
anchors.left: tranAuthorName.right
|
||||||
|
anchors.leftMargin: 10
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
height: 30
|
height: 30
|
||||||
spacing: 10
|
spacing: 10
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
text: websiteName
|
text: websiteName
|
||||||
|
visible: websiteName !== ""
|
||||||
icon.name: 'web-browser'
|
icon.name: 'web-browser'
|
||||||
height: parent.height
|
height: parent.height
|
||||||
onClicked: Qt.openUrlExternally(website)
|
onClicked: Qt.openUrlExternally(website)
|
||||||
|
@ -332,3 +354,4 @@ BaseDialog {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in a new issue