In this article we will see how to create circular push button. By default, when we create a push button it is in rectangular form although we can also change it size to square.
In order to create circular button we have to do following steps:
1. Create a push button.
2. Change its size to make it square.
3. Set radius of button to half of length or square button.
Note : If we set radius greater then the half of the length then no change will occur as that shape would not be possible.
Syntax : button.setStyleSheet(“border-radius : 50;”)
Argument : It takes string as argument.
Action performed : It sets the radius of button.
Attention geek! Strengthen your foundations with the Python Programming Foundation Course and learn the basics.
To begin with, your interview preparations Enhance your Data Structures concepts with the Python DS Course. And to begin with your Machine Learning Journey, join the Machine Learning – Basic Level Course