Inconsistent events for custom inspectors

The events usable for custom inspectors are really hard to works with.
The usage is unpredictable and not consistent.
There also is little documentation on when EventType events do and don’t call.

An example is the MouseUp event.
This is only called when clicking on empty space, or when clicking on reference fields. When opening or closing foldouts, or sliding a float value it does not call.

If changing this will break certain Unity features, a new type called ‘FinalizedChange’ or whatever would be welcome. This way I can only call a function when the change of a value is done. That being opening a foldout, changing a variable, or when finishing changing a float (now I cannot read an event when the float change finished).

Here is an issue of mine about this as well:

If the current event is used by a different control before it reaches your code, the type will be “Used.” It is by design - you don’t want events being used by multiple different controls.

If you could share some code with an example of what you’re trying to achieve I could help troubleshoot.

To get back to you quickly, here is my setup:

I am making a custom LOD system.
This consists of an array, which contains 2 floats (range and downscale).
Every time the range is edited I want to sort the array from low to high. I also want to sort when the array is reordered (I can also use non-reorderable, but that looks less good imo).

I can share code tomorrow if needed

Usually the way to handle changes in IMGUI is through Unity - Scripting API: EditorGUI.BeginChangeCheck. There’s no need to listen for specific events.

Oh thanks!
It would be great to see some more learning material for custom inspectors, etc. It’s really hard to find what you are looking for without knowing the exact terms already.