Repository navigation
Appearance: the inline effect editor shows 3D, Warp, Rasterize and channel choices as dropdowns - #2796
Merged
bflatastic merged 1 commit intoOct 18, 2026
Conversation
4 tasks done
…annel choices as dropdowns The Appearance panel's inline effect editor still showed eight choice parameters as text fields holding the stored value: Revolve's edge, Extrude & Bevel's bevel, every Warp style's orientation, Rasterize's Color Model, Background and Anti-aliasing, and the channel of Levels and Curves. Their dialogs built these lists in their own bodies, so effect::choices did not hold them. Nothing checked a channel's value: a typo was stored, and Levels or Curves drew it as RGB. effect::own_choices now holds these lists, each label as its dialog passes it to its dropdown or radio buttons. The dialogs read the lists from it (Rasterize's Anti-aliasing from the AntiAlias list it is built from), and the inline editor shows each one as a dropdown with the dialog's translated labels; Rasterize's Color Model reads CMYK or RGB by the document's mode. effect.apply and effect.setParams refuse a Levels or Curves channel other than rgb, red, green or blue (r, g, b and any letter case are read too) with "`channel` must be one of rgb, red, green, blue", and the document and its undo history stay as they were. Docs: docs/mcp.md (effect params), docs/target-app-parity.md.
bflatastic
force-pushed
the
fix/appearance-inline-3d-and-channel-dropdowns
branch
from
October 18, 2026 06:20
55a816d to
22ce516
Compare
Contributor
|
Note Currently processing new changes in this PR. This may take a few minutes, please wait... ⚙️ Run configuration
📒 Files selected for processing: 13
✨ Finishing Touches
Comment |
Member
|
Thanks @dotCooCoo, merged. It went through the full gate (fmt, clippy, tests, layers, wasm) in a batch with the other PRs landed today. |
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.
What and why
After #2582, the Appearance panel's inline effect editor still showed eight choice parameters as text fields holding
the stored value. Apply Effect › 3D and Materials › Revolve… and open its row with the chevron: on
main, Edge readsleft, where the dialog has a Left / Right dropdown. Extrude & Bevel's bevel, every Warp style's orientation,Rasterize's Color Model, Background and Anti-aliasing, and the channel of Levels and Curves are text fields too. Their
dialogs built these lists in their own bodies, so
effect::choicesdid not hold them. Nothing checked a channel'svalue:
effect.setParamsstoredchannel: "alpha", and Levels drew it as RGB.effect::own_choicesnow holds these lists, each label as its dialog passes it to its dropdown or radio buttons. Thedialogs read the lists from it (Rasterize's Anti-aliasing from the
AntiAliaslist it is built from), and the inlineeditor shows each one as a dropdown with the dialog's translated labels; Rasterize's Color Model reads CMYK in a CMYK
document.
effect.applyandeffect.setParamsrefuse a channel that Levels or Curves does not read with "channelmust be one of rgb, red, green, blue", and the document and its undo history stay as they were.
How it was tested
New tests:
panels::appearance::tests::the_effect_editor_picks_choices_their_own_dialogs_list: each of the eight shows itsdialog's label, and a pick stores the dialog's value as one undo step.
panels::appearance::tests::the_effect_editor_shows_those_choices_as_their_dialogs_do: RVB for the channel inFrench, the "3d" row for Rounded in Spanish, and CMYK for Rasterize in a CMYK document.
dialogs::effect::tests::lists_drawn_in_a_dialogs_body_are_the_documented_values: each list holds the effect'sdocumented values, in order.
a_tone_curve_channel_it_does_not_have_is_refused(engine/tests/param_keys.rs):effect.apply,appearance.addEffect,effect.setParamsand the parameter check refuse bad channels.i18n::tests::effect_channel_param_error_is_translated: every message-complete language translates the error.All but the documented-values test fail on
main.On Windows 11 (x86-64) with rustc 1.99.0, on top of
mainat f7de3d6:CRAFT_FONTS_DIR=<craft-fonts checkout> cargo xtask cipasses its 10 steps: 7,931 tests passed, 0 failed, 11 ignored.On the branch merged with
mainat e6aec06, which adds 3D lights todialogs/revolve.rs, clippy on the effects,engine and ui-egui crates passes, and the dialog, Appearance, plug-in and i18n tests (466),
param_keys(5) and theeffects library tests (232) pass.
git merge-treereports no conflicts withmainat e6aec06. It conflicts with #2759 incrates/ui-egui/src/i18n/tests.rs, where both add a test aftereffect_color_param_error_is_translated; keeping bothtests resolves it.
Checklist
cargo xtask cipasses (fmt, clippy, tests, assets, brands, layers, wasm).unwrap(),expect(),panic!,unreachable!,todo!orunimplemented!outside tests, and no unchecked indexing on data from files, parameters ormessages. Errors are returned as
Resultand shown to the user(why and how).
ASSETS.md.