Fix painted region rebuild after mixed filament edits#408
Merged
Conversation
Fixes #125. Add Local-Z Full Domain and related mixed-filament project settings to the project config and import allow-lists so they survive 3MF save/load and model import.
Fix geometry-only 3MF import so saved Local-Z project settings override the current unsaved state even when importing into a non-empty scene. Mirror the print-tab Local-Z booleans as well so the UI does not drift back to the old preset values.
Default Apply subdivision to infill to off while Subdivide Mix Layer is disabled, auto-enable it when subdivision is enabled, and clear dependent Local-Z child settings when subdivision is disabled so saved project config does not retain stale active child values.
- Reorder Show+Layout before SetLabel so hidden LB_AUTO_WRAP Label
gets valid width for wrapping, preventing NSTextField from
reporting overly wide intrinsicContentSize
- Clean up i18n keys: drop colons (Filaments:/Target Color:),
fix cycle card title Pattern→Filaments
- Sync zh_CN translations
bugfix: mix dialog error/warning panel oversized on first display
After geometry-only 3MF import, reload the print tab when Local-Z settings were imported so the visible Subdivide Mix Layer controls match the project config used for slicing.
File -> Import 3MF should preserve the current project's process parameter state. Stop applying saved Local-Z project/print settings during geometry-only 3MF import; those settings are still loaded when opening a project with config.
feature update the soft version (#389)
Bugfix 124
…tence Fix 3MF persistence for Local-Z project settings
i18n: add zh_CN translation for "Apply subdivision to infill"
…n MixedFilamentDialog The error/warning labels use LB_AUTO_WRAP, which requires two Layout() passes on macOS: the first lands the panel's actual width after Show(), the second re-wraps the label text at the correct width. Without this, a single Layout can query a stale zero-width from CalcMin and produce an oversized dialog on first display.
docs: add inline comments explaining double-Layout macOS workaround in MixedFilamentDialog
Fix painted region rebuild after mixed filament edits
LiuLikeQian
reviewed
May 31, 2026
| static bool painted_region_targets_match(const PrintObjectRegions &print_object_regions, | ||
| const std::vector<unsigned int> &painting_extruders) | ||
| { | ||
| std::vector<unsigned int> expected_extruders = painting_extruders; |
Collaborator
There was a problem hiding this comment.
data check for enter parameter.if it is invalid.
LiuLikeQian
reviewed
May 31, 2026
| @@ -4,6 +4,8 @@ | |||
| #include "libslic3r/PresetBundle.hpp" | |||
| #include "libslic3r/Print.hpp" | |||
Collaborator
There was a problem hiding this comment.
the test for unit and should not have include this pr.
NikSativa
added a commit
to NikSativa/OrcaSlicer-FullSpectrum
that referenced
this pull request
Jun 2, 2026
… rebuild after mixed filament edits + U1 by-object end safety move (Snapmaker#376, Snapmaker#408)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Fixes stale painted-region reuse after editing a custom mixed filament formula.
When a painted mixed filament keeps the same virtual filament slot but changes components, for example
1+2 -> 3+2 -> 3+4,Print::apply()could reuse the oldPaintedRegionstable because the total filament count had not changed. That left the table with old physical targets, so slicing could keep the previous mix or fail to find the newly required physical filament target.This PR compares cached painted-region targets against the currently required
(parent region, extruder id)set. If they differ, shared print-object regions are rebuilt before slicing.Also marks same-layer pointillism as deprecated in code.
Tests
libslic3rlibslic3r_testsMixed filament component edits rebuild painted region targets[MixedFilament]104 test cases,539 assertions