Z-Index and Editor elements

Godot Version

4.2

Question

So i have a editor plugin i am making, which are adding some UI to the editor at certain instances.

The nodes are added as expected, and everything works as expected.

My issue is that my added UI goes in front of alot of editor components, like when i hover another scene my “Button” can be seen on top of the preview of the scene. as an example.

I thought i could control this through ZIndex, but it’s already 0, and setting it to -1 would make it go away.

Also tried with both relative on and off but to no avail, and currently im feeling quite numb on what i should change to get the behavior i seek, which would be that my button hides behind the preview when hovering a scene tab. like the other UI components of Godot is doing it.

Would i have to somehow inject the add of the child so it’s placed at a certain point in the tree?

Hope someone can help, thanks!