A brief overview covering the basics of Tkinter, python’s standard GUI library, and how to build a basic GUI.

Overview

Tk is an open-source, cross-platform widget toolkit that allows for developers to create basic GUIs using a widget based development. Tk was originally released in 1991 with the original library written in C. Since then a number of Language Bindings have been released, including: Haskell, Ruby, Perl and Python.

The Python binding for Tk is known as Tkinter and it will be the library we will focus on in this introduction. Tkinter has since become the standard for GUI creation in Python however there are numerous alternatives including: PyQt, PySide, PyGame, wxPython and PyGTK.

Terminology

  • Window: The general rectangular area that is displayed on user’s screen, all other components are placed within the Window.
  • Frame: A rectangular area that can be used to divide up a Window for more complex layouts, considered the most basic Widget.
  • Widget : A generic term for any of the given building blocks that make up the GUI

#tk #programming #tkinter #gui #python

GUIs for Python — A Introduction to Tkinter
2.20 GEEK