Files
OrcaSlicer/docs
RrrrobertB1992andyw4z 9c0d948575 Add co-extruded colors to the color picker (#17541)
* Add co-extruded colors to the color picker

The color picker could make solid colors and gradients, but co-extruded
filaments (colors side by side along the strand, like dual color silk)
could only be kept, not created or edited.

Solid mode now works like Gradient where multi-color is allowed: its
colors show as blocks with the same - and + buttons. Two or more blocks
are a co-extruded color, one block is a plain solid. The Solid/Gradient
switch is unchanged. Co-extruded colors are saved as the existing
multicolor type (filament_colour_type 1, AMS ctype 1), which the
swatches already draw as segments.

Made with help from Claude

* Start a new solid from the selected gradient color

Made with help from Claude

* Carry colors over when switching between Solid and Gradient

Made with help from Claude

* Convert colors only on the first Solid/Gradient switch

Switching between Solid and Gradient used to copy colors across on every
switch, so edits made in one mode overwrote the other. Now the first
switch to a mode converts the other mode's colors, and after that each
mode keeps its own.

Gradient support now also allows co-extruded colors, so the separate
allow_coextruded option is removed.

Made with help from Claude

* Skip invalid favorites when loading instead of dropping all of them

Made with help from Claude

* Fix ColorPickerOptions initializer after removing allow_coextruded

Made with help from Claude

* Restore the original picker options at the project color call sites

With allow_coextruded gone, {true, true} already allows gradients and
co-extruded colors, so these two call sites no longer need to change.

Made with help from Claude

* Update the color picker design doc for the Solid/Gradient behavior

Made with help from Claude

* Merge gradient and co-extruded picker types into ColorMulti

Replace ColorGradient and ColorCoextruded with one ColorMulti
{colors, gradient} in ColorSelection = variant<ColorRGBA, ColorMulti>,
as suggested in review. This also collapses the duplicated gradient and
co-extruded branches in normalize, JSON load/save and the AMS conversion.

Made with help from Claude

---------

Co-authored-by: yw4z <ywsyildiz@gmail.com>
2026-11-28 17:52:03 +08:00
..