- Edited
Can somebody give me a good explanation about how pivot works?
In all software I used before, a pivot point determines an "anchor" or offset relative to the object, that is added to the global position itself.
But not in Godot, or that's what it seems, at least.
What I'm trying to do is setting the pivot using pivot_offset (by the way, poorly documented, even the name isn't that) to half the size of my control, and then when I set its position.y to zero, the control aligns with the upper border of the canvas, but not centered on the control itself as the pivot may suggest: it uses the top-left corner of the control instead, as if the pivot wasn't changed before.
Is pivot used for all transform (position/rotation/scale), or is only for resizing/rotating controls?
The same goes to anchors: why sould I care about anchors, if all positioning inside the canvas is done on absolute coordinates, not relative to anchors?
When I see this, what I expect is position to be = (0,0), based on anchoring:
But no, this is what I get instead, based on absolute canvas coordinates: