In this article we will see how we can get the clicked signal from the QCalendarWidget. Clicked signal is emitted when a mouse button is clicked i.e when the mouse was clicked on the specified date. The signal is only emitted when clicked on a valid date, e.g., dates are not outside the minimum date and maximum date. If the selection mode is NoSelection, this signal will not be emitted.
In order to do this we will use
clickedmethod with the QCalendarWidget object.
Syntax : calender.clicked.connect(lambda: print(“Clicked”))
Argument : It takes method as argument
Action Performed : It will print the message whenever activated signal get emitted
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.
- PyQt5 QCommandLinkButton - Clicked Signal
- PyQtGraph – Menu Clicked Signal of Image View
- PyQtGraph – Export Clicked Signal of Image View
- PyQtGraph – ROI Clicked Signal of Image View
- PyQt5 QCalendarWidget - Activated signal
- PyQt5 QCalendarWidget - Current Page Changed signal
- PyQt5 QCalendarWidget - Destroyed signal
- PyQt5 QCalendarWidget - Object Name Changed signal
- PyQt5 QCalendarWidget - Selection Changed signal
- PyQt5 QCalendarWidget - Icon Changed Signal
- PyQt5 QCalendarWidget - Title Changed Signal
- Displaying the coordinates of the points clicked on the image using Python-OpenCV
- PyQt5 QSpinBox - Editing Finished Signal
- PyQt5 QSpinBox - Getting the sender signal index value
- PyQt5 QColorDialog - Accepted Signal
- PyQt5 QColorDialog - Finished Signal
- PyQt5 QColorDialog - Rejected Signal
- PyQt5 QColorDialog - Current Color Changed Signal
- PyQt5 QCommandLinkButton - Pressed Signal
- PyQt5 QCommandLinkButton - Released Signal
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to firstname.lastname@example.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.