Files
clide/qml/Components/ClideAboutWindow.qml

70 lines
2.2 KiB
QML
Raw Permalink Normal View History

2026-02-08 21:25:03 +00:00
// SPDX-FileCopyrightText: 2026, Shaun Reed <shaunrd0@gmail.com>
//
// SPDX-License-Identifier: GNU General Public License v3.0 or later
2026-01-25 20:57:36 +00:00
import QtQuick
import QtQuick.Controls.Basic
import clide.module 1.0
2026-02-08 21:25:03 +00:00
import Logger 1.0
2026-01-25 20:57:36 +00:00
ApplicationWindow {
id: root
2026-02-08 21:25:03 +00:00
2026-01-25 20:57:36 +00:00
color: RustColors.gutter
2026-02-08 21:25:03 +00:00
// Create the window with no frame and keep it on top.
flags: Qt.Tool | Qt.FramelessWindowHint
height: 350
width: 450
visible: root.active
2026-01-25 20:57:36 +00:00
// Hide the window when it loses focus.
onActiveChanged: {
2026-02-08 21:25:03 +00:00
Logger.debug("Setting active: " + root.active)
if (!root.active) {
2026-01-25 20:57:36 +00:00
root.visible = false;
}
}
// Kilroy logo.
Image {
id: logo
anchors.left: parent.left
2026-02-08 21:25:03 +00:00
anchors.margins: 20
2026-01-25 20:57:36 +00:00
anchors.right: parent.right
anchors.top: parent.top
antialiasing: true
asynchronous: true
2026-02-08 21:25:03 +00:00
fillMode: Image.PreserveAspectFit
smooth: true
source: "qrc:/images/kilroy.png"
sourceSize.height: 80
sourceSize.width: 80
2026-01-25 20:57:36 +00:00
}
ScrollView {
anchors.bottom: parent.bottom
2026-02-08 21:25:03 +00:00
anchors.left: parent.left
2026-01-25 20:57:36 +00:00
anchors.margins: 20
2026-02-08 21:25:03 +00:00
anchors.right: parent.right
anchors.top: logo.bottom
2026-01-25 20:57:36 +00:00
TextArea {
2026-02-08 21:25:03 +00:00
antialiasing: true
background: null
color: RustColors.editor_text
horizontalAlignment: Text.AlignHCenter
readOnly: true
2026-01-25 20:57:36 +00:00
selectedTextColor: RustColors.editor_highlighted_text
selectionColor: RustColors.editor_highlight
2026-02-08 21:25:03 +00:00
text: qsTr("<h3>About CLIDE</h3>" + "<p>A simple text editor written in Rust and QML using CXX-Qt.</p>" + "<p>Personal website <a href=\"http://shaunreed.com\">shaunreed.com</a></p>" + "<p>Project notes <a href=\"http://knoats.com\">knoats.com</a></p>" + "<p>This project is developed at <a href=\"http://git.shaunreed.com/shaunrd0/clide\">git.shaunreed.com</a></p>" + "<p><a href=\"https://github.com/KDAB/cxx-qt\">KDAB CXX-Qt repository</a></p>" + "<p>Copyright (C) 2026 Shaun Reed, all rights reserved.</p>")
2026-01-25 20:57:36 +00:00
textFormat: Text.RichText
wrapMode: Text.WordWrap
onLinkActivated: function (link) {
2026-02-08 21:25:03 +00:00
Qt.openUrlExternally(link);
2026-01-25 20:57:36 +00:00
}
}
}
}