绘画示例

Qt 的绘制系统能使用抗锯齿以亚像素精度渲染矢量图形、图像和基于字体的轮廓文本,以提高渲染质量。

这些示例展示了使用 Qt 绘制时最常用的技术,从绘制简单基元等基本概念到变换的使用。

Affine Transformations

演示 QPainter 中的仿射变换是如何工作的。

Basic Drawing Example

基本绘图示例展示了如何使用 QPainter 类以各种样式显示基本图形基元。

Composition Modes

演示如何在 QPainter 中使用合成模式。

Gradients

演示如何在 QPainter 中使用渐变。

Image Composition Example

演示如何在 QPainter 中使用合成模式。

Painter Paths Example

绘制路径(Painter Paths)示例展示了如何使用绘制路径来构建复杂的渲染形状。

Path Stroking

路径描边示例展示了 QPainter 中可使用的各种类型的笔。

Transformations Example

变换(Transformations)示例展示了变换如何影响 QPainter 渲染图形基元的方式。

Vector Deformation

演示如何操作 QPainterPath 的元素。

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.