Book Image

Kivy - Interactive Applications and Games in Python

By : Roberto Ulloa
Book Image

Kivy - Interactive Applications and Games in Python

By: Roberto Ulloa

Overview of this book

Table of Contents (13 chapters)
Kivy – Interactive Applications and Games in Python Second Edition
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Chapter 3. Widget Events – Binding Actions

In this chapter, you will learn how to integrate actions into the Graphical User Interface (GUI) components; some of the actions will be associated with the canvas and others with the Widget management. We will learn how to handle events dynamically in order to make the application respond to the user interactions. In this chapter, you will acquire the following skills:

  • Reference different parts of the GUI through IDs and properties

  • Override, bind, unbind, and create Kivy events

  • Add widgets to other widgets dynamically

  • Add vertex and context instructions to the canvas dynamically

  • Translate relative and absolute coordinates between a widget, its parent, and its window

  • Use properties to keep the GUI updated with the changes

This is an exciting chapter because our application will start interacting with the user applying the concepts acquired in the previous two chapters. All the basic functionality of our Comic Creator project will be ready by the end. This...