Mastering Qt 5

Master application development by writing succinct, robust, and reusable code with Qt 5
Preview in Mapt

Mastering Qt 5

Guillaume Lazar, Robin Penea

12 customer reviews
Master application development by writing succinct, robust, and reusable code with Qt 5
Mapt Subscription
FREE
โ‚ฌ29.98/m after trial
eBook
โ‚ฌ26.88
RRP โ‚ฌ38.38
Save 29%
Print + eBook
โ‚ฌ38.99
RRP โ‚ฌ38.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
โ‚ฌ26.88
โ‚ฌ38.99
โ‚ฌ29.99 p/m after trial
RRP โ‚ฌ38.38
RRP โ‚ฌ38.99
Subscription
eBook
Print + eBook
Start 14 Day Trial

Frequently bought together


Mastering Qt 5 Book Cover
Mastering Qt 5
โ‚ฌ 38.38
โ‚ฌ 26.88
Python GUI Programming Recipes using PyQt5 [Video] Book Cover
Python GUI Programming Recipes using PyQt5 [Video]
โ‚ฌ 142.78
โ‚ฌ 121.38
Buy 2 for โ‚ฌ35.72
Save โ‚ฌ121.20
Add to Cart

Book Details

ISBN 139781786467126
Paperback526 pages

Book Description

Qt 5.7 is an application development framework that provides a great user experience and develops full-capability applications with Qt Widgets, QML, and even Qt 3D.

This book will address challenges in successfully developing cross-platform applications with the Qt framework. Cross-platform development needs a well-organized project. Using this book, you will have a better understanding of the Qt framework and the tools to resolve serious issues such as linking, debugging, and multithreading. Your journey will start with the new Qt 5 features.

Then you will explore different platforms and learn to tame them. Every chapter along the way is a logical step that you must take to master Qt. The journey will end in an application that has been tested and is ready to be shipped.

Table of Contents

