mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-09-18 14:32:36 +00:00
Design: a verb's address is data, so the toolbar widget can stop existing
snaporca-7ih's remaining half. Both flyout factories registered their verbs INSIDE the widget-building loop, so the ~40 retired tool buttons had to be constructed and then Hide()n: skipping construction would have deleted 42 offer verbs (26 fly:<family>#<row> + 16 Shift+keys) while their rows still rendered and did nothing when picked. Register first, build second. The addresses are pure data; the widget is one door onto them, not their owner. A family absent from kBarKeep now returns before any wxWindow is made. The keep-list stays a one-line data decision, not a structural one. And close the class of bug for good: the constructor now verifies, once, that every verb the atlas marks wired resolves to a real registration, logging each break and asserting in debug. Rows that render and do nothing have shipped three times (edit_feature and sk_move with action:null, then this) and are invisible from either side alone. Verified on the snaporca rig by walking the offer, not by reading the code — all four at-risk address kinds run with no widget behind them: fly:design_rect#2 drew an OBLIQUE rectangle (the third variant, not the family's first), key:S+E opened Extrude with its 10 mm gizmo, fly:material#4 opened Thicken. Hover hints, icons and nesting intact. This fork is code-identical here bar the two permitted DropDown divergences; it still owes a build of its own (snaporca-5pl). Two hints were wrong and are fixed: Cut said "Split the body with a plane", colliding with the Split verb one row away and pointing at a card for a value the canvas already offers as a draggable arrow; Split never said its plane comes from a picked face. Also, because it blocked the verification and will block the next one: gui-session.sh killed by full path while its own app_pid() matched by basename, so a differently-pathed instance survived, held the single-instance lock, and got reported as a healthy session — a Jul-30 binary nearly passed as this build. It now kills by basename and prints which binary is actually on screen. Traps 6 and 7 documented.
This commit is contained in:
@@ -121,3 +121,31 @@ invisible and the session hunts a phantom. Pass `BIN` explicitly:
|
||||
Note also that the GUI containers do **not** mount `scripts/`: `/OrcaSlicer/scripts` inside them
|
||||
is the baked copy, so a local edit to `gui-session.sh` has no effect until you
|
||||
`docker cp scripts/gui-session.sh <container>:/OrcaSlicer/scripts/`.
|
||||
|
||||
---
|
||||
|
||||
## Trap 6 — `src/Release/` resolves resources to `build/resources`, which may not exist
|
||||
|
||||
The binary derives `resources_dir()` from its own location, so the `src/Release/` one looks in
|
||||
`/OrcaSlicer/build/resources` while the packaged one looks inside `build/package/`. Only the
|
||||
packaging step creates the latter; nothing creates the former. Without it the app fails every
|
||||
`Failed to add custom font ".../build/resources/fonts/…"`, logs `Health check is not running`,
|
||||
and **exits 255 with nothing on stdout** — which reads exactly like a crash in whatever you just
|
||||
changed. Measured 2026-08-02: an hour was nearly spent bisecting a GUI change that was fine.
|
||||
|
||||
`build/` is the shared cache volume, so one symlink fixes it permanently, and pointing it at the
|
||||
bind-mounted repo tree means the rig also picks up new `resources/images/*.svg` without a rebuild:
|
||||
|
||||
docker exec <fork>-gui ln -sfn /OrcaSlicer/resources /OrcaSlicer/build/resources
|
||||
|
||||
Tell the two apart before debugging: a resource failure dies in the first second with no window;
|
||||
a real fault in your code gets past the version banner. Compare
|
||||
`~/.config/<App>/log/<newest>.log.0` against a known-good run — 47 lines versus 340 is the tell.
|
||||
|
||||
## Trap 7 — a single-instance app plus a path-matched `pkill`
|
||||
|
||||
`gui-session.sh` used to kill by `"$BIN"`, while its own `app_pid()` matched by BASENAME. Launch
|
||||
with a `BIN` that differs from the running instance's path and the old process survives, keeps
|
||||
the single-instance lock, and the new one exits seconds after loading fonts — then `status`
|
||||
reports the *stale* pid as a healthy session. Fixed by killing on the basename; `status` now also
|
||||
prints `binary : $(readlink -f /proc/<pid>/exe)`. **Read that line before trusting a screenshot.**
|
||||
|
||||
@@ -567,7 +567,7 @@
|
||||
"gui": true,
|
||||
"action": "key:S+X",
|
||||
"icon": "design_cut",
|
||||
"hint": "Split the body with a plane; set the offset in the card"
|
||||
"hint": "Trim the body with a plane — drag the offset arrow; keep one half or both"
|
||||
},
|
||||
{
|
||||
"id": "split",
|
||||
@@ -586,7 +586,7 @@
|
||||
"gui": false,
|
||||
"action": null,
|
||||
"icon": null,
|
||||
"hint": "Split the body into separate solids"
|
||||
"hint": "Split the body along a picked face into two solids"
|
||||
},
|
||||
{
|
||||
"id": "fillet",
|
||||
|
||||
Reference in New Issue
Block a user