Search Unity

2017.3.1p3: Layout, Content Size Fitter and changing Text causes layout jitter

Discussion in 'UGUI & TextMesh Pro' started by snlehton, Mar 9, 2018.

  1. snlehton

    snlehton

    Joined:
    Jun 11, 2010
    Posts:
    99
    After finally getting fix for the UI prefab apply bug described here, some of the layouts in our game started to jitter.

    I was able to pinpoint the issue to be layout group (Vertical or Horizontal) coupled with Content Size Fitter and a child that changes size (modifying text on a Text component)

    Steps to repro:
    1: create UI canvas
    2: add a game object and put Vertical Layout Group (change and force expand width & height), and Content Size Fitter (preferred size on both)
    3. add a child Text
    4. have a script that modifies both position of the game object with the layout, and modify the text.

    Every time the text changes, the layout jumps to an arbitrary position for one frame before jumping back.

    This did not happen in 2017.3.0, but started happening 2017.3.1p1 and forward.

    You can see the issue in action here: https://twitter.com/snlehton/status/972018411466260480

    When can we see this fixed?