Chapter 1: Get Your Qt Feet Wet
Creating a project
MainWindow structure
Qt Designer
Signals and slots
Custom QWidget
Adding a task
Using a QDialog
Distributing code responsibility
Emitting a custom signal using lambdas
Simplifying with the auto type and a range-based for loop
Summary
Chapter 2: Discovering QMake Secrets
Designing a cross-platform project
Transforming SysInfo into a singleton
Exploring Qt Charts
CpuWidget using QCharts
Memory using Qcharts
The .pro file in depth
Under the hood of qmake
Beneath Q_OBJECT and signals/slots
Summary
Chapter 3: Dividing Your Project and Ruling Your Code
Designing a maintainable project
Defining data classes
Storing your data in a database
Protecting your code with a smart pointer
Implementing the model
Summary
Chapter 4: Conquering the Desktop UI
Creating a GUI linked to a core shared library
Listing your albums with AlbumListWidget
Creating a ThumbnailProxyModel
Displaying the selected album with AlbumWidget
Enhancing thumbnails with PictureDelegate
Displaying a picture with PictureWidget
Composing your Gallery app
Summary
Chapter 5: Dominating the Mobile UI
Starting with Qt Quick and QML
Checking your development environment
Creating a Qt Quick project
Preparing your Qt Quick gallery entry point
Displaying albums with ListView
Theming the application with a QML singleton
Loading a database on mobile
Creating a new album from a custom InputDialog
Loading images with an ImageProvider
Displaying thumbnails in a GridView
Swiping through full resolution pictures
Summary
Chapter 6: Even Qt Deserves a Slice of Raspberry Pi
Discovering Qt3D
Configuring Qt for your Raspberry Pi
Creating an entry point for your Qt3D code
Setting up the scene
Assembling your Qt3D entities
Preparing the board game
Crafting entities from the factory
Building a snake engine in JavaScript
Varying the HUD with QML states
Profiling your QML application
Summary
Chapter 7: Third-Party Libraries Without a Headache
Creating your Qt Designer plugin
Configuring the project for Windows
Configuring the project for Linux
Configuring the project for Mac
Implementing your OpenCV filters
Designing the UI with FilterWidget
Exposing your plugin to Qt Designer
Using your Qt Designer plugin
Building the image-filter application
Summary
Chapter 8: Animations - Its Alive, Alive!
Preparing an SDK
Creating your plugins
Loading your plugins dynamically
Using the plugins inside the application
Discovering the Animation Framework
Making your thumbnails jump
Fading the picture in
Flashing the thumbnail in a sequence
Summary
Chapter 9: Keeping Your Sanity with Multithreading
Discovering QThread
Flying over Qt multithreading technologies
Architecting the Mandelbrot project
Defining a Job class with QRunnable
Using QThreadPool in MandelbrotCalculator
Displaying the fractal with MandelbrotWidget
Summary
Chapter 10: Need IPC? Get Your Minions to Work
Architecturing an IPC project
Laying down the foundations with an SDK
Working with QDataStream and QTcpSocket
Interacting with sockets in the worker
Interacting with sockets from the application
Building your own QTcpServer
Summary
Chapter 11: Having Fun with Serialization
Architecting the drum machine project
Creating a drum track
Making your objects serializable with QVariant
Serializing objects in JSON format
Serializing objects in XML format
Serializing objects in binary format
Playing low latency sounds with QSoundEffect
Triggering a QButton with your keyboard
Bringing PlaybackWorker to life
Accepting mouse drag and drop events
Summary
Chapter 12: You Shall (Not) Pass with QTest
Discovering Qt Test
Executing your tests
Writing factorized tests with datasets
Benchmarking your code
Testing your GUI
Spying on your application with QSignalSpy
Summary
Chapter 13: All Packed and Ready to Deploy
Packaging your application
Packaging for Windows
Packaging for Linux with a distribution package
Packaging for Linux with AppImage
Packaging for Mac OS X
Packaging for Android
Packaging for iOS
Summary
Chapter 14: Qt Hat Tips and Tricks
Managing your workspace with sessions
Searching with the Locator
Increasing the compilation speed
Examining the memory with Qt Creator
Generating random numbers
Silencing unused variable warnings
Logging custom objects to QDebug
Improving log messages
Saving your logs to a file
Generating a command-line interface
Sending and receiving HTTP data
Summary

What You Will Learn

  • Create stunning UIs with Qt Widget and Qt Quick
  • Develop powerful, cross-platform applications with the Qt framework
  • Design GUIs with the Qt Designer and build a library in it for UI preview
  • Handle user interaction with the Qt signal/slot mechanism in C++
  • Prepare a cross-platform project to host a third-party library
  • Build a Qt application using the OpenCV API
  • Use the Qt Animation framework to display stunning effects
  • Deploy mobile apps with Qt and embedded platforms

Authors

Table of Contents

