aboutsummaryrefslogtreecommitdiffstats
path: root/desktop/modules/sonix/BootlogoCanvas.qml
diff options
context:
space:
mode:
authorDanilo M. <danix@danix.xyz>2026-11-07 12:14:23 +0100
committerDanilo M. <danix@danix.xyz>2026-11-07 12:14:23 +0100
commit9aef136ab4c6af5590867e49fc46054d968f3043 (patch)
tree3ea0fb54a640d78af93dceee1f348e4002f93318 /desktop/modules/sonix/BootlogoCanvas.qml
parent6e0a5116660730920f2427af550ce9d4c17a5d85 (diff)
downloadquickshell-9aef136ab4c6af5590867e49fc46054d968f3043.tar.gz
quickshell-9aef136ab4c6af5590867e49fc46054d968f3043.zip
sonix: boot logo fixes from review, own HiBy R1 group
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'desktop/modules/sonix/BootlogoCanvas.qml')
-rw-r--r--desktop/modules/sonix/BootlogoCanvas.qml16
1 files changed, 9 insertions, 7 deletions
diff --git a/desktop/modules/sonix/BootlogoCanvas.qml b/desktop/modules/sonix/BootlogoCanvas.qml
index 309e9ad..6915dfc 100644
--- a/desktop/modules/sonix/BootlogoCanvas.qml
+++ b/desktop/modules/sonix/BootlogoCanvas.qml
@@ -74,7 +74,9 @@ Item {
x: canvas.cfg.x - width / 2
y: canvas.cfg.y - height / 2
- // The second colour: an offset copy behind, or Bungee Inline on top.
+ // The second colour: an offset copy behind the fill. For Bungee it is
+ // the Regular layer underneath, showing through the stripe Bungee
+ // Inline cuts out of each letter; the Inline layer on top is the fill.
Text {
visible: !label.layered
x: label.off.x
@@ -87,13 +89,13 @@ Item {
id: fillText
text: canvas.text
font { family: label.fam; pixelSize: canvas.cfg.size }
- color: canvas.colour(canvas.cfg.fill)
+ color: canvas.colour(label.layered ? canvas.cfg.second : canvas.cfg.fill)
}
Text {
visible: label.layered
text: canvas.text
font { family: fInline.name; pixelSize: canvas.cfg.size }
- color: canvas.colour(canvas.cfg.second)
+ color: canvas.colour(canvas.cfg.fill)
}
}
@@ -126,14 +128,14 @@ Item {
// Writes base + ".png" (the logo) and base + "-mask.png" (the text on
// transparency). cb(ok, error).
function save(base, cb) {
- canvas.grabToImage(r => {
+ if (!canvas.grabToImage(r => {
if (!r.saveToFile(base + ".png")) { cb(false, `Cannot write ${base}.png`); return; }
canvas.maskOnly = true;
- canvas.grabToImage(m => {
+ if (!canvas.grabToImage(m => {
canvas.maskOnly = false;
const ok = m.saveToFile(base + "-mask.png");
cb(ok, ok ? "" : `Cannot write ${base}-mask.png`);
- }, Qt.size(480, 800));
- }, Qt.size(480, 800));
+ }, Qt.size(480, 800))) { canvas.maskOnly = false; cb(false, "Cannot grab the mask"); }
+ }, Qt.size(480, 800))) cb(false, "Cannot grab the canvas");
}
}