PySide6.QtQuick#
属性属性.PySide6.QtQuick.QSGGeometry.Attribute.position属性.PySide6.QtQuick.QSGGeometry.Attribute.tupleSize属性.PySide6.QtQuick.QSGGeometry.Attribute.type属性.PySide6.QtQuick.QSGGeometry.Attribute.isVertexCoordinate属性.PySide6.QtQuick.QSGGeometry.Attribute.attributeType属性.PySide6.QtQuick.QSGGeometry.Attribute.reserved属性集属性集.PySide6.QtQuick.QSGGeometry.AttributeSet.count属性集.PySide6.QtQuick.QSGGeometry.AttributeSet.stride属性集.PySide6.QtQuick.QSGGeometry.AttributeSet.attributes彩色点2D彩色点2D.PySide6.QtQuick.QSGGeometry.ColoredPoint2D.x彩色点2D.PySide6.QtQuick.QSGGeometry.ColoredPoint2D.y彩色点2D.PySide6.QtQuick.QSGGeometry.ColoredPoint2D.r彩色点2D.PySide6.QtQuick.QSGGeometry.ColoredPoint2D.g彩色点2D.PySide6.QtQuick.QSGGeometry.ColoredPoint2D.b彩色点2D.PySide6.QtQuick.QSGGeometry.ColoredPoint2D.a点2D点2D.PySide6.QtQuick.QSGGeometry.Point2D.x点2D.PySide6.QtQuick.QSGGeometry.Point2D.yQQuickAsyncImageProviderQQuickFramebufferObjectQQuickGraphicsConfigurationQQuickGraphicsDeviceQQuickImageProviderQQuickImageResponseQQuickItemQQuickItemGrabResultQQuickPaintedItemQQuickRenderControlQQuickRenderTargetQQuickRhiItemQQuickRhiItemRendererQQuickTextDocumentQQuickTextureFactoryQQuickTransformQQuickViewQQuickWindowQSGBasicGeometryNodeQSGClipNodeQSGDynamicTextureQSGFlatColorMaterialQSGGeometryQSGGeometryNodeQSGMaterialQSGMaterialShaderQSGMaterialTypeQSGNodeQSGOpacityNodeQSGOpaqueTextureMaterialQSGOpaqueTextureMaterial.PySide6.QtQuick.QSGOpaqueTextureMaterial.m_textureQSGOpaqueTextureMaterial.PySide6.QtQuick.QSGOpaqueTextureMaterial.m_filteringQSGOpaqueTextureMaterial.PySide6.QtQuick.QSGOpaqueTextureMaterial.m_mipmap_filteringQSGOpaqueTextureMaterial.PySide6.QtQuick.QSGOpaqueTextureMaterial.m_horizontal_wrapQSGOpaqueTextureMaterial.PySide6.QtQuick.QSGOpaqueTextureMaterial.m_vertical_wrapQSGOpaqueTextureMaterial.PySide6.QtQuick.QSGOpaqueTextureMaterial.m_anisotropy_levelQSGOpaqueTextureMaterial.PySide6.QtQuick.QSGOpaqueTextureMaterial.m_reservedQSGRectangleNodeQSGRenderNodeQSGRendererInterfaceQSGSimpleRectNodeQSGSimpleTextureNodeQSGTextNodeQSGTextureQSGTextureMaterialQSGTextureProviderQSGTransformNodeQSGVertexColorMaterial渲染状态渲染状态渲染器纹理点2D纹理点2D.PySide6.QtQuick.QSGGeometry.TexturedPoint2D.x纹理点2D.PySide6.QtQuick.QSGGeometry.TexturedPoint2D.y纹理点2D.PySide6.QtQuick.QSGGeometry.TexturedPoint2D.tx纹理点2D.PySide6.QtQuick.QSGGeometry.TexturedPoint2D.ty更新绘制节点数据更新绘制节点数据.PySide6.QtQuick.QQuickItem.UpdatePaintNodeData.transformNode
详细说明#
Qt Quick模块实现了QML的“标准库”
Qt Quick模块是编写QML应用的标准库。虽然Qt Qml模块提供了QML引擎和语言基础设施,但Qt Quick模块为使用QML创建用户界面提供了所有必要的基类型。它提供了一个视觉画布,包括创建和动画化视觉组件、接收用户输入、创建数据模型和视图以及延迟对象实例化的类型。
Qt Quick模块提供了一个QML API ,提供了使用QML语言创建用户界面的QML类型,以及一个C++ API 来使用C++代码扩展QML应用。
注意
一组基于Qt Quick的用户界面控件也可用于创建用户界面。请参见Qt Quick Controls以获取更多信息。
如果您对QML和Qt Quick是新手,请参见QML应用以了解如何编写QML应用。
使用模块#
QML API#
模块的QML类型通过QtQuick导入。要使用这些类型,向您的.qml文件添加以下导入语句
C++ API#
使用Qt模块的C++ API需要链接到模块库,可以直接链接,或者通过其他依赖链接。CMake和qmake等几个构建工具都为此提供了专门的支持。
使用CMake构建#
使用find_package()命令在Qt6包中定位所需模块组件
find_package(Qt6 REQUIRED COMPONENTS Quick) target_link_libraries(mytarget PRIVATE Qt6::Quick)
有关更多详细信息,请参阅使用CMake构建概述。
使用qmake构建#
要将模块配置为使用qmake构建,将模块添加到项目中 prost 文件的QT变量的值中
QT += quick
Qt Quick中的重要概念#
Qt Quick提供了创建具有流畅和动态用户界面的丰富应用的所需的一切。它使您能够围绕用户界面组件的行为以及它们如何相互连接来构建用户界面,并提供一个具有自己的坐标系和渲染引擎的视觉画布。动画和转换效果在Qt Quick中是第一类概念,您可以通过专门为粒子效果和着色器效果设计的组件添加视觉效果。
当使用Qt Quick模块时,您需要了解如何使用QML语言编写QML应用。特别是,您可以从QML应用的页面上找到QML基础和QML精华。
要了解更多关于使用QML语言的信息,请参阅Qt Qml模块文档。
C++扩展点#
文章和指南#
有关编写 QML 应用的更多信息
QML 应用 —— 使用 QML 和 Qt Quick 开发应用程序的基本信息
Qt Qml —— 提供 QML 引擎和语言基础设施的 Qt Qml 模块的文档
Qt Quick 常见做法 —— 展示如何在 Qt Quick 中完成特定任务
示例#
参考#
Qt Quick C++ 类 —— Qt Quick 模块提供的 C++ API
Qt Quick QML 类型 —— 由
QtQuick导入提供的 QML 类型列表
许可证和归属#
Qt Quick 由 Qt 公司提供商业许可证。此外,它还可用免费软件许可证。自 Qt 5.4 开始,这些免费软件许可证是 GNU Lesser General Public License 版本 3 或 GNU General Public License 版本 2。有关详细信息,请参阅 Qt 许可证。
该模块还提供了 QML 类型 。
类列表#
A |
||
C |
||
P |
||
Q |
||
R |
||
S |
||
T |
||
U |