Tkinter is a GUI (Graphical User Interface) module which is widely used in the desktop applications. It comes along with the Python, but you can also install it externally with the help of pip command.
It provides variety of Widget classes and functions with the help of which one can make our GUI more attractive and user friendly in terms of both looks and functionality.
Binding function is used to deal with the events. We can bind Python’s Functions and methods to an event as well as we can bind these functions to any particular widget.
Code #1: Binding mouse movement with tkinter Frame.
Code #2: Binding Mouse buttons with tkinter Frame
Code #3: Binding keyboard buttons with root window (tkinter main window).
Note: When we bind keyboard buttons with the tkinter window, whenever we press special characters we will only get space while in case of alphabets and numericals we will get actual values (in string).
- Python | askopenfile() function in Tkinter
- Python | asksaveasfile() function in Tkinter
- Python GUI - tkinter
- RadioButton in Tkinter | Python
- Different messages in Tkinter | Python
- Python | after method in Tkinter
- Python | GUI Calendar using Tkinter
- Python: Age Calculator using Tkinter
- Color game using Tkinter in Python
- Python | Menu widget in Tkinter
- Progressbar widget in Tkinter | Python
- destroy() method in Tkinter | Python
- minsize() method in Tkinter | Python
- Python | Add image on a Tkinter button
- Combobox Widget in tkinter | Python
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. 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.