add full proj

This commit is contained in:
2026-05-31 09:28:44 +02:00
commit f8a4536a02
26 changed files with 1307 additions and 0 deletions

43
widgets/Network.qml Normal file
View File

@@ -0,0 +1,43 @@
import QtQuick
import QtQuick.Layouts
import "../config"
import "../services"
// Down/up throughput on the active interface, with a wifi/ethernet icon.
Pill {
Text {
text: SysStats.iface.startsWith("wl") ? Icons.wifi : Icons.ethernet
font.family: Theme.monoFont
font.pixelSize: Theme.fontSize + 1
color: Theme.sky
Layout.alignment: Qt.AlignVCenter
}
// reserve the width of the widest rate string so values never shift
TextMetrics {
id: rateMetrics
font: rxText.font
text: Icons.down + " 99.9M"
}
Text {
id: rxText
text: Icons.down + " " + SysStats.fmtRate(SysStats.rxRate)
font.family: Theme.monoFont
font.pixelSize: Theme.fontSize - 1
color: Theme.green
horizontalAlignment: Text.AlignRight
Layout.alignment: Qt.AlignVCenter
Layout.preferredWidth: rateMetrics.advanceWidth
}
Text {
text: Icons.up + " " + SysStats.fmtRate(SysStats.txRate)
font.family: Theme.monoFont
font.pixelSize: Theme.fontSize - 1
color: Theme.peach
horizontalAlignment: Text.AlignRight
Layout.alignment: Qt.AlignVCenter
Layout.preferredWidth: rateMetrics.advanceWidth
}
}