0 Beginner's Tutorial

By following these tutorials you will learn the basics of GUI programming using Gtk+.

If you have never programmed before, or are not familiar with the concepts of object oriented programming, you may need to learn a few basics first. The book Learn Python the Hard Way or The Python Tutorial may be a better place for you to start. You may also be interested in The Python GTK+ 3 Tutorial. Once you master the basics, be sure to come back and check out these tutorials.

To run the code samples

To run the code samples:

  1. Copy and paste the code into filename.py

  2. In the terminal type:

    python filename.py

A path through the widgets

Tutorial

  1. Basic windows

  2. Images and labels

  3. Grid

  4. Ornaments

  5. Other display widgets

  6. Entry widgets (with a detour on basic scrolling)

  7. Menus and toolbars (also: using Glade)

  8. Tooltip

  9. More containers

  10. More scrolling

    1. "scrollbar.py"

  11. Custom widget

    1. "widget.py"

Exercises