AutomaticSize Studio Beta

AS = AutomaticSize

This is certainly an easy way to create resizable frames because all you’d have to do is change the button’s to follow the mouse and it will resize!

Strange Behavior(s)

I think there is really weird behavior, intentional or not, but it makes it a little strange to use.

When the parent frame resizes, it doesn’t actually change its size property, which is what should happen IMO. Similar to how the red triangle pops up that says that the size property is controlled by UIAspectRatioConstraint (when added), that should also happen with AS, and the property would become a “read-only” for that state.

Bugs

Also, a “bug” occurs when using Inset and Middle Borders:


The gray frame should be overlapping the border and staying inside.


Weirdly, this behaves how it INSET should behave. For middle, the box’s rightmost edge should end between the border.

Additional Features

  • I think a great addition should be allowing UIPadding to add padding between the child and parent borders (only for the directions set because otherwise, it’d bleed over the edge anyway).

  • Two properties should appear when setting AS to anything but None: Min Size and Max Size. When the child is within the Min Size area, then the frame won’t follow to scale with the child’s position. On the contrary, when the child leaves the Max Size area, then the frame will just say at the Max Size and let the child wander off. (good parenting XD).


I hope I didn’t reiterate what was said in the post but do let me know anyone.

Anyways, thank you for this feature y’all!
Keep it up, Roblox! :roblox: :roblox_light:

9 Likes

This is actually perfect timing. I was going to make a plugin that has a TextLabel appear when you hover your mouse over a button telling you what it did. Before I had to make use of TextLabel.TextBounds to size the textbox to fit its text, but it had multiple issues. And now we have this feature which makes doing that 10x easier!

Thank you Roblox! image

2 Likes

Finally! I have been waiting for this for so long! Can’t wait to try it.

1 Like

Yes, yes, YES! Finally, I don’t have to have any awkward conversations with the devs that the translated text doesn’t fit the UI! Thank you guys so much.

4 Likes

I wish this works with ScrollingFrames.

4 Likes

Just to inform you, this new feature messed up my current icons layout:

1 Like

Maybe try reloading an old save and copying the gui then pasting it back in the current game.

I think is partially intentional as you should be using AbsoluteSize to determine the current size of a frame.

2 Likes

This is great! I can finally get rid of my manual scrolling frame canvas size changing.
Though it doesn’t seem to work at all and makes the scrolling bar not move and sometimes snap to different positions. It also seems to mess with tweening on pretty much every GUI object. Hopefully, this gets fixed soon!

1 Like

thank you so much, one of my first topics are finally solved

i kept using a ugly workaround but now automaticsize

this is revolutionary

3 Likes

This is quite helpful for Everyone!
I guess one of the main reasons for adding this feature is for auto-translated games because of the size of the text that is different in other languages.

Great job!

I just hope Roblox will be able to finish this year’s Roadmap.

1 Like

More info on this would be great. Can you send me a test place where you can repro the issue?

1 Like

I already sent it in the studio bug topic.

1 Like

This is a great feature to add! Regardless of most people probably using this feature for a more basic use, I can’t wait to see what people come up with, I can see a lot of creative features like buttons and loading screens using this feature!

For example, this’d make a great loading screen :eyes:

1 Like

This means I won’t need to update the size of my UI objects every time they change… Thank you very much for this!

1 Like

This is quite useful even if I don’t tend to script, however, I’d like to know what other type of frames will be support to AutomaticSize such as ScrollingFrame, other than that I don’t see any massive issues and hope you keep up the good work since I’m super excited for a planned release of realistic clouds.

1 Like

Hey @rogchamp - yes that’s correct. In the case of the parent frame set to automatically, size, it will size itself to fit the content of the children, in this case whatever the size of the TextLabel is. You can set AutomaticSize on both the Frame and the child TextLabel if you’d like both the parent Frame and the TextLabel to fit the text.

Thank you for trying out the beta, and for your feedback! :hugs:

5 Likes

Hi @IAmPinleon - TextScaled will change the font size to fit the available space of the size of the TextLabel. Without AutomaticSize, the TextLabel size is technically fixed.

The pipeline for TextScaled/AutomaticSize is something like this:

  1. AutomaticSize: calculate the max available space for this TextLabel.
  2. TextScaled: scale to fit the space from step #1
  3. TextScaled: return back the actual amount of space used
  4. AutomaticSize: set the amount of space used as the new size of the GuiObject.

Thank you for trying out the beta! :hugs:

3 Likes

I am in awe. This is exactly what I needed for my game. I have some reference images here of what I’m working on. Anything with the red background is using the AutomaticSize feature, everything to the right is hacked together using Scale values.

This one, the example display is at 1280x720:
image
1366x768:
image
1920x1080:

Serious props to the team and people who worked on the AutomaticSize feature, because this is a lifesaver. I’m super excited and can’t wait for this to get out of beta.

6 Likes

Hi @iiau - so when Automatic Size resizes the object from sizeOld to sizeNew (for example), give the ability to specify a Tween property that determines how the resizing occurs visually? Is that correct?

4 Likes