Setting and accessing name of a Label – PyQt5
In this article we will see how we can set and access the description of the label.
A label is a graphical control element which displays text on a form. It is usually a static control; having no interactivity. A label is generally used to identify a nearby text box or other widget. Description of label is the details of the label, setting description helps in better understanding of the details for back-end purposes.
To set the Description –
Syntax : label.setAccessibleDescription(details)
Argument : It takes string as argument.
Return : No return value.
To access the Description –
Syntax : label.accessibleDescription()
Argument : It takes no argument.
Return : It returns string.
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