-
-
Notifications
You must be signed in to change notification settings - Fork 21.4k
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
Improve Project Settings' Plugin display #88308
Improve Project Settings' Plugin display #88308
Conversation
Imo, addons which are enabled should not make their names bold as it's inconsistent with other elements from the editor, I don't remember that happening anywhere else in the editor. |
See proposal. While it is "inconsistent" there's desire to make enabled addons more noticeable. It does help. |
I have read the proposal before posting my comment, I do still think it's weird to include it. I'm not on my computer rn, I'll look for other components asap. |
|
But Shader Globals cannot be enabled or disabled, they can only be added or removed from the list, so they don't need their name in bold. There may be no precedent to something like this, hence why it looks weird to you? Autoloads feature a similar list and the logic is similar, too. The alternative to bold enabled addons could be to... darken disabled addons, instead? |
I'm pretty sure there were toggles on the Shader Globals tab, let me double check |
That could work too, it's even consistent to when you disable a node's process. |
Ah, I see, I mistakenly assumed the variable's bool toggle was a enable/disable toggle. |
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.
Looks great otherwise!
editor/editor_plugin_settings.cpp
Outdated
item->add_button(4, get_editor_theme_icon(SNAME("Edit")), BUTTON_PLUGIN_EDIT, false, TTR("Edit Plugin")); | ||
item->set_text(COLUMN_NAME, name); | ||
if (is_active) { | ||
item->set_custom_font(COLUMN_NAME, get_theme_font("bold", EditorStringName(EditorFonts))); |
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.
You could fetch the font before the loop. Same below (font and icon).
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.
The question is whether to do this or make the name more transparent (although in the original proposal no one seemed to mind the bold)
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.
You'd still need to fetch a "disabled" color, no? I mean, it's better to use a defined color than just decrease opacity.
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.
Ever since the massive editor theme refactoring I'm not sure how. Do you have a hint?
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.
e.g. get_theme_color(SNAME("font_disabled_color"), EditorStringName(Editor))
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.
Overall looks good.
I think it's worth to try using a different color instead of bold font to differentiate enabled and disabled plugins. Currently it doesn't look that readable with a longer list.
2627ed1
to
e8d8cfd
Compare
Looks better IMO. |
e8d8cfd
to
5080c62
Compare
I updated the PR to use the disabled color.
That's the drawback. The font size is not changed, it may be just the antialiasing. |
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.
Tested locally, it works as expected.
Code looks good to me.
Thanks! |
Partially addresses godotengine/godot-proposals#8438
May provide more screenshots at a later time.
This PR makes a few simple yet notable adjustments to the Project Setting's Plugin section (the Addons):
monospace
;.cfg
file is more concise.script
, I can't think of a reason to require all other fields, as well.Internally the EditorPluginSettings' code has been restructured a tad, as well.