Kivy Cookbook

Enhance your skills in developing multi-touch applications with Kivy

Kivy Cookbook

Hugo Solis

1 customer reviews
Enhance your skills in developing multi-touch applications with Kivy
Mapt Subscription
FREE
$29.99/m after trial
eBook
$28.00
RRP $39.99
Save 29%
Print + eBook
$49.99
RRP $49.99
What do I get with a Mapt Pro subscription?
  • Unlimited access to all Packt’s 5,000+ eBooks and Videos
  • Early Access content, Progress Tracking, and Assessments
  • 1 Free eBook or Video to download and keep every month after trial
What do I get with an eBook?
  • Download this book in EPUB, PDF, MOBI formats
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
What do I get with Print & eBook?
  • Get a paperback copy of the book delivered to you
  • Download this book in EPUB, PDF, MOBI formats
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
What do I get with a Video?
  • Download this Video course in MP4 format
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
$0.00
$28.00
$49.99
$29.99p/m after trial
RRP $39.99
RRP $49.99
Subscription
eBook
Print + eBook
Start 30 Day Trial
Subscribe and access every Packt eBook & Video.
 
  • 5,000+ eBooks & Videos
  • 50+ New titles a month
  • 1 Free eBook/Video to keep every month
Start Free Trial
 
Preview in Mapt

Book Details

ISBN 139781783987382
Paperback246 pages

Book Description

Kivy is an open-source Python library for rapid development of applications that make use of innovative user interfaces, such as multi-touch apps. It is a promising Python framework to develop UI and UX apps in a cross-platform environment, under the Python philosophy.

Kivy Cookbook is a practical book that will guide you through the Kivy framework to develop apps and get your apps ready for distribution in App Store and Android devices.

You will start off with installing Kivy and building your interfaces. You will learn how to work the accelerometer and create custom events. Then, you will understand how to use the basics, buttons, labels and text inputs and manipulate the widget tree. Next, you will be able to work with manipulating instructions, create an atlas and layouts. Moving on, you will learn packing for Windows and packing for iOS, and use TestDrive.

By the end of the book, you will have learnt in detail the relevant features and tools in Kivy and how to create portable packages to distribute your apps in the most used platforms.

Table of Contents

Chapter 1: Kivy and the Kv Language
Introduction
Installing Kivy
Building your interfaces
Declaring properties within a class
Relating Python code and the Kv language
Referencing widgets
Accessing widgets defined inside the Kv language in your Python code
Reusing styles in multiple widgets
Designing with the Kv language
Running your code
Using Kivy garden
Chapter 2: Input, Motion, and Touch
Introduction
Using the mouse
Evolving to the touchscreen
Working with the accelerometer
Using the gyroscope
The differences between the touch and motion events
Recognizing touch shapes
Detecting multitapping
Grabbing touch events
Recording gestures
Chapter 3: Events
Introduction
Scheduling a one-time event
Scheduling a repetitive event
Triggering events
Defining widget events
Creating custom events
Attaching callbacks
Declaring a property
Compounding properties
Chapter 4: Widgets
Introduction
Using the basics: buttons, labels, and text inputs
Manipulating the widget tree
Traversing the tree
Using swappable widgets
Organizing with layouts
Using FloatLayout
Using BoxLayout
Using GridLayout
Using StackLayout
Using RelativeLayout
Using AnchorLayout
Working with ActionBar
Chapter 5: Graphics – Canvas and Instructions
Introduction
Separating with the screen manager
Using drawing instructions
Using context instructions
Working with manipulating instructions
Rotating, translating, and scaling the canvas
Modifying with multitouching
Storing and retrieving the coordinate space context
Introducing animations
Chapter 6: Advanced Graphics – Shaders and Rendering
Introduction
Using Carousel
Creating and using Atlas
Creating layouts
Editing shaders
Creating widgets
Creating your own shader
Rendering in a Framebuffer
Optimizing graphics
Chapter 7: The API in Detail
Introduction
Getting to know the API
Using the asynchronous data loader
Logging objects
Parsing
Applying utils
Leveraging the factory object
Working with audio
Working with video
Working with a camera
Using spelling
Adding effects
Advanced text manipulation
Chapter 8: Packaging our Apps for PC
Introduction
Packaging for Windows
Including multimedia for Windows
Running apps in Windows
Packaging for Mac OS
Including multimedia for Mac OS
Running apps in Mac OS
Packaging for Linux
Including multimedia for Linux
Running apps in Linux
Chapter 9: Kivy for Mobile Devices
Introduction
Packaging for iOS
Resizing the screen into iOS
Leveraging mobile features in iOS
Preparing for the App Store
Packaging for Android
Resizing the screen into Android
Leveraging mobile features in Android

What You Will Learn

  • Access widgets defined inside Kv language in your Python code
  • Handle Kivy events to control widgets, touches, the mouse, the keyboard, and animations
  • Recognize touch shapes and detecting multi-tapping
  • Create custom events and declare properties
  • Organizing your layouts while working with the ActionBar
  • Store and retrieve the coordinate space context
  • Create your own shader and render in a framebuffer
  • Leverage Factory objects, multi-touch in iOS and multi-touch in Android

Authors

Table of Contents

Chapter 1: Kivy and the Kv Language
Introduction
Installing Kivy
Building your interfaces
Declaring properties within a class
Relating Python code and the Kv language
Referencing widgets
Accessing widgets defined inside the Kv language in your Python code
Reusing styles in multiple widgets
Designing with the Kv language
Running your code
Using Kivy garden
Chapter 2: Input, Motion, and Touch
Introduction
Using the mouse
Evolving to the touchscreen
Working with the accelerometer
Using the gyroscope
The differences between the touch and motion events
Recognizing touch shapes
Detecting multitapping
Grabbing touch events
Recording gestures
Chapter 3: Events
Introduction
Scheduling a one-time event
Scheduling a repetitive event
Triggering events
Defining widget events
Creating custom events
Attaching callbacks
Declaring a property
Compounding properties
Chapter 4: Widgets
Introduction
Using the basics: buttons, labels, and text inputs
Manipulating the widget tree
Traversing the tree
Using swappable widgets
Organizing with layouts
Using FloatLayout
Using BoxLayout
Using GridLayout
Using StackLayout
Using RelativeLayout
Using AnchorLayout
Working with ActionBar
Chapter 5: Graphics – Canvas and Instructions
Introduction
Separating with the screen manager
Using drawing instructions
Using context instructions
Working with manipulating instructions
Rotating, translating, and scaling the canvas
Modifying with multitouching
Storing and retrieving the coordinate space context
Introducing animations
Chapter 6: Advanced Graphics – Shaders and Rendering
Introduction
Using Carousel
Creating and using Atlas
Creating layouts
Editing shaders
Creating widgets
Creating your own shader
Rendering in a Framebuffer
Optimizing graphics
Chapter 7: The API in Detail
Introduction
Getting to know the API
Using the asynchronous data loader
Logging objects
Parsing
Applying utils
Leveraging the factory object
Working with audio
Working with video
Working with a camera
Using spelling
Adding effects
Advanced text manipulation
Chapter 8: Packaging our Apps for PC
Introduction
Packaging for Windows
Including multimedia for Windows
Running apps in Windows
Packaging for Mac OS
Including multimedia for Mac OS
Running apps in Mac OS
Packaging for Linux
Including multimedia for Linux
Running apps in Linux
Chapter 9: Kivy for Mobile Devices
Introduction
Packaging for iOS
Resizing the screen into iOS
Leveraging mobile features in iOS
Preparing for the App Store
Packaging for Android
Resizing the screen into Android
Leveraging mobile features in Android

Book Details

ISBN 139781783987382
Paperback246 pages
Read More
From 1 reviews

Read More Reviews

Recommended for You

Python 3 Object-oriented Programming - Second Edition Book Cover
Python 3 Object-oriented Programming - Second Edition
$ 39.99
$ 28.00
Mastering Object-oriented Python Book Cover
Mastering Object-oriented Python
$ 26.99
$ 18.90
Python GUI Programming Cookbook Book Cover
Python GUI Programming Cookbook
$ 35.99
$ 25.20
Python Machine Learning Book Cover
Python Machine Learning
$ 35.99
$ 25.20
Python Data Analysis Book Cover
Python Data Analysis
$ 29.99
$ 21.00
Zen Cart: E-commerce Application Development Book Cover
Zen Cart: E-commerce Application Development
$ 29.99
$ 21.00