Free Sample
+ Collection

GNOME 3 Application Development Beginner's Guide

Beginner's Guide
Mohammad Anwari

Step-by-step practical guide to get to grips with GNOME application development
$26.99
$44.99
RRP $26.99
RRP $44.99
eBook
Print + eBook

Want this title & more?

$12.99 p/month

Subscribe to PacktLib

Enjoy full and instant access to over 2000 books and videos – you’ll find everything you need to stay ahead of the curve and make sure you can always get the job done.

Book Details

ISBN 139781849519427
Paperback366 pages

About This Book

  • Full of easy to follow tutorials with ready-to-run code
  • Covers most of the subsystems in the GNOME 3 platform stack, from low to high level
  • Adapts common good development practices with GNOME 3 development environment

Who This Book Is For

If you have programming skill either in Linux or other operating systems and want to have GNOME 3 as one of your deployment targets, then this book is for you. This book is also for commercial software developers or an open source software hacker. The reader needs to be familiar with Vala and JavaScript before starting to develop Gtk+ and Clutter applications.

Table of Contents

Chapter 1: Installing GNOME 3 and SDK
System requirements
GNOME 3 desktop architecture
GNOME and the SDK
Time for action – installing GNOME and SDK in Fedora 17
Time for action – installing GNOME and SDK in openSUSE 12
Time for action – installing GNOME and SDK in Debian Testing
Time for action – installing GNOME and SDK in Ubuntu 12.04
Summary
Chapter 2: Preparing Our Weapons
Firing up Anjuta
Time for action – creating a new Vala project
Navigation between tabs
Time for action – navigating between tabs
Comment block
Time for action – commenting/uncommenting a block
Time for action – running the program for the first time
Editing UI
Time for action – editing UI
Time for action – adding a label and a button
Time for action – changing widget properties
A responsive button
Time for action – making the button responsive
Tracking symbols
Time for action – finding a symbol
Getting help
Summary
Chapter 3: Programming Languages
Programming GNOME with JavaScript
Time for action – saying hello to Seed
Time for action – running our program with Seed
Time for action – playing with data types
Time for action – controlling Iteration
Time for action – manipulating an array
Time for action – using the JavaScript object
Time for action – playing with constructors
Time for action – adding prototypes
Time for action – modifying the prototype of an object
Time for action – modularizing our program
Getting to know Vala
Time for action – entry point to our program
Time for action – defining member access
Time for action – experiment with data types
Time for action – adding the Gee library
Time for action – Gee in action
Time for action – watching for signals
Summary
Chapter 4: Using GNOME Core Libraries
Before we start
The GLib main loop
Time for action – playing with the GLib main loop
GObject signals
Time for action – handling GObject signals
GLib properties
Time for action – accessing properties
Configuration files
Time for action – reading configuration files
GIO, the input/output library
Time for action – accessing files
Network access with GIO
Time for action – accessing a network
Understanding GSettings
Time for action – learning GSettings
GSettings API
Time for action – accessing GSettings programmatically
Summary
Chapter 5: Building Graphical User Interface Applications
Before we start
Creating a basic GTK+ application
Time for action – implementing the mockup
Time for action – adding icons to the buttons
Porting the code without GtkBuilder
Time for action – programming with raw GTK+
GUI programming with Clutter
Time for action – implementing the mockup with Clutter
Summary
Chapter 6: Creating Widgets
Before we take off
Overriding the widget's standard functions
Time for action – overriding the set_title function
Adding new functionalities
Time for action – making a composite widget
Maintaining compatibility
Implementing a GTK+ custom widget
Time for action – implementing the custom widget
Maintaining widgets in a library
Time for action – creating a library
Summary
Chapter 7: Having Fun with Multimedia
Packages required
Understanding the basic concept of GStreamer
Accessing the GStreamer pipeline with the command line
Time for action – testing the pipeline
Time for action – programmatically playing the audio
Time for action – handling the events
Playing a video media
Time for action – playing video
Time for action – programmatically playing the video
Summary
Chapter 8: Playing with Data
Presenting data with TreeView
Time for action – using TreeView
The Evolution Data Server (EDS) architecture
Time for action – setting up the address book and the calendar data source
Time for action – accessing the address book
Have a go hero – saving data to the address book
Summary
Chapter 9: Deploying HTML5 Applications with GNOME
Before we start
Embedding WebKit
Time for action – embedding WebKit
Runtime with JavaScriptCore
Time for action – calling the Vala object from the frontend
Time for action – connecting GNOME with client-side JavaScript
Summary
Chapter 10: Desktop Integration
Talking to each other with D-Bus
Time for action – listening to D-Bus
The GNOME session manager
Time for action – talking to the session manager
Launcher
Time for action – putting our application in the launcher
GNOME keyring
Time for action – storing passwords securely
Notification system
Time for action – sending notifications
Summary
Chapter 11: Making Our Applications Go International
Understanding locale
Time for action – getting the available locales
Time for action – adding a locale
Time for action – getting different outputs with different locales
i18n in a Vala project
Time for action – bootstrapping the infrastructure
Time for action – creating a UI
Time for action – translating UI texts
The localization process
Summary
Chapter 12: Quality Made Easy
Reasons for performing unit testing
Time for action – creating our first unit test
Time for action – creating stubs
Testing GUI modules
Time for action – testing a GTK+ module
Summary
Chapter 13: Exciting Projects
Part I – web browser
Time for action – designing our UI
Time for action – preparing the build infrastructure
Time for action – finishing up
Part II – A Twitter client
Time for action – implementing the Twitter client
Summary

What You Will Learn

  • GNOME 3 development environment installation in many popular Linux distributions
  • Best engineering practices in GNOME, from mock up to the running app
  • Accessing data with Evolution Data Server
  • Internationalization and localization in GNOME 3
  • Unit testing framework in GLib, Gdk, and Gtk+
  • Multimedia programming with GStreamer
  • GNOME 3 development environment installation in many popular Linux distributions
  • GNOME 3 desktop integration

In Detail

GNOME is a desktop environment and graphical user interface that runs on top of a computer operating system. GNOME 3 provides both modern desktops and development platforms with more than 50 supported languages of the world. Since 1999, it has been evolving into a very nice desktop to use and an interesting platform to develop on.

"GNOME 3 Application Development Beginner's Guide" is about developing GNOME 3 application with Vala and JavaScript programming languages. It guides the reader to build Gtk+, Clutter, and HTML5 applications on the GNOME 3 platform. It covers GNOME 3 specific subsystems such as data access, multimedia, networking, and filesystem. It also covers good software engineering practices such as localization and testing.

This book is full of step-by-step tutorials and ready to run codes. The examples are written in a simple and straightforward way  to make it easier for the reader to get a thorough understanding of the topics.

The book starts with the installation of GNOME 3 and ends with building two exciting projects, a web browser and a Twitter client. The book starts from the basics and gradually talks about more advanced topics.

It then guides the readers in using the development environment starts from Anjuta IDE, Glade, and DevHelp. The essential GNOME 3 subsystems like GStreamer, GLib, GIO, GSettings, Evolutions Data Server, WebKit, and GNOME desktop are then uncovered one by one. Then the internationalization, localization, and unit testing techniques are brought up.

"GNOME 3 Application Development Beginner's Guide" is really a guide that a novice GNOME 3 application developer must not miss.

Authors

Read More