Search Unity

Feature Request TransformToVisualElement

Discussion in 'UI Toolkit' started by Xelnath, Jun 28, 2022.

  1. Xelnath

    Xelnath

    Joined:
    Jan 31, 2015
    Posts:
    402
    Windows WPF (which seems to use a similar architecture to this) has a great quality of life feature.

    TransformToVisualElement() - its a function where you provide two visual elements, and it produces a transformation matrix to convert coordinates from one space to another.

    This is really useful for positioning things precisely and handling custom input, etc. Does such a thing exist or is it possible to add?
     
  2. Xelnath

    Xelnath

    Joined:
    Jan 31, 2015
    Posts:
    402