Cyberpunk Rainmeter HUD: completed build, Rainmeter Y-positioning gotcha, lock screen update

This commit is contained in:
kenpat 2026-06-12 01:55:04 -05:00
parent f56f93c19c
commit 00145b1657

View file

@ -26,9 +26,6 @@ memory setup that motivated adding this command to the homelab quick reference.
- Current scrape jobs: `t14-node` (monk's own node-exporter container) and
`kscloud1-node` (kscloud1 node-exporter, public IP - do not commit this IP anywhere).
Config lives at `~/kitestacks-live/docker/prometheus/prometheus.yml` on monk.
- samurai has NO exporter yet - needs windows_exporter installed (port 9182) and a
new `samurai-node` scrape job targeting `100.74.0.109:9182` added to prometheus.yml.
- Neither Rainmeter nor a windows_exporter is installed on samurai yet.
- Wallpaper Engine IS installed, but at a non-default Steam location:
`C:\Program Files (x86)\steam2\steamapps\common\wallpaper_engine` (note "steam2" dir name).
- monk also runs `kitestacks-metrics-api` (FastAPI/psutil, source at
@ -42,3 +39,54 @@ memory setup that motivated adding this command to the homelab quick reference.
added as a Host alias in samurai's ~/.ssh/config. Separate from the
`100.85.209.116` config block used for Forgejo git (port 2222, user git,
id_ed25519_forgejo) - both entries must coexist, do not collapse them.
## STATUS: Built and working (2026-06-12)
Both Rainmeter skins are live, persisted in `Rainmeter.ini`, and Rainmeter is set
to launch at login (added to `HKCU\...\CurrentVersion\Run`). windows_exporter
service confirmed `Running`/`Automatic`, `samurai-node` Prometheus job confirmed up.
- Skins live under `Documents\Rainmeter\Skins\KiteStacks\`:
- `Metrics\Metrics.ini` - "KITESTACKS NODES" panel, 480x373, polls
`fetch-metrics.ps1` (RunCommand plugin, 60s) which queries Prometheus and
writes `metrics.json`; WebParser reads it. Shows CPU/RAM/Disk bars +
ONLINE/OFFLINE per host for samurai/monk/kscloud1.
- `Commands\Commands.ini` - renders `~/obsidian-vault/Homelab Commands/Quick
Reference.md` as a single-column cyberpunk text panel (484x557). Regenerate
after editing the source doc with `Commands\regen-commands.ps1`, then
`Rainmeter.exe "[!Refresh \"KiteStacks\Commands\"]"`.
- `Variables.inc` (shared colors/fonts) included via `..\Variables.inc`.
- Window positions: Commands at (0,20), Metrics at (500,20) on the PRIMARY
monitor, which is **1536x864** (DISPLAY14, at virtual-screen origin (0,0)),
NOT the 1920x1080 secondary monitor (DISPLAY13, at X=-1920..0). Always check
`[System.Windows.Forms.Screen]::AllScreens` before reasoning about coordinates
- GetWindowRect-based tools report positions in this virtual-screen space.
- **Critical Rainmeter gotcha**: a plain `Y=10` on a meter is NOT absolute - it's
relative to the previous meter in file order (previous.bottom + 10), even for
the very first content meter (previous = whatever IMAGE/background meter
precedes it). This caused the Commands panel to balloon to 1240x1356 over
many iterations. Fix: drop separate BorderFrame/Background IMAGE meters;
use `[Rainmeter] BackgroundMode=2` + `SolidColor=R,G,B,A` for the panel
background instead (auto-sized to content bounding box). Single-column layout
only - a 2-column layout re-triggers the same chaining bug because the second
column's first meter still chains off the first column's last meter.
- **Encoding gotcha**: Rainmeter reads `.inc` files as ANSI, so UTF-8 multi-byte
chars (em dash, box-drawing ├└─, arrows →, smart quotes) become mojibake.
`regen-commands.ps1` now replaces these with ASCII equivalents (`-`, `|`/`\`,
`->`, straight quotes) before writing the .inc.
## Lock screen (2026-06-12)
kenpat asked to also update the Windows lock screen to match. Used the
Wallpaper Engine background kenpat had just subscribed to (Workshop item
2323323193, "Cyberpunk City w/ System 24h Clock... | Skeor") - copied its
`preview.jpg` to `C:\Users\Kenny\Pictures\KiteStacks\lockscreen-cyberpunk.jpg`
and set it via `HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\PersonalizationCSP`
(`LockScreenImagePath`/`LockScreenImageUrl`/`LockScreenImageStatus=1`). Note:
this is the MDM/CSP-style override - it greys out the lock screen picture picker
in Settings > Personalization. To let kenpat pick a different lock screen image
via Settings later, these 3 registry values need to be deleted first.
## Remaining / not done
- Wallpaper Engine background itself: kenpat picks/applies it manually (Rainmeter
renders on top automatically via `WindowZPosition=-2`/OnDesktop).
- "keep track of token and token limit per session always" - kenpat asked for
this as a standing behavior but it hasn't been set up as anything concrete yet.