Commit Graph
20339 Commits
Author SHA1 Message Date
SoftFever 5b2fee9b10 Give every CAD tool a one-line summary and details 2026-11-09 21:35:05 +08:00
SoftFever 9c1d0e20ec Reach the Design tab only through the MCP server 2026-11-09 21:02:25 +08:00
SoftFever 0b9c47be29 Move the Design tab's MCP code next to the MCP server 2026-11-09 20:42:30 +08:00
SoftFever 348c801203 Keep the call_cad_tool registration with the Design tab's MCP code 2026-11-09 20:40:36 +08:00
SoftFever 70ca70ceb3 Give MCP tools plain names and call recorded tool lists replays 2026-11-09 20:21:02 +08:00
SoftFever 70842d3165 Add an MCP tool that lists open windows with refs for screenshots and input 2026-11-09 04:23:07 +08:00
SoftFever 643319c40b Split Run Script into Action Replay and a docked Python Run Script panel 2026-11-09 03:25:25 +08:00
SoftFever d56a80515f Move the MCP server only when its port is edited in Preferences 2026-11-08 16:04:04 +08:00
SoftFever fe12c41057 Fix Windows popup capture and MCP stalls in native menus and dialogs 2026-11-08 15:39:07 +08:00
SoftFever cd76a0ffdd Show context menus, dialogs and web views in macOS screenshots and recordings
Recording frames are also spaced as documented when capture is slow, and a drop-down that has left the screen is no longer drawn into macOS frames.
2026-11-08 01:38:33 +08:00
SoftFever ae5ccfbaa0 Keep MCP canvas clicks working when OrcaSlicer is in the background 2026-11-07 23:36:21 +08:00
SoftFever 4e11be7f3f Show popups in Windows and macOS recordings and screenshots 2026-11-07 22:24:11 +08:00
SoftFever 65d5867d61 Show popups, context menus and tooltips in Wayland recordings and screenshots 2026-11-07 22:15:34 +08:00
SoftFever 3a0dc1785d Show dialogs in Wayland recordings and stop blank Wayland window captures 2026-11-07 20:02:27 +08:00
SoftFever 15ee17cf92 Start OrcaSlicer from the stdio bridge only when a tool is called 2026-11-07 16:51:11 +08:00
SoftFever dc7f494d2b Give register_operation a signature Python can declare 2026-11-07 12:42:12 +08:00
SoftFever 7fef3a331d Give python_api's static methods their own documentation 2026-11-07 12:42:10 +08:00
SoftFever 6663dcbfb3 Show a reloaded local plugin's new version in the Plugins dialog 2026-11-07 12:42:07 +08:00
SoftFever 0548b7ea5e Show Speed Dial plugin refreshes and installs in an open Plugins dialog 2026-11-07 12:42:04 +08:00
SoftFever be94a6a0da Report why a local plugin install failed 2026-11-07 12:42:01 +08:00
SoftFever 09aa257c76 Let install_local_plugin take a plugin file's path 2026-11-07 12:41:59 +08:00
SoftFever a52e232385 Merge branch 'main' into feature/mcp 2026-11-07 03:12:51 +08:00
SoftFever eedd56991c Merge branch 'main' into feature/mcp 2026-11-07 02:51:37 +08:00
Kris Austin e2c2641acf Give the plugin Permissions tab its own Processes translation (#17339) 2026-11-07 02:47:11 +08:00
SoftFever 8b5bbcb7e8 Read a modal dialog's controls and values into its MCP message 2026-11-07 02:31:07 +08:00
Ian Bassi 4cfdccfe45 Fix adaptive and TPMS infill paths that start mid-line and end on themselves (#17334) 2026-11-06 15:11:58 -03:00
SoftFever b11009123c Update translation catalogs and fix run_gettext warnings (#17332)
* update locales

* Stop marking the plugin permissions example URL for translation
2026-11-07 01:04:20 +08:00
932b492252 feat: Add plugin permission management to the Plugins dialog (#17285)
* feat: permissions tab in plugin dialog ui draft

* feat: allow full access, make threading a boolean

* fix: clang-tidy

* feat: save changes button

* fix: clang-tidy

* fix: only allow permission editing when plugin not loaded

* fix: plugin permission drafts, target validation, and sidecar synchronization

* fix: minor html/css changes

* fix: Make plugin permission edits immediate and thread-safe

* refactor: rehaul UI

* fix: add don't show again to request permission dialog

* fix: permission request dialog ui

* fix: clean up plugin permission dialog and mutation APIs

* fix: retry Windows plugin permission file replacement

* test: extract and cover plugin permission validators

* fix: show clear denial for worker plugin file operations

* fix: clang-tidy

* docs: clarify plugin filesystem permissions and clean up declaration

* fix: handle the 3 states of install state read

* fix: match equivalent paths for exact filesystem grants

* fix: preserve unreadable plugin state and allow socket grant editing

* Recover plugins whose install-state file cannot be parsed

---------

Co-authored-by: SoftFever <103989404+SoftFever@users.noreply.github.com>
Co-authored-by: SoftFever <softfeverever@gmail.com>
2026-11-07 00:00:18 +08:00
Kris Austin b5c4ccd9c5 Fill every filament slot when a project has fewer filaments than tools (#17330)
Opening a project with fewer filaments than the printer has tools tops
up filament_presets and the flush matrix, but leaves filament_colour
and the other per-filament arrays at the project's count. Slicing then
fails the flush matrix check, and an overwriting filament sync reads
past the end of those arrays.

load_current_presets() used to fill the arrays on every load. Since
#15385 it compares against filament_presets, which the top-up has
already raised, so it no longer runs. Grow the arrays where the project
is loaded.
2026-11-06 09:23:38 -06:00
Lam Wei Lun 719fdcf4dd By object: keep rotated copies of an object in their list order (#17286)
* By object: order rotated copies of an object by their list position

Copies of one object that differ in rotation get one PrintObject each, and
print.objects() lists those groups by transformation. sequential_print_
clearance_valid() keyed the instances by their object's index, which all
copies share, so std::stable_sort kept the transformation grouping and every
second copy on a rotated plate printed out of place.

Key each instance by its position in the model's object and instance lists
instead. No key repeats, so the sort no longer depends on being stable, and
arrange_order is then the list order the G-code export and the sequence
labels already print in.

Fixes #17260.

* Keep the sequential printed-copy tests in step with the list order

The new by-object test rotated a cube centred on its corner, which moved the
footprint by half the cube and closed the 12 mm grid gap under the 2 mm
clearance distance, so validation rejected the plate. Centre the mesh on the
object origin so the rotation turns the footprint in place.

Sequential clearance warned the copy that print.objects() listed first, which
for a plate of rotated copies was the rotated one. Copies now print in object
list order, so print validation warns the first copy in the list; expect that
copy from the preview as well, and drop the now incorrect header comment.
2026-11-06 21:30:38 +08:00
2ec1a0732f Plugin audit: keep non-Latin path names intact in the keyword check (#16925)
* Keep non-Latin path names intact in the plugin audit keyword check

is_denied_path_keyword() lowercased every path component with
std::tolower(), which follows the C locale. With a single-byte locale,
which the UI language sets on Windows (Russian_Russia.1251), that
rewrites bytes of UTF-8 sequences: "Новая папка" is no longer valid
UTF-8, and has_denied_config_extension() then throws "boost::filesystem
::path codecvt to wstring: partial" while turning it back into a path.
The exception left the CPython audit hook, so the plugin call never
returned, and the app crashed later in PyFrame_GetCode.

The keyword check now uses the file's ascii_lower(), which lowercases
A-Z only; the keywords are ASCII, so matching stays case-insensitive.
ascii_lower() itself no longer goes through a locale-aware
boost::algorithm::to_lower(), so the network permission keys get the
same guarantee. The audit hook also no longer lets any C++ exception
reach the interpreter: a check that fails denies the event, like an
unanswered prompt.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* Address review: narrower try in audit_hook, shorter comments, a test for the catch

- Wrap only audit_plugin_event() in the try, so release_frames() is called
  once after the event is decided.
- Shorten the ascii_lower() comment and drop the one that repeated it.
- Use only the .1251 locale in the non-Latin path test.
- Test that a permission prompt that throws denies the event, which
  reaches the new catch on every platform.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: GNUGiminot <215263196+GNUGiminot@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: SoftFever <103989404+SoftFever@users.noreply.github.com>
2026-11-06 20:35:44 +08:00
HanifKoh 606b50f187 Restore the Custom Camera Source in the Device Tab (#17326)
* Restore the Custom Camera Source in the Device Tab

The printer-agent refactor reused the Device tab's WebView for the
generic snapshot stream and dropped the "Custom camera source" row from
the Camera Setting popup along with the code that showed the user's URL
in that WebView. The two app-config keys were then read nowhere, so
anyone who had a custom camera configured lost it on upgrade.

Bring the row back and show the stored URL when the source is enabled,
with the title-bar switch button toggling between it and the printer's
own stream. The agent-driven snapshot path leaves the WebView alone while
a custom source is enabled, a URL without a scheme gets http://, and the
Enable/Disable labels are translatable separately.

* Offer the Custom Camera Source Only Alongside the Bambu Native Stream

The custom view hides the Device tab's media control and play bar, which
every agent camera mode plays through (snapshot mode via the very WebView
the custom source takes over), and the 2.4.2 feature was only ever used
against the Bambu native stream. Gate the row and the stored URL on camera
mode none, which is that stream, so the custom source never contends with
an agent's own playback. Stop the native stream when the custom view takes
over, reapply the switch icon on rescale and theme change, trim and
normalise the URL in one shared helper, and reword the hint to say a URL
is expected.

* Keep the Custom Camera View in Step With the Agent's Camera Mode

Selecting a printer whose agent streams through the shared WebView
leaves the stored custom source unsupported, so reapply the view
whenever the stored state and the applied one differ, on every camera
tick and on the no-printer reset. Read the config flag before asking
the agent for its mode, so users without a custom source pay one config
lookup per tick. Stop the printer stream for the view switch without the
failure bookkeeping, which could open the LAN dialog mid-connect. Write
the trimmed URL back into the field and store it only when enabling.

* Load the Custom Camera Page Only While It Is On Screen

Let the show helper own the WebView page: it stops the native stream,
then loads the URL when the custom view comes up and a blank page when
it goes away, so a hidden view pulls no stream and the load never races
the stop. Track the applied state in a member and evaluate the stored
state once per tick. A view-switch stop leaves no retry count or
back-off behind, the URL field is read-only while the source is
enabled, and the gating comment says what mode none actually is.

* Pass the Custom Camera URL Through Once Per Tick

Read the stored URL once per camera tick and hand it to the sync, apply
and show helpers, so a toggle can no longer show a blank page when the
URL is empty and the camera-state branches no longer start with an empty
if. Disable the URL field while the source is enabled, which greys it
out, instead of a read-only state with no visual cue. The gating comment
now gives the real reason: the custom view hides the media control and
play bar that every agent mode plays through, and the feature was only
ever used against the Bambu native stream.

* Offer the Custom Camera Source With the Bambu Printer Agent Only

Printer agents are not for general use in 2.5.0, so gate the row on the
active printer agent being the Bambu one instead of on its camera mode.
The interaction with the other agents' camera modes gets a proper design
after the release.

* Note That the Custom Camera Source Is a Temporary Bambu-Only Patch

Say at the gate and in the header that the feature is a patch for the
Bambu printer agent and is to be deprecated or extended to the other
agents once printer agents are fully implemented.
2026-11-06 20:05:25 +08:00
cb80a0db84 Fix/wipetower klipper m400 stalls (#17246)
* WipeTower2: on Klipper, sync motion only before temperature commands

Follow-up to #15133. On Klipper, flush_planner_queue() emitted M400 at
every toolchange boundary, stalling the toolhead over the tower. Keep the
sync only before M104/M109/M591, and drop the sync line left behind when
GCode.cpp strips the interface-temperature M109.

End the deretraction placeholder with a newline: without the M400 that
used to follow it, the next tower move was glued to the placeholder line,
skipped post_process_wipe_tower_moves and kept tower-local Y.

Creator 5 Pro, 247 toolchanges: 1235 M400 -> 247 (~30 min saved).

* Update src/libslic3r/GCode.cpp

Good point, done. The strip now uses flush_planner_queue_command() and follows whatever the tower writes.

Co-authored-by: Kris Austin <kris.austin@gmail.com>

* tests: move the wipe tower slice and shared checks into one helper

* WipeTower2: keep the sync at the end of the unload on Klipper

[change_filament_gcode] and Tn are macros on Klipper; their non-motion
parts run when parsed, so without the sync a filament-change macro could
run while the unload and ramming moves are still queued.

Creator 5 Pro, 247 toolchanges: 494 M400 instead of 1235 (247 in this PR
before). The other boundary flushes, which stalled the toolhead over the
tower, stay removed.

* tests: check the unload sync before each change_filament_gcode

* WipeTower2: don't sync the cooldown after the interface wipe

The reset to the base temperature after the interface wipe isn't
timing-critical, but its M400 stopped the head over the tower before the
tower perimeter. Test print, Creator 5 Pro, 247 toolchanges: 3:22 with
the sync, 3:17 without it.

* tests: check only the interface cooldown for a missing sync

* WipeTower2: skip the cooldown sync on Klipper only

---------

Co-authored-by: Kris Austin <kris.austin@gmail.com>
Co-authored-by: GhZserG <ghzserg@zmod.link>
2026-11-06 18:58:00 +08:00
Ian Bassi c78272f583 Keep realistic view on while painting seams, supports and fuzzy skin (#17317) 2026-11-05 20:10:22 -03:00
Lam Wei Lun a620d804ef By layer: keep As object list copies in their list order (#17232)
By layer: order As object list copies by their list position

sort_object_instances_by_model_order() keyed every instance on its object's
index when it initialized the order, so all copies of an object tied.
print.objects() does not list the copies in list order either: copies with a
different rotation live in separate PrintObjects, ordered by transformation,
so the ties were broken by that grouping and the copies printed as 2, 4, 6,
1, 3, 5. std::sort reordering the ties made it worse from 17 instances up.

Number the instances by their position in the model's object and instance
lists instead. No order key repeats, so a plain sort is enough; the renumber
after it compacts this print's instances to 1..n. The other intra-layer orders
and the by-object path are unaffected.

The new test rotates every second copy, which fails on every platform before
this change, MSVC included.
2026-11-05 21:40:41 +08:00
SoftFever 637d7a9ce6 Enable vendor profile updates by default, except in stealth mode (#17289)
* always enable OTA

* Stop vendor profile update checks in stealth mode

* Keep vendor profile updates off in dev builds
2026-11-05 18:46:13 +08:00
Lam Wei Lun f96bbe8db1 Speed Dial Minor QOLs (#17291)
Single click to launch actions. Close button removed to prevent cluttering
2026-11-05 18:09:59 +08:00
SoftFever 56b03d7bdf Merge branch 'main' into feature/mcp 2026-11-05 18:07:30 +08:00
yw4z b2978d1c73 Fix: Prevent deselecting object and closing widget while clicking to toolbar background / divider (#15548)
* init

* simplify code

* simplify comments

* update

* update
2026-11-05 14:19:17 +08:00
HanifKoh 70c12f5cba Warn When an Object Overrides Settings Spiral Vase Mode Needs (#17240)
Enabling spiral vase mode in the GUI resets sparse infill, wall loops and
top shell layers in the global config only. An object, part or height range
that overrides them keeps its own values, and its layers with infill or more
than one wall are printed without spiralizing, with no hint as to why.

Print::validate now warns once per such object, naming it and the first
conflicting setting so the notification jumps to it.
2026-11-05 13:45:43 +08:00
Lam Wei LunandHanif Koh bd3e9aeb96 fix: stop the Speed Dial dismissing itself on the first open (#17245)
* fix: stop the Speed Dial dismissing itself on the first open

Opening the dial with Space and not touching anything closed it again a
moment later, on GNOME and KDE, X11 and Wayland, and only on the first open.

The dial hides on wxEVT_ACTIVATE(false), but wxGTK does not deliver that
event to the window that lost the focus: gtk_frame_focus_out_callback sends
it to g_activeFrame, the toplevel that was activated last (wx
src/gtk/toplevel.cpp:192-205). A deactivation that belongs to another
window, or the same one arriving while the dial is still taking the focus,
therefore read as "the user dismissed the dial". The first open is the only
one that maps the window, moves it, resizes it to its content and grabs
focus into a web view that has never held it, so it is the only open
exposed to that ordering.

Validate the dismissal instead of trusting the event: arm a 150 ms one-shot,
cancelled by any activation, and hide only if the dial is still shown and
its window is no longer active. On GTK ask the window with
gtk_window_is_active(), because wxTopLevelWindow::IsActive() resolves
through wx focus tracking, which does not follow the focus that WebKit's
native widget takes. Also skip the pre-map focus grab on the first open: at
that point wxGTK has not mapped the window yet, so the grab cannot land.

speed_dial_should_hide() is a free function, so the rule is covered by
tests/slic3rutils/test_speed_dial_dismiss.cpp without a GUI.

* docs(wxwidgets-skill): document the validated Speed Dial deactivation

Section 10 described the dial's old handler, which hid on every
wxEVT_ACTIVATE(false). The skill is the review ground truth, so it has to
match the code: the deactivation is now validated after a settle interval
against the window's real active state, because wxGTK sends that event to
the last activated toplevel whatever window lost the focus.

* Ignore Page Changes of Inner Books in the Main Tab Handler

The main frame's tab-panel handler receives the page-changed event of
any book inside a page, because wxBookCtrlEvent propagates and the
Calibration page's Tabbook has no handler of its own. It then treated
the inner page switch as a main tab change: it reset the selected tab,
toggled the undo/redo buttons and called SetFocus() on the current page.

On wxGTK, SetFocus() on a child of a visible but inactive top-level
window presents that window. While the Calibration page is built in the
background after start-up, this re-activated the main window and the
Speed Dial, which hides when it loses the focus, closed by itself a
moment after its first open on Linux.

Only act on events whose object is the main tab panel.

* Include wx/timer.h Where the Speed Dial Binds Its Timer

* Describe the Real Cause of the Speed Dial's First-Open Close

The deferred, re-checked hide absorbs a focus bounce shorter than its
delay. It did not stop the first-open close, which was the main frame
activating itself from its tab handler; say so in the comments, the
test and the skill reference instead of describing a misdelivered
deactivation.

---------

Co-authored-by: Hanif Koh <hanifkoh@outlook.com>
2026-11-05 11:34:33 +08:00
Rodrigo Faselli 834c6987e0 Hide lightning angles if there is no infill (#17277) 2026-11-04 21:34:00 -03:00
HanifKoh 1a61ffd32e Keep a Filament Slot Past the Colour Arrays From Staying Frozen (#17262)
PlaterPresetComboBox::update() froze the combo and returned without
thawing it when the slot had no colour icon, which happens on a tool
changer whenever filament_presets is topped up to the tool count while
the colour arrays keep the project's shorter length. The leaked freeze
count left the combo unpainted for the rest of the session.

The slot now shows a blank swatch and still fills its list, and
update_ams_color() grows the colour arrays to the slot before writing,
as sync_colour_config() already does.
2026-11-04 13:59:04 -06:00
HanifKoh dd0079ec64 Start the Orca Cloud Sync Cursor at Zero (#17263)
Fixes #17256

On a machine with no saved `sync_state`, the first `sync/pull` sent whatever was in memory as `?cursor=`. The server answered 400, nothing was downloaded, and the account's presets never arrived because only a 410 clears the cursor.

`SyncState::last_sync_timestamp` now starts at zero, so a session with no saved state pulls everything. `SyncPullResponse::next_cursor` had the same problem on a 304, where a stray value would have been saved to `sync_state` and sent on every later pull, so it and the other scalars in `ProfileUpsert` and `SyncPushResult` start at zero too.
2026-11-04 13:57:23 -06:00
Lam Wei Lun 6839c9d344 Invalidate filament grouping when the AMS material inventory changes (#17195)
Print::m_extruder_filament_info feeds filament grouping, but it was a plain
member with no change detection and no invalidation entry point. Changing only
the device-side AMS material inventory, such as a spool colour, therefore left
a finished slice valid: Print::apply() reported UNCHANGED, the grouping steps
stayed done, and export re-emitted the previous G-code with a stale
filament_map.

Compare the inventory in Print::apply() and invalidate the grouping steps when
it changed:

- set_extruder_filament_info() now only stashes the payload, so apply() can
  compare it against the installed one and act on the change under the state
  lock.
- The comparison projects both payloads exactly as grouping does: colour, type,
  tray name, support flag and filament id per tray. Volatile AMS keys such as
  remaining amount, temperatures and filament_changed therefore do not count.
- A changed inventory invalidates psWipeTower and psSkirtBrim, matching what
  extruder_ams_count already does, and escalates to APPLY_STATUS_INVALIDATED
  only when a step was actually taken back.
- A payload carrying no tray configs at all is treated as "not known yet"
  rather than "no filaments", so an AMS reconnect does not invalidate a
  finished slice, while clearing the last spool still does.
- The Plater hands the inventory to apply() before applying, so the change
  rides the same pass.

Adds comparator tests for the inventory projection and an integration test that
drives process() and apply() over a two-extruder auto-match print.
2026-11-04 21:45:25 +08:00
Kris Austin 0b1d825142 Fix the freeze before the Creality send dialog opens on a printer without a CFS (#17177)
Fixes #17128

Clicking Print on a Creality printer asked it for its CFS slots on the UI thread, with the 10 s command timeout. A K1C without a CFS never answers that query, so OrcaSlicer froze for 10 s on every click.

The send dialog now opens right away and reads the printer on a background thread. Upload works at once, and Upload and Print turns on when the read ends. The slot query waits 5 s, or the full 10 s once the printer reports `"cfsConnect": 1`, and stops as soon as it reports `"cfsConnect": 0`. When there is no filament mapping, the dialog says whether the printer reports no CFS, lists no slots, or can't be reached.
2026-11-04 07:40:11 -06:00
anjis 3bda653448 Fix Type 1 wipe tower filament statistics for non-Bambu printers (#17199) 2026-11-04 09:31:08 -03:00
Ian Bassi d607d7f4ad Fix gap infill printing with the outer wall filament with classic walls (#17229) 2026-11-04 09:30:34 -03:00
Ian Bassi 9afa96e92f Fill internal solid Spiral Inset with Arachne walls
Internal solid infill fell back to fixed width loops so that Arachne's open
walls would not be printed after an outward spiral, which ends at the edge
and travelled back to the centre for them. Fixed width loops leave strips
up to two lines wide in the middle of an island and wedges where it
branches: on calicat.3mf they need 218 mm of gap fill against 53 mm with
Arachne, and with gap fill off for internal solid those gaps stay empty.

Keep Arachne for every solid surface and print each open wall at the centre
end of the nearest spiral instead: before an outward spiral, which starts
there, and after an inward one, which ends there.
2026-11-04 08:56:28 -03:00
Ian Bassi 88c4c1e915 Print gap fill after the lines next to it in fills that keep their order
insert_gap_fill() put each piece of gap fill wherever it added the least
travel, which could be before the extrusions bordering it: the centre gap
of a Spiral Inset printed before the spiral that starts there, and gaps
where spirals meet printed before the later spiral. Each piece now only
goes after the last extrusion of its fill that passes within half its
widest width and a line spacing of it.
2026-11-04 08:56:28 -03:00