UI Toolkit Animation Curve

Hello! I am simply puzzled over why the .ranges is not working properly on the CurveField for the UI Toolkit. The first issue that that it doesn’t adhere to ranges at all. Second issue is it doesn’t visually update, even with a MarkDirtyRepaint()

I have a curve field, and I can change the range:

float width = maxX.value -  minX.value;
responseCurve.ranges = new Rect(minX.value, 0f, width, 1f);

And I can trigger that code just fine. You can see in the output that the range is computed correctly as well.

However, it doesn’t adhere to it at all.
In the picture, you can see the curve that appears to be displaying correctly, however once you click into the range editor you can see that you can go out of the range:
image

Compared to doing the same thing in an editor script, where it properly locks the range:

float width = xMax - xMin;
return EditorGUILayout.CurveField("Response Curve",value, Color.red, new Rect(xMin, 0f, width, 1f));

image

For the second issue, I just don’t know!
This is what it looks like after changing the range and saving (debug does say the range is correct:

However, this is what it looks like after simply closing/reopening:
image

As you can see, it does update it (still doesn’t adhere to it though) , but you have to do a hard refresh to get it to display properly (even after calling responseCurve.MarkDirtyRepaint()

Any tips/advice/help would be greatly appreciated! This is our last piece for this editor and it’s been killing us!

Thank You for your time!

Today I learned: its a bug. submitting a report once I figure out how to :slight_smile: