6import QtQuick.Controls 2.15 as QQC2
7import QtQuick.Window 2.15
8import QtQuick.Layouts 1.15
9import org.kde.kirigami 2.20 as Kirigami
10import org.kde.kirigamiaddons.components 1.0 as KirigamiComponents
11import org.kde.coreaddons as Core
13import "private" as Private
71 property var aboutData: Core.AboutData
79 property url getInvolvedUrl: aboutData.desktopFileName.startsWith(
"org.kde.") ?
"https://community.kde.org/Get_Involved" :
""
86 property url donateUrl: aboutData.desktopFileName.startsWith(
"org.kde.") ?
"https://www.kde.org/donate" :
""
88 title:
i18nd(
"kirigami-addons6",
"About %1", page.aboutData.displayName)
91 Layout.topMargin:
Kirigami.Units.gridUnit
95 Layout.fillWidth:
true
97 contentItem: RowLayout {
98 spacing:
Kirigami.Units.smallSpacing * 2
102 Layout.preferredHeight:
Kirigami.Units.iconSizes.huge
103 Layout.preferredWidth: height
104 Layout.maximumWidth: page.width / 3;
105 Layout.rightMargin:
Kirigami.Units.largeSpacing
106 source:
Kirigami.Settings.applicationWindowIcon || page.aboutData.programLogo || page.aboutData.programIconName || page.aboutData.componentName
110 Layout.fillWidth:
true
111 spacing:
Kirigami.Units.smallSpacing
114 Layout.fillWidth:
true
115 text: page.aboutData.displayName +
" " + page.aboutData.version
116 wrapMode: Text.WordWrap
120 Layout.fillWidth:
true
122 type:
Kirigami.Heading.Type.Secondary
123 wrapMode: Text.WordWrap
124 text: page.aboutData.shortDescription
133 id: copyrightDelegate
134 text:
i18nd(
"kirigami-addons6",
"Copyright")
135 descriptionItem.textFormat: Text.PlainText
136 description: aboutData.otherText + (aboutData.otherText.length > 0 ?
'\n' :
'')
137 + aboutData.copyrightStatement
142 title:
i18ndp(
"kirigami-addons6",
"License",
"Licenses", aboutData.licenses.length)
143 visible: aboutData.licenses.length
147 visible: aboutData.licenses.length
150 model: aboutData.licenses
153 Layout.fillWidth:
true
155 licenseSheet.text = modelData.text;
156 licenseSheet.title = modelData.name;
162 data: KirigamiComponents.MessageDialog {
165 property alias text: bodyLabel.text
167 parent: applicationWindow().overlay
174 contentItem: QQC2.ScrollView {
175 leftPadding:
Kirigami.Units.gridUnit
176 rightPadding:
Kirigami.Units.gridUnit
180 text: licenseSheet.text
189 Layout.topMargin:
Kirigami.Units.gridUnit
192 id: getInvolvedDelegate
193 text:
i18nd(
"kirigami-addons6",
"Homepage")
194 onClicked:
Qt.openUrlExternally(aboutData.homepage)
195 visible: aboutData.homepage.length > 0
199 above: getInvolvedDelegate
200 below: donateDelegate
201 visible: aboutData.homepage.length > 0
206 text:
i18nd(
"kirigami-addons6",
"Donate")
207 onClicked:
Qt.openUrlExternally(donateUrl + "?app=" + page.aboutData.componentName)
208 visible: donateUrl.toString().length > 0
212 above: donateDelegate
213 below: homepageDelegate
214 visible: donateUrl.toString().length > 0
219 text:
i18nd(
"kirigami-addons6",
"Get Involved")
220 onClicked:
Qt.openUrlExternally(page.getInvolvedUrl)
221 visible: page.getInvolvedUrl != ""
225 above: homepageDelegate
227 visible: page.getInvolvedUrl !=
""
232 readonly
property string theUrl: {
233 if (aboutData.bugAddress !==
"submit@bugs.kde.org") {
234 return aboutData.bugAddress
236 const elements = aboutData.productName.split(
'/');
238 if (elements.length === 2) {
239 url +=
"&component=" + elements[1];
244 text:
i18nd(
"kirigami-addons6",
"Report a bug")
245 onClicked:
Qt.openUrlExternally(theUrl)
246 visible: theUrl.length > 0
251 title:
i18nd(
"kirigami-addons6",
"Libraries in use")
252 visible:
Kirigami.Settings.information
256 visible:
Kirigami.Settings.information
259 model:
Kirigami.Settings.information
262 Layout.fillWidth:
true
268 model: aboutData.components
269 delegate: libraryDelegate
274 title:
i18nd(
"kirigami-addons6",
"Authors")
275 visible: aboutData.authors !== undefined && aboutData.authors.length > 0
279 visible: aboutData.authors !== undefined && aboutData.authors.length > 0
283 model: aboutData.authors
284 delegate: personDelegate
289 title:
i18nd(
"kirigami-addons6",
"Credits")
290 visible: aboutData.credits !== undefined && aboutData.credits.length > 0
294 visible: aboutData.credits !== undefined && aboutData.credits.length > 0
298 model: aboutData.credits
299 delegate: personDelegate
304 title:
i18nd(
"kirigami-addons6",
"Translators")
305 visible: aboutData.translators !== undefined && aboutData.translators.length > 0
309 visible: aboutData.translators !== undefined && aboutData.translators.length > 0
313 model: aboutData.translators
314 delegate: personDelegate
323 Layout.fillWidth:
true
325 contentItem: RowLayout {
326 spacing:
Kirigami.Units.smallSpacing * 2
328 KirigamiComponents.Avatar {
332 property bool hasRemoteAvatar:
false
333 implicitWidth:
Kirigami.Units.iconSizes.medium
334 implicitHeight: implicitWidth
336 source:
if (!!modelData.avatarUrl && modelData.avatarUrl.toString().startsWith(
'https://')) {
337 const url =
new URL(modelData.avatarUrl);
338 const params =
new URLSearchParams(url.search);
339 params.append(
"s", width);
340 url.search = params.toString();
348 Layout.fillWidth:
true
349 spacing:
Kirigami.Units.smallSpacing
352 Layout.fillWidth:
true
354 elide:
Text.ElideRight
358 id: internalDescriptionItem
359 Layout.fillWidth:
true
361 color:
Kirigami.Theme.disabledTextColor
363 elide:
Text.ElideRight
364 visible: text.length > 0
369 visible: typeof(modelData.ocsUsername) !==
"undefined" && modelData.ocsUsername.length > 0
370 icon.name:
"get-hot-new-stuff"
371 QQC2.ToolTip.delay:
Kirigami.Units.toolTipDelay
372 QQC2.ToolTip.visible: hovered
373 QQC2.ToolTip.text:
i18nd(
"kirigami-addons6",
"Visit %1's KDE Store page", modelData.name)
374 onClicked:
Qt.openUrlExternally("https:
378 visible: typeof(modelData.emailAddress) !==
"undefined" && modelData.emailAddress.length > 0
379 icon.name:
"mail-sent"
380 QQC2.ToolTip.delay:
Kirigami.Units.toolTipDelay
381 QQC2.ToolTip.visible: hovered
382 QQC2.ToolTip.text:
i18nd(
"kirigami-addons6",
"Send an email to %1", modelData.emailAddress)
383 onClicked:
Qt.openUrlExternally("mailto:%1".arg(modelData.emailAddress))
387 visible: typeof(modelData.webAddress) !==
"undefined" && modelData.webAddress.length > 0
389 QQC2.ToolTip.delay:
Kirigami.Units.toolTipDelay
390 QQC2.ToolTip.visible: hovered
391 QQC2.ToolTip.text: (typeof(modelData.webAddress) ===
"undefined" && modelData.webAddress.length > 0) ?
"" : modelData.webAddress
392 onClicked:
Qt.openUrlExternally(modelData.webAddress)
403 required property var modelData
405 Layout.fillWidth: true
407 contentItem: RowLayout {
411 Layout.fillWidth: true
415 Layout.fillWidth: true
416 text: delegate.modelData.
name +
' ' + delegate.modelData.
version
421 id: internalDescriptionItem
422 Layout.fillWidth: true
423 text: delegate.modelData.description
424 color:
Kirigami.Theme.disabledTextColor
427 visible: text.length > 0
432 visible: modelData.licenses !== 0
437 QQC2.
ToolTip.text: !visible ?
"" : delegate.modelData.licenses.
name
442 parent: applicationWindow().overlay
449 title: delegate.modelData.licenses.
name
457 text: delegate.modelData.licenses.text
464 onClicked: licenseSheet.
open()
468 visible: typeof(modelData.webAddress) !==
"undefined" && modelData.webAddress.length > 0
472 QQC2.
ToolTip.text: (typeof(modelData.webAddress) ===
"undefined" && modelData.webAddress.length > 0) ?
"" : modelData.webAddress
473 onClicked:
Qt.openUrlExternally(modelData.webAddress)
A scrollable page used as a container for one or more FormCards.
A Form delegate that corresponds to a text label and a description.
A dialog to show a message.
QString i18ndp(const char *domain, const char *singular, const char *plural, const TYPE &arg...)
QString i18nd(const char *domain, const char *text, const TYPE &arg...)
KDB_EXPORT KDbVersionInfo version()
QString name(StandardShortcut id)
const QList< QKeySequence > & open()