Hi,
So the issue am having is my UI prefabs for my game that are saved in the project file system when opened don’t look right (see below). Even when dragged onto the scene canvas they stay broken (and also scales then by a factor of 27 for some reason)

It is supposed to look like the following.
At the moment, to edit UI components, I have to copy it into the scene, edit it there, delete it in the main project file and save it as the new one.
This a pain, as I have to reshape it every single time, and for every canvas component.
Any thoughts on what is causing this would be appreciated.
Thanks.
It’s not completely clear what the issue might be here, but my guess it it’s related to this:
UI Prefabs opened in isolation will be displayed in a Canvas that may have a different size than the Canvas in the scene. If there are scaling elements in the UI Prefab, that can make it appear different when displayed in a Canvas of a different size.
In Unity 2020.1 and later, Prefabs in a scene can be opened in Prefab Mode in Context, which will display it in Prefab Mode in a Canvas of the same size as the Canvas in the scene. Hopefully this addresses the issue (if you’re able to use 2020.1).
2 Likes
Hi, thanks for the reply.
The canvas it does open it up with does have different settings, but I am not able edit it. It is all greyed out.
When I come back to my UI I will see if I can upgrade to 2020 (currently on 2018.4.23f1).
Yeah, you can only edit the Prefab itself in Prefab Mode. And the canvas is not part of the Prefab (it’s part of the environment), hence can’t be edited.
1 Like
Is there really no way to choose what environment it opens with?
There is. You can set an editing environment scene for UI Prefabs. See the manual page about Prefab Mode:
https://docs.unity3d.com/Manual/EditingInPrefabMode.html
2 Likes