In this article we will see how we can get the mouse tracking property to the QCalendarWidget. If mouse tracking is disabled (the default), the calendar will only receive mouse move events when at least one mouse button is pressed while the mouse is being moved. If mouse tracking is enabled, the calendar will receive mouse move events even if no buttons are pressed. We can set the mouse tracking property with the help of
In order to do this we will use
hasMouseTrackingmethod with the QCalendarWidget object.
Syntax : calendar.hasMouseTracking()
Argument : It takes no argument
Return : It return bool
Below is the implementation
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.