关键功能
- Slot as Canvas Slot-> Set Position
- Get Cached Geometry
- Local to Absolute
- Absolute to Local
思路
- 获取目标UI组件的绝对坐标 Widget->Get Cached Geometry->Local to Absolute
- 把绝对坐标转换为CanvasPanel下的坐标CanvasPanel->Get Cached Geometry->Absolute to Local
其中Local to Absolute的Local Coordinate 参数,00为左上角,DesireSize/2为中心点。根据要调整位置的UI组件的定位方式选择