Chapter 1: Get Your Qt Feet Wet
Creating a project
MainWindow structure
Qt Designer
Signals and slots
Custom QWidget
Adding a task
Using a QDialog
Distributing code responsibility
Emitting a custom signal using lambdas
Simplifying with the auto type and a range-based for loop
Summary
Chapter 2: Discovering QMake Secrets
Designing a cross-platform project
Transforming SysInfo into a singleton
Exploring Qt Charts
CpuWidget using QCharts
Memory using Qcharts
The .pro file in depth
Under the hood of qmake
Beneath Q_OBJECT and signals/slots
Summary
Chapter 3: Dividing Your Project and Ruling Your Code
Designing a maintainable project
Defining data classes
Storing your data in a database
Protecting your code with a smart pointer
Implementing the model
Summary
Chapter 4: Conquering the Desktop UI
Creating a GUI linked to a core shared library
Listing your albums with AlbumListWidget
Creating a ThumbnailProxyModel
Displaying the selected album with AlbumWidget
Enhancing thumbnails with PictureDelegate
Displaying a picture with PictureWidget
Composing your Gallery app
Summary
Chapter 5: Dominating the Mobile UI
Starting with Qt Quick and QML
Checking your development environment
Creating a Qt Quick project
Preparing your Qt Quick gallery entry point
Displaying albums with ListView
Theming the application with a QML singleton
Loading a database on mobile
Creating a new album from a custom InputDialog
Loading images with an ImageProvider
Displaying thumbnails in a GridView
Swiping through full resolution pictures
Summary
Chapter 6: Even Qt Deserves a Slice of Raspberry Pi
Discovering Qt3D
Configuring Qt for your Raspberry Pi
Creating an entry point for your Qt3D code
Setting up the scene
Assembling your Qt3D entities
Preparing the board game
Crafting entities from the factory
Building a snake engine in JavaScript
Varying the HUD with QML states
Profiling your QML application
Summary
Chapter 7: Third-Party Libraries Without a Headache
Creating your Qt Designer plugin
Configuring the project for Windows
Configuring the project for Linux
Configuring the project for Mac
Implementing your OpenCV filters
Designing the UI with FilterWidget
Exposing your plugin to Qt Designer
Using your Qt Designer plugin
Building the image-filter application
Summary
Chapter 8: Animations - Its Alive, Alive!
Preparing an SDK
Creating your plugins
Loading your plugins dynamically
Using the plugins inside the application
Discovering the Animation Framework
Making your thumbnails jump
Fading the picture in
Flashing the thumbnail in a sequence
Summary
Chapter 9: Keeping Your Sanity with Multithreading
Discovering QThread
Flying over Qt multithreading technologies
Architecting the Mandelbrot project
Defining a Job class with QRunnable
Using QThreadPool in MandelbrotCalculator
Displaying the fractal with MandelbrotWidget
Summary
Chapter 10: Need IPC? Get Your Minions to Work
Architecturing an IPC project
Laying down the foundations with an SDK
Working with QDataStream and QTcpSocket
Interacting with sockets in the worker
Interacting with sockets from the application
Building your own QTcpServer
Summary
Chapter 11: Having Fun with Serialization
Architecting the drum machine project
Creating a drum track
Making your objects serializable with QVariant
Serializing objects in JSON format
Serializing objects in XML format
Serializing objects in binary format
Playing low latency sounds with QSoundEffect
Triggering a QButton with your keyboard
Bringing PlaybackWorker to life
Accepting mouse drag and drop events
Summary
Chapter 12: You Shall (Not) Pass with QTest
Discovering Qt Test
Executing your tests
Writing factorized tests with datasets
Benchmarking your code
Testing your GUI
Spying on your application with QSignalSpy
Summary
Chapter 13: All Packed and Ready to Deploy
Packaging your application
Packaging for Windows
Packaging for Linux with a distribution package
Packaging for Linux with AppImage
Packaging for Mac OS X
Packaging for Android
Packaging for iOS
Summary
Chapter 14: Qt Hat Tips and Tricks
Managing your workspace with sessions
Searching with the Locator
Increasing the compilation speed
Examining the memory with Qt Creator
Generating random numbers
Silencing unused variable warnings
Logging custom objects to QDebug
Improving log messages
Saving your logs to a file
Generating a command-line interface
Sending and receiving HTTP data
Summary

Book Details

ISBN 139781786467126
Paperback526 pages
Read More
From 12 reviews

Read More Reviews

Recommended for You

Qt 5 Blueprints Book Cover
Qt 5 Blueprints
โ‚ฌ 40.78
โ‚ฌ 28.56
Learning Vulkan Book Cover
Learning Vulkan
โ‚ฌ 46.78
โ‚ฌ 32.76
Modern Python Cookbook Book Cover
Modern Python Cookbook
โ‚ฌ 41.98
โ‚ฌ 29.40
C++17 STL Cookbook Book Cover
C++17 STL Cookbook
โ‚ฌ 45.58
โ‚ฌ 31.92
Mastering C++ Multithreading Book Cover
Mastering C++ Multithreading
โ‚ฌ 41.98
โ‚ฌ 29.40
Beginning C++ Programming Book Cover
Beginning C++ Programming
โ‚ฌ 45.58
โ‚ฌ 31.92