Qt Examples And Tutorials

A collection of code samples and tutorials are provided with Qt to help new users get started with Qt development. These documents cover a range of topics, from basic use of widgets to step-by-step tutorials that show how an application is put together.

The examples are part of the Qt packages. Visit the Downloads page for more information.

Running the Examples

Open and run examples within Qt Creator's Welcome mode. Most of the examples run on various platforms and to search for platform-specific examples, type the platform name (or any keywords) in the search field. For example, typing Android in the search field lists the examples that are fully compatible with Android.

For more information about running examples in Qt Creator, visit the Building and Running an Example page.

Application Examples

Calqlatr

A Qt Quick app designed for portrait devices that uses custom components, animated with AnimationController, and JavaScript for the application logic.

Coffee Machine

A Qt Quick application with a state-based custom user interface.

Dice

A dice throwing application that demonstrates using Qt Quick 3D Physics and Qt Quick 3D.

Document Viewer

A Widgets application to display and print JSON, text, and PDF files.

FX & Material Showroom

Demonstrates material and effects capabilities of Qt Quick 3D. This example demonstrates how you can use particle effects and materials in Qt Quick 3D.

Getting Started Programming with Qt Quick

A tutorial for Qt Quick based on an alarms application.

Media Player Example

Playing audio and video using Qt Quick.

Photo Surface

A QML app for touch devices that uses a Repeater with a FolderListModel to access content in a folder, and a PinchHandler to handle pinch gestures on the fetched content.

Qt Quick Demo - RESTful API client

Example of how to create a RESTful API QML client.

Robot Arm Example

Demonstrates how to add a C++ backend to a 3D project from Qt Design Studio. This example demonstrates adding a C++ backend to a 3D project created in Qt Design Studio. The example itself consists of an interactive industrial robot arm in a Qt Quick 3D scene. The 2D UI to control the robot arm is implement using Qt Quick Controls.

Same Game

A QML implementation of the popular puzzle game by Kuniaki Moribe.

Thermostat

A user interface for a home thermostat, implemented in Qt Quick. It demonstrates how to create responsive applications that scale from large desktop displays to mobile and small embedded displays.

To Do List Example

A QML implementation of to do list application that demonstrates how to create application thats looks native on any platform.

Desktop

Media Player Example

Playing audio and video using Qt Quick.

Mobile

Calqlatr

A Qt Quick app designed for portrait devices that uses custom components, animated with AnimationController, and JavaScript for the application logic.

Coffee Machine

A Qt Quick application with a state-based custom user interface.

Embedded

Coffee Machine

A Qt Quick application with a state-based custom user interface.

Thermostat

A user interface for a home thermostat, implemented in Qt Quick. It demonstrates how to create responsive applications that scale from large desktop displays to mobile and small embedded displays.

Graphics

Qt Quick Demo - Clocks

A QML clock application that demonstrates using a ListView type to display data generated by a ListModel and a SpringAnimation type to animate images.

Qt Widgets - Text Viewer Plugin Example

A widget example with menus, toolbars and a status bar.

Multimedia

Data Visualization & 3D

FX & Material Showroom

Demonstrates material and effects capabilities of Qt Quick 3D. This example demonstrates how you can use particle effects and materials in Qt Quick 3D.

StocQt

A configurable stock chart for 100 stocks.

Data Processing & I/O

Connectivity

Networking

Qt Quick Demo - RESTful API client

Example of how to create a RESTful API QML client.

Positioning & Location

User Interface Components

Web Technologies

Qt Quick Demo - RSS News

A QML RSS news reader that uses XmlListModel and XmlListModelRole custom QML types to download XML data, ListModel and ListElement to create a category list, and ListView to display the data.

Community Examples

To view and run examples provided through the Qt Project, visit the Community Examples page.

All Examples

All Qt Examples lists all examples categorized by the Qt module they belong to.