-
-
Notifications
You must be signed in to change notification settings - Fork 21.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improved Inspector Sub-Resource Editing #45907
Improved Inspector Sub-Resource Editing #45907
Conversation
99629cc
to
2360b54
Compare
Can the user somehow manipulate the colors? Otherwise I feel they are a bit too strong / saturated. |
In that case an editor setting should give the ability to toggle or tweak the saturation of the colors, maybe? |
looks great, easy to distinguish between sub resources |
Rather than rotate the hue through the colours (16 of them it seems), why not just add editor theme settings for each level which can be modified by users? Then they can retain complete control over the theme of the editor. It doesn't have to be many - only 5 perhaps. Consider how many times you are going into sub resources which are 5+ levels deep? I think having 5 or so and then looping back to the first colour if you have more than 5 would be fine: 1 > 2 > 3 > 4 > 5 > 1 > 2... etc. You would still be able to easily distinguish each section since the repeated colours would be deeply nested and would not get confused with one another. Overall it is a good usability change though! |
Seeing the feedback on Twitter and Discord, there seem to be quite a lot of people that prefer to have the resources highlighted with blue only. Because of this it might be good to have an option to turn off the automatic coloring. Another way would be to have a modifiable array of colors like @EricEzaM mentioned, so that the user can set them all to blue if preferred. |
@EricEzaM Let's see how many find that to be a problem eventually and then we discuss again. I prefer automatic because i can ensure the colors are contrasting and the usability is good. It also works great because it's based on the accent color so, if you change it (or change from dark to light theme) it always finds contrasting colors. On the other side, having to tweak these every time you tweak your theme to make it contrasting is a hassle that most users will not be happy about. The new theme system is designed to be hassle free (few things change lots of settings) and this has been a win so far, so better not return to the "lots of settings" theme. |
dcec69d
to
47afe53
Compare
That will help a lot. |
Very nice change, thank you! |
@alexfreyre TBH we explored a lot of options in the past too, and the colors are by far what works better. In your images it's not entirely clear what's going on in comparison. I am a pragmatical person, so if something objectively works better at its given task, and then it's the best solution. The "consistency" arguments are subjective and thus irrelevant, you will just get used to it like users did to a lot of changes I am not going to mention that were controversial at the time but nowadays no one cares any longer. |
@reduz totally agree, my intention with the previous images was to show another solution. Any simple task can be time consuming if we have no alternatives. I am not trying to change the idea of this PR, it is very good, but I want to contribute some more. With colors the problem is solved, without doubts. What seems to me that three different colors separate three elements that are integrated. what I wanted to do with the tones was to integrate the elements into a tonal group, not three families of different colors, although it can also be a group of analogous colors within the same family or same color with different values. for example, Group Environment = blue family
then they are integrated, I think that this small detail would make any place have a visual hierarchy with unified groups and subgroups. |
This was a suggestion I made on Twitter. Basically same separation by hue, however with the hue steps much smaller. I would suggest hand-picking three colors and linearly interpolating between them based on the level of nesting. (1. -> 2. second color for the most common nesting depths, 2. -> 3. color for deeply nested) |
I like @API-Beast's "After" suggestion, but would suggest that contrast is increased on hover. This way you have something not too visually jarring by default, but when you do edit those options, you get a better contrast to make nesting much clearer (while keeping similar hues, like a typical hover effect would). |
While I agree that it looks more stylish (apart from the colors getting basically all purplish, but that's taste), I think the contrast is much less resulting in a harder to differentiate subresources. You can upload your example image here: And you will quickly notice that the contrast is muss smaller and sometimes almost non existant. |
9350c47
to
3c9a9ec
Compare
Also since usability has considerably improved now, I made it possible again to edit materials inline. |
editor/editor_themes.cpp
Outdated
for (int i = 0; i < 16; i++) { | ||
Color si_base_color = accent_color; | ||
|
||
float hue_roate = (i * 2 % 16) / 16.0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
float hue_roate = (i * 2 % 16) / 16.0; | |
float hue_rotate = (i * 2 % 16) / 16.0; |
editor/editor_themes.cpp
Outdated
Ref<StyleBoxFlat> | ||
sub_inspector_bg = make_flat_stylebox(dark_color_1.lerp(si_base_color, 0.08), 2, 0, 2, 2); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ref<StyleBoxFlat> | |
sub_inspector_bg = make_flat_stylebox(dark_color_1.lerp(si_base_color, 0.08), 2, 0, 2, 2); | |
Ref<StyleBoxFlat> sub_inspector_bg = make_flat_stylebox(dark_color_1.lerp(si_base_color, 0.08), 2, 0, 2, 2); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clang format is doing this for some reason, I can't fix it. Guess I will rewrite the code so it does not.
sub_inspector_bg->set_draw_center(true); | ||
|
||
theme->set_stylebox("sub_inspector_bg", "Editor", sub_inspector_bg); | ||
for (int i = 0; i < 16; i++) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we even need to go to 16? If the impact on editor start performance is negligible it's fine, but otherwise I think 8 might be plenty enough, especially if it rotates.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
performance is not a problem, and it just ensures the rotation is slow and smooth in case it needs to be.
-Better margins -Colors to delimit subresources better.
3c9a9ec
to
b9b68b7
Compare
One question, will this change als be made available for the Godot 3 branch? |
Thanks! |
This could possibly be backported to the That being said, this kind of change is usually iterative and we might want to wait for things to be fine-tuned in the |
I use subresources workflow quite often, if these changes are not too different from the |
See #45940 for I'd say that most people actually use |
I think the point of waiting is to make sure we don't run into a change later on that would be breaking in |
According to what I've seen, Unlike #45902, #45940 is mostly cosmetic and does not introduce any compatibility breakage (it's internal change). Especially that I've tested it myself (and urge anyone to do the same testing, because this feature is great). 🙂 That said, I'm fine if this is postponed to 3.2.5... |
It may be good to use 3.x as testing ground of that harmless feature, considering how long it will take for 4 to be released (and "feature preview" approaches seem to give good results for early tests on other popular tools). |
There is any way to disable this? |
How do you imagine it should look, when disabled? |
@yosoyfreeman you can try to set |
Thanks you! This is a nice update anyway |
Based on ideas from @LucyLavend and @RPicster, posted in godotengine/godot-proposals#2230
How it looks:
Bugsquad edit: This closes godotengine/godot-proposals#2230.