edited June 2023 in General Support
Hello,

I've been having a problem with my UI when resizing the window. I'm not certain if it's an isolated issue on my end or not. To replicate the problem, follow these steps:

- Open a menu.
- Resize the window.
- Close the menu.
- Open the menu again.

Before resizing: image
After resizing: image

It seems random on which elements move. Sometimes it's the tabs, sometimes the grid in the middle.

If anyone has experienced similar behavior or knows of a solution, I would greatly appreciate your input.

Thank you!
Post edited by g35011 on
  • edited June 2023
    Generally, all of that is depending on the setup of the canvas and the individual UI boxes and HUDs prefabs.

    The default canvas (when not using a prefab or disabling this in the UI system settings) will use Unity's canvas scaler to adjust based on screen size.
    This is combind with the anchoring of your UI prefabs, e.g. anchoring in the center vs stretching with width/height of the parent will have vastly different results.

    Also, resizing with a fixed aspect ratio (e.g. 16:9) should usually keep the same layout, while free aspect will lead to funky results if the canvas and/or anchoring of the UI prefabs isn't set up for it.
    Post edited by gamingislove on
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Sign In or Register to comment.