线程和并发编程范例

Qt makes it easy to write multithreaded applications. Signals and slots can be used to safely communicate between threads in your application.

Mandelbrot 范例

Mandelbrot example demonstrates multi-thread programming using Qt. It shows how to use a worker thread to perform heavy computations without blocking the main thread's event loop

队列自定义类型范例

Demonstrates multi-thread programming using Qt

信号量范例

Demonstrates multi-thread programming using Qt

等待条件范例

Demonstrates multi-thread programming using Qt

QtConcurrent namespace includes a collection of classes and functions for straightforward concurrent programming.

These examples show how to apply the basic techniques of concurrent programming to simple problems.

图像比例缩放范例

演示如何异步缩放图像

地图范例

演示如何同步比例缩放图像

QtConcurrent 进度对话框范例

演示如何监视活动进程的进度

QtConcurrent 单词计数范例

演示如何使用 map-reduce (映射缩减) 算法

运行函数范例

演示如何并发运行标准函数

Examples marked with an asterisk (*) are fully documented.