Applying UIPadding to an ImageButton

Right now, I’m trying to add UIPadding to my ImageButton. However, it seems like it has no effect at all. I searched the DevHub but to no avail. This is odd, because it seems to work on a TextButton just fine. What am I doing wrong? I tried looking on the DevHub too, no answer.

It’s because you’re trying to pad something that’s not there for the UIPadding to work you would need a child of “Exit”

A TextButton’s text is not a child of the TextButton itself though, and it works perfectly. I’ll probably end up making an ImageFrame inside the ImageButton, thanks for replying though.

yeah i mean i dont think you can pad an image on an image button

You can’t use UIPadding to pad a image because you can’t change the size of a image without resizing the whole frame

Your idea of using ImageButton as background and ImageLabel on top is the way I do it

1 Like

Thanks for the proper solution.

1 Like