Buttons with images
#2704
-
I want to add an Icon to a button. The Icon should be centered and scaling automatically to the size of the button. How would I do that? |
Beta Was this translation helpful? Give feedback.
Answered by
ogoffart
May 9, 2023
Replies: 1 comment 2 replies
-
There is a icon property on the Button widget. But that puts the icon on the side. The provided Button widget cannot be customized further. So what you can do is to have a Button without content and put the Image over it, or write your own Button. |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
pej-p
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
There is a icon property on the Button widget. But that puts the icon on the side.
The provided Button widget cannot be customized further. So what you can do is to have a Button without content and put the Image over it, or write your own Button.
Example