Godot version: aeddb30
Issue description:
Naming scripts after specific names such as Snap
or Group
will change the icon in the Add Child Node
context.
Steps to reproduce:
Create a new script.
Set the class_name to Snap
(or any other iconname used by Godot)
Search for the class/script in the Add Child Node
context.
Edit
Any icon from editor/icons
can be used. The name has to be in PascalCase.
Are you sure it is not a feature tho..
This could really be a feature indeed! I've actually have a couple of classes that do match the built-in icon names.
But unfortunately it's not currently possible to override it with a custom class_name
icon, it always reverts to using an icon from the Godot's theme in any case.
Would you still be interested in preserving this behavior while fixing its limitations?
Yes it should be made to favour user defined icons over built-in ones. Not sure if the current happenstance feature is actually useful, but it probably makes the code simpler anyway to keep it and just check class_name icon first, and then fallback to the class name built-in icon if relevant (i.e. using the same code as for built-in nodes).
Most helpful comment
Are you sure it is not a feature tho..