godotengine / godot-docs

Godot Engine official documentation
https://docs.godotengine.org
Other
3.87k stars 3.16k forks source link

Problem with clarity in EditorInspector subpage #9442

Open Sythelux opened 4 months ago

Sythelux commented 4 months ago

Your Godot version:

4.3-beta1_mono (I'm coding in C#)

Issue description:

I was reading over the linked page and it says EditorInspector used in the editor's Inspector dock, use EditorInterface.get_inspector. which makes total sense, and all, but it also says

EditorInspector will show properties in the same order as the array returned by Object.get_property_list. which suggests, that I can use it to make an editor utility similar to the Editor when I make an EditorPlugin and want to have an EditorInspector that shows different properties than the main one, but I wasn't able to make one.

Alright so what I want to know is: As a plugin developer can I actually use the EditorInspector API to make my own EditorInspector or is that purely internal and the page is there to explain to me how to access the built-in inspector?

If I can use it. It would be neat to have an example in the docs telling me how, because I didn't got it to work at all.

If it is for internal use and the only important part for an plugin developer would be the "EditorInterface.get_inspector", than it would be good to to have it somewhat mentioned. (for example. [...]Object.get_property_list[...] is not actually exposed to Plugin or game development, but an hint to engine developers )

Edit 1st June:

I wasn't able to figure out how to use it still. I added it as side panel and main panel, inherited it, made a template scene with vbox in it and instantiated it. It never calls back the GetProperties function.

Do I have to call it back from another part of the plugin and implement the parsing and rendering as well? Then I could just use a normal Scroll Area.

URL to the documentation page (if already existing):

https://docs.godotengine.org/en/latest/classes/class_editorinspector.html

AThousandShips commented 4 months ago

You can use it yourself, but it's not directly supported from scripting but only from modules as far as I can tell

Sythelux commented 4 months ago

You can use it yourself, but it's not directly supported from scripting but only from modules as far as I can tell

apologies, but what do you mean with modules?

AThousandShips commented 4 months ago

Modules