#UIToolkit styling
1 messages · Page 1 of 1 (latest)
Nothing my ui doesnt do anything responding to the different window sizes as shown in the image I sent before and this:
Have you set any style settings?
Well i dont particularly know much but most the stuff ive done have made no change
Basically just this but for the window ui:
I would start in a new UXML file, and just add a field to it. It should do that by default
done and its the same
Well.. that isn't what it should look like... umm, setstyle.flexShrink = 1 on the field I guess
If you are not already, I recommend using the UIBuilder
nope
yeah I am
do i gotta install some unity package?
Do you have an example screenshot of what it should look like? @cyan quartz
ah
What version are you on? They liked to change defaults from one version to another
2021.3.16f1
Hmmm, I just tried it in 2021.3.0f1 and it works fine for me.
Like what does it look like in an editor window?
Exactly the same
odd
I would delete the uxml, close unity and then reopen it and create a new uxml file
No, just add the field
What do you mean? like a text field? this is all i have
Click on the little vertical dots at the top right and select "Editor extension"
yay
wait
i think i found out the problem
its when I change the position from relative to absolute
Yeah, don't do that 😛
oh
well how can I set a position of my ui without doing that?
Generally it is better to use the auto layout options along with parenting.
ahh ok thanks
i cant even change its size without it doing that thing
with the clipping
so i can change its position with transform but i cant get scaling
Of course, if you set its size, than it will stay the size that you set it at. What are you expecting it to do?