|
C++ GUI Programming with Qt4 2nd Edition
The Only Official, Best-Practice Guide to Qt 4.3 Programming
Using Trolltech's Qt you can build industrial-strength C++ applications that run natively on Windows, Linux/Unix, Mac OS X, and embedded Linux without source code changes. Now, two Trolltech insiders have written a start-to-finish guide to getting outstanding results with the latest
version of Qt: Qt 4.3.
Packed with realistic examples and in-depth advice, this is the book Trolltech uses to teach Qt to its own new hires. Extensively revised and expanded, it reveals today's best Qt programming patterns for everything from implementing model/view architecture to using Qt 4.3's improved graphics support. You'll find proven solutions for virtually every GUI development task, as well as sophisticated techniques for providing database access, integrating XML, using subclassing, composition, and more. Whether you're new to Qt or upgrading from an older version, this book can help you accomplish everything that Qt 4.3 makes possible.
* Completely updated throughout, with significant new coverage of databases, XML, and Qtopia embedded programming
* Covers all Qt 4.2/4.3 changes, including Windows Vista support, native CSS support for widget styling, and SVG file generation
* Contains separate 2D and 3D chapters, coverage of Qt 4.3's new graphics view classes, and an introduction to QPainter's OpenGL back-end
* Includes new chapters on look-and-feel customization and application scripting
* Illustrates Qt 4's model/view architecture, plugin support, layout management, event processing, container classes, and much more
* Presents advanced techniques covered in no other book??from creating plugins to interfacing with native APIs
* Includes a new appendix on Qt Jambi, the new Java version of Qt
CONTENTS:
Series Editor's NoteForeword Preface Acknowledgments A Brief History of QtPart I: Basic Qt Chapter 1. Getting Started
Hello Qt
Making Connections
Laying Out Widgets
Using the Reference Documentation
Chapter 2. Creating Dialogs
Subclassing QDialog
Signals and Slots in Depth
Rapid Dialog Design
Dynamic Dialogs
Built-in Widget and Dialog Classes
Chapter 3. Creating Main Windows
Subclassing QMainWindow
Creating Menus and Toolbars
Setting Up the Status Bar
Implementing the File Menu
Using Dialogs
Storing Settings
Multiple Documents
Splash Screens
Chapter 4. Implementing Application Functionality
The Central Widget
Subclassing QTableWidget
Loading and Saving
Implementing the Edit Menu
Implementing the Other Menus
Subclassing QTable Widge Item
Chapter 5. Creating Custom Widgets
Customizing Qt Widgets
Subclassing QWidget
Integrating Custom Widgets with Qt Designer
Double Buffering
Part II: Intermediate Qt Chapter 6. Layout Management
Laying Out Widgets on a Form
Stacked Layouts
Splitters
Scrolling Areas
Dock Windows and Toolbars
Multiple Document Interface
Chapter 7. Event Processing
Reimplementing Event Handlers
Installing Event Filters
Staying Responsive During Intensive Processing
Chapter 8. 2D Graphics
Painting with QPainter
Coordinate System Transformations
High-Quality Rendering with QImage
Item-Based Rendering with Graphics View
Printing
Chapter 9. Drag and Drop
Enabling Drag and Drop
Supporting Custom Drag Types
Clipboard Handling
Chapter 10. Item View Classes
Using the Item View Convenience Classes
Using Predefined Models
Implementing Custom Models
Implementing Custom Delegates
Chapter 11. Container Classes
Sequential Containers
Associative Containers
Generic Algorithms
Strings, Byte Arrays, and Variants
Chapter 12. Input/Output
Reading and Writing Binary Data
Reading and Writing Text
Traversing Directories
Embedding Resources
Inter-Process Communication
Chapter 13. Databases
Connecting and Querying
Viewing Tables
Editing Records Using Forms
Presenting Data in Tabular Forms
Chapter 14. Multithreading
Creating Threads
Synchronizing Threads
Communicating with the Main Thread
Using Qt's Classes in Secondary Threads
Chapter 15. Networking
Writing FTP Clients
Writing HTTP Clients
Writing TCP Client-Server Applications
Sending and Receiving UDP Datagrams
Chapter 16. XML
Reading XML with Q XML Stream Reader
Reading XM Lwith DOM
Reading XML with SAX
Writing XML
Chapter 17. Providing Online Help
Tooltips, Status Tips, and "What's This?" Help
Using a Web Browser to Provide Online Help
Using QText Browser as a Simple Help Engine
Using QtAssistant for Powerful Online Help
Part III: Advanced QtChapter 18. Internationalization
Working with Unicode
Making Applications Translation-Aware
Dynamic Language Switching
Translating Applications
Chapter 19. Look and Feel Customization
Using Qt Style Sheets
Subclassing QStyle
Chapter 20. 3D Graphics
Drawing Using Open GL
Combining OpenGL and QPainter
Doing Overlays Using Framebuffer Objects
Chapter 21. Creating Plugins
Extending Qt with Plugins
Making Applications Plugin-Aware
Writing Application Plugins
Chapter 22. Application Scripting
Overview of the ECMA Script Language
Extending Qt Applications with Scripts
Implementing GUI Extensions Using Scripts
Automating Tasks Through Scripting
Chapter 23. Platform-Specific Features
Interfacing with Native APIs
Using Active Xon Windows
Handling X11 Session Management
Chapter 24. Embedded Programming
Getting Started with Qt/Embedded Linux
Customizing Qt/Embedded Linux
Integrating Qt Applications with Qtopia
Using Qtopia APIs
Appendix A. Obtaining and Installing Qt Appendix B. Building Qt Applications Appendix C. Introduction to Qt JambiAppendix D. Introduction to C++ for Java and C# ProgrammersIndex
|