O ne of the most important aspects of an application is the interface that is provided to
interact with the user. With the unprecedented popularity of computers in society today,
people have come to expect those user interfaces to be graphical, and the question of which
graphical toolkit to use quickly arises for any developer. For many, the cross-platform, feature-
rich GTK+ library is the obvious choice.
Learning GTK+ can be a daunting task, because many features lack documentation, and
even more are difficult to understand from only the API documentation. Foundations of GTK+
Development aims to decrease the learning curve and set you on your way to creating cross-
platform graphical user interfaces for your applications.
Each chapter in this book contains multiple examples that will help you further your
understanding. In addition to these examples, the final chapter of this book provides five
complete applications that incorporate topics from the previous chapters. These applications
will show you how to bring together what you have learned to accomplish various projects.
The beginning of each chapter provides an overview of what that chapter will cover, so that
you are able to skip around if you want. Most chapters also contain exercises to test your under-
standing of the material. I recommend that you complete all of the exercises before continuing,
because the best way to learn GTK+ is to use it.
At the end of this book, you will find multiple appendixes that can serve as references for
various aspects of GTK+. These appendixes include tables listing signals, styles, and properties
for every widget in GTK+ and a complete list of stock items and GError types. These appendixes
will remain a useful reference even after you have finished reading the book and begin creating
your own applications. In addition, Appendix F contains explanations of the solutions to all of
the exercises throughout the book.
Who Should Read This Book
Because this book begins with the basics and works up to more difficult concepts, you do not
need any previous knowledge of GTK+ development to use this book. This book does assume
that you have a decent grasp of the C programming language. You should also be comfortable
with running commands and terminating applications (Ctrl+C) in a Linux terminal.
In addition to a grasp of the C programming language, some parts of this book may be diffi-
cult to understand without some further knowledge about programming for Linux in general.
You will get more out of this book if you already comprehend basic object-oriented concepts. It
is also helpful to know how Linux handles processes.
You can still use this book if you do not already know how to implement object orienta-
tion or manage processes in Linux, but you may need to supplement this book with one or
more online resources. A list of helpful links and tutorials can be found on the book’s web
■I N T R O D U C T I O N
site, which is located at www.gtkbook.com
. You can also find more information about the book