-
-
Notifications
You must be signed in to change notification settings - Fork 103
Description
Describe the project you are working on
Image editor with a Photoshop-like layer system.
Describe the problem or limitation you are having in your project
I want to add effects (outline, brightness/contrast/saturation, any other adjustment) to a group of Control nodes (in this project, I use Control nodes almost exclusively). I achieve that with CanvasGroup, but it breaks the layout and complicates in-editor control (e.g. unlike with Control nodes, I can drag the node with its children only while holding the top left handle).
Describe the feature / enhancement and how it helps to overcome the problem or limitation
Make a Control-compatible CanvasGroup node that would behave like any other Control but render like a CanvasGroup.
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
I've made this GDExtension based on CanvasGroup code. It adds a CanvasGroupContainer node that renders like a CanvasGroup but iherits all the nice layout features from Control. I'm not sure about the naming though. Because the node I made inherits from Control but not Container.
If this enhancement will not be used often, can it be worked around with a few lines of script?
No. In particular, anchor/offset system is too complex to be worked around with a few lines of script.
Is there a reason why this should be core and not an add-on in the asset library?
CanvasGroupcan technically be used today withControlnodes but it feels broken that way: layout positions break, in-editor controls are different. Making aControlnode withCanvasGroupfunctionality fills a natural gap.- Any UI-heavy project that uses Materials for custom effects could benefit (e.g. for group outline/highlight)
- The feautre was already requested here: Make CanvasGroup node that's compatible with Controls #4392