Qt 6.4 中新类和函数
此页面包含 Qt 6.4 中引入的所有新类和函数的完整列表。
新类
新成员函数
| (自 6.4)void | setUseFetchMore(bool value) | 
| (自 6.4)QByteArray | percentDecoded(char percent) const | 
| (自 6.4)void | resize(qsizetype newSize, char c) | 
类 QColor
| (自 6.4)QColor | fromString(QAnyStringView name) | 
| (自 6.4)bool | isValidColorName(QAnyStringView name) | 
| (自 6.4)bool | isIdentity() const | 
| (自 6.4)QRgbaFloat16 | map(QRgbaFloat16 rgbafp16) const | 
| (自 6.4)QRgbaFloat32 | map(QRgbaFloat32 rgbafp32) const | 
| (自 6.4)bool | operator!=(const QColorTransform &ct1, const QColorTransform &ct2) | 
| (自 6.4)bool | operator==(const QColorTransform &ct1, const QColorTransform &ct2) | 
类 QDate
| (自 6.4)QDate | addDuration(std::chrono::days ndays) const | 
| (自 6.4)QDate | fromStdSysDays(const std::chrono::sys_days &days) | 
| (自 6.4)QDateTime | addDuration(std::chrono::milliseconds msecs) const | 
| (自 6.4)QDateTime | fromStdLocalTime(const std::chrono::local_time<std::chrono::milliseconds> &time) | 
| (自 6.4)QDateTime | fromStdTimePoint(const std::chrono::time_point<Clock, Duration> &time) | 
| (自 6.4)QDateTime | fromStdTimePoint(std::chrono::time_point<std::chrono::system_clock, std::chrono::milliseconds> time) | 
| (自 6.4)QDateTime | fromStdTimePoint(const std::chrono::local_time<std::chrono::milliseconds> &time) | 
| (自 6.4)QDateTime | fromStdZonedTime(const int &time) | 
| (自 6.4)QDateTime | operator+(const QDateTime &dateTime, std::chrono::milliseconds duration) | 
| (自 6.4)QDateTime | operator+(std::chrono::milliseconds duration, const QDateTime &dateTime) | 
| (since 6.4)QDateTime & | operator+=(std::chrono::milliseconds duration) | 
| (since 6.4)std::chrono::milliseconds | operator-(const QDateTime &lhs, const QDateTime &rhs) | 
| (自 6.4)QDateTime | operator-(const QDateTime &dateTime, std::chrono::milliseconds duration) | 
| (since 6.4)QDateTime & | operator-=(std::chrono::milliseconds duration) | 
| (since 6.4)std::chrono::sys_time<std::chrono::milliseconds> | toStdSysMilliseconds() const | 
| (since 6.4)std::chrono::sys_seconds | toStdSysSeconds() const | 
| (自 6.4)bool | isAlias() const | 
| (自 6.4)bool | isRowVisible(int row) const | 
| (自 6.4)bool | isRowVisible(QWidget *widget) const | 
| (自 6.4)bool | isRowVisible(QLayout *layout) const | 
| (自 6.4)void | setRowVisible(int row, bool on) | 
| (自 6.4)void | setRowVisible(QWidget *widget, bool on) | 
| (自 6.4)void | setRowVisible(QLayout *layout, bool on) | 
类 QFuture
| (since 6.4)QFuture<U> | unwrap() | 
类 QHash
| (since 6.4)auto | asKeyValueRange() & | 
| (since 6.4)auto | asKeyValueRange() const& | 
| (since 6.4)auto | asKeyValueRange() && | 
| (since 6.4)auto | asKeyValueRange() const&& | 
类 QImage
| (since 6.4)QImage | colorTransformed(const QColorTransform &transform) const& | 
| (since 6.4)QImage | colorTransformed(const QColorTransform &transform) && | 
| (since 6.4)jfieldID | findField(jclass clazz, const char *fieldName) | 
| (since 6.4)jmethodID | findMethod(jclass clazz, const char *methodName) | 
| (since 6.4)jfieldID | findStaticField(jclass clazz, const char *fieldName) | 
| (since 6.4)jmethodID | findStaticMethod(jclass clazz, const char *methodName) | 
| (since 6.4)auto | callMethod(const char *methodName, const char *signature, Args &&... args) const | 
| (since 6.4)auto | callMethod(const char *methodName, Args &&... args) const | 
| (since 6.4)QJniObject | callObjectMethod(const char *methodName, Args &&... args) const | 
| (since 6.4)auto | callStaticMethod(const char *className, const char *methodName, const char *signature, Args &&... args) | 
| (since 6.4)auto | callStaticMethod(jclass clazz, jmethodID methodId, Args &&... args) | 
| (since 6.4)auto | callStaticMethod(const char *className, const char *methodName, Args &&... args) | 
| (since 6.4)auto | callStaticMethod(jclass clazz, const char *methodName, Args &&... args) | 
| (since 6.4)QJniObject | callStaticObjectMethod(const char *className, const char *methodName, Args &&... args) | 
| (since 6.4)QJniObject | callStaticObjectMethod(jclass clazz, const char *methodName, Args &&... args) | 
| (since 6.4)QJniObject | construct(Args &&... args) | 
| (自 6.4 版起)const char * | constBegin() const | 
| (自 6.4 版起)const char * | constData() const | 
| (自 6.4 版起)const char * | constEnd() const | 
| (自 6.4 版起)qsizetype | count(QStringView str, Qt::CaseSensitivity cs) const | 
| (自 6.4 版起)qsizetype | count(QLatin1StringView l1, Qt::CaseSensitivity cs) const | 
| (自 6.4 版起)qsizetype | count(QChar ch, Qt::CaseSensitivity cs) const | 
| (自 6.4)bool | empty() const | 
| (自 6.4 版起)QLatin1Char | first() const | 
| (自 6.4 版起)QLatin1Char | last() const | 
| (自 6.4 版起)qsizetype | length() const | 
| (自 6.4 版起)double | toDouble(bool *ok) const | 
| (自 6.4 版起)float | toFloat(bool *ok) const | 
| (自 6.4 版起)int | toInt(bool *ok, int base) const | 
| (自 6.4 版起)long | toLong(bool *ok, int base) const | 
| (自 6.4 版起)qlonglong | toLongLong(bool *ok, int base) const | 
| (自 6.4 版起)short | toShort(bool *ok, int base) const | 
| (自 6.4 版起)uint | toUInt(bool *ok, int base) const | 
| (自 6.4 版起)ulong | toULong(bool *ok, int base) const | 
| (自 6.4 版起)qulonglong | toULongLong(bool *ok, int base) const | 
| (自 6.4 版起)ushort | toUShort(bool *ok, int base) const | 
类 QLine
| (自 6.4 版起)QLineF | toLineF() const | 
| (自 6.4)void | setTextAlignment(Qt::Alignment alignment) | 
类 QMap
| (since 6.4)auto | asKeyValueRange() & | 
| (since 6.4)auto | asKeyValueRange() const & | 
| (since 6.4)auto | asKeyValueRange() && | 
| (since 6.4)auto | asKeyValueRange() const && | 
类 QMargins
| (自 6.4 版起)QMarginsF | toMarginsF() const | 
| (自 6.4)bool | noLocal() const | 
| (自 6.4)void | setNoLocal(bool noloc) | 
| (since 6.4)auto | asKeyValueRange() & | 
| (since 6.4)auto | asKeyValueRange() const & | 
| (since 6.4)auto | asKeyValueRange() && | 
| (since 6.4)auto | asKeyValueRange() const && | 
| (since 6.4)auto | asKeyValueRange() & | 
| (since 6.4)auto | asKeyValueRange() const & | 
| (since 6.4)auto | asKeyValueRange() && | 
| (since 6.4)auto | asKeyValueRange() const && | 
| (自 6.4)bool | isLocked() const | 
| (自6.4开始)QMutexLocker<Mutex> & | operator=(QMutexLocker<Mutex> &&other) | 
| (自 6.4)void | swap(QMutexLocker<Mutex> &other) | 
| (自 6.4)bool | loadBackendByFeatures(QNetworkInformation::Features features) | 
| (自 6.4)bool | loadBackendByName(QStringView backend) | 
类 QObject
| (自 6.4)bool | isQuickItemType() const | 
| (自 6.4)void | setObjectName(QAnyStringView name) | 
类 QPoint
| (自6.4开始)QPointF | toPointF() const | 
类 QPolygon
| (自6.4开始)QPolygonF | toPolygonF() const | 
| (自 6.4)void | objectCreationFailed(const QUrl &url) | 
| (自6.4开始)QQuickRenderTarget | fromD3D11Texture(void *texture, uint format, const QSize &pixelSize, int sampleCount) | 
| (自6.4开始)QQuickRenderTarget | fromMetalTexture(MTLTexture *texture, uint format, const QSize &pixelSize, int sampleCount) | 
| (自6.4开始)QQuickRenderTarget | fromOpenGLTexture(uint textureId, uint format, const QSize &pixelSize, int sampleCount) | 
| (自6.4开始)QQuickRenderTarget | fromPaintDevice(QPaintDevice *device) | 
| (自6.4开始)QQuickRenderTarget | fromVulkanImage(VkImage image, VkImageLayout layout, VkFormat format, const QSize &pixelSize, int sampleCount) | 
| (自 6.4)bool | mirrorVertically() const | 
| (自 6.4)void | setMirrorVertically(bool enable) | 
类 QRect
| (自6.4开始)QRectF | toRectF() const | 
| (自 6.4 版起)int | combinedImageSamplerCount(int binding) const | 
类 QSize
| (自6.4开始)QSizeF | toSizeF() const | 
| (自 6.4 版起)qsizetype | count(QLatin1StringView l1, Qt::CaseSensitivity cs) const | 
| (自 6.4 版起)int | localeAwareCompare(QStringView other) const | 
| (自 6.4)void | setTextAlignment(Qt::Alignment alignment) | 
| (自 6.4)void | pendingConnectionAvailable() | 
| (自 6.4)void | insertMarkdown(const QString &markdown, QTextDocument::MarkdownFeatures features) | 
| (自 6.4)QTextDocumentFragment | fromMarkdown(const QString &markdown, QTextDocument::MarkdownFeatures features) | 
| (自 6.4)QString | toMarkdown(QTextDocument::MarkdownFeatures features) const | 
| (自 6.4)QString | toRawText() const | 
| (自 6.4)QTextStream & | operator>>(char16_t &c) | 
| (自 6.4)bool | setEngine(const QString &engine, const QVariantMap ¶ms) | 
| (自 6.4)QTimeZone | fromStdTimeZonePtr(const int *timeZone) | 
| (自 6.4)void | setTextAlignment(int column, Qt::Alignment alignment) | 
| (自 6.4)size_t | qHash(QMetaType type, size_t seed) | 
| (自 6.4)void | resize(qsizetype size, const T &v) | 
| (自 6.4)QVersionNumber | fromString(QAnyStringView string, qsizetype *suffixIndex) | 
类 QVoice
| (自 6.4)QDataStream & | operator<<(QDataStream &stream, const QVoice &voice) | 
| (自 6.4)QDebug | operator<<(QDebug debug, const QVoice &voice) | 
| (自 6.4)QDataStream & | operator>>(QDataStream &stream, QVoice &voice) | 
| (自 6.4)void | swap(QVoice &other) | 
| (自 6.4)void | fileSystemAccessRequested(QWebEngineFileSystemAccessRequest request) | 
| (自 6.4)QWebSocketHandshakeOptions | handshakeOptions() const | 
| (自 6.4)void | open(const QUrl &url, const QWebSocketHandshakeOptions &options) | 
| (自 6.4)void | open(const QNetworkRequest &request, const QWebSocketHandshakeOptions &options) | 
| (自 6.4)QString | subprotocol() const | 
| (自 6.4)void | setSupportedSubprotocols(const QStringList &protocols) | 
| (自 6.4)QStringList | supportedSubprotocols() const | 
命名空间中的新函数
| (自 6.4)QLatin1StringView | operator""_L1(const char *str, size_t size) | 
| (自 6.4 版起)QLatin1Char | operator""_L1(char ch) | 
| (自 6.4)QByteArray | operator""_ba(const char *str, size_t size) | 
| (自 6.4)QString | operator""_s(const char16_t *str, size_t size) | 
| (自 6.4)bool | qIsPolishScheduled(const QQuickWindow *窗口) | 
| (自 6.4)bool | qWaitForPolish(const QQuickWindow *窗口, int 超时) | 
| (自 6.4)bool | qWaitForPolish(const QQuickItem *项目, int 超时) | 
新宏
| (自6.4版起) | QCOMPARE_EQ(计算值, 基线值) | 
| (自6.4版起) | QCOMPARE_GE(计算值, 基线值) | 
| (自6.4版起) | QCOMPARE_GT(计算值, 基线值) | 
| (自6.4版起) | QCOMPARE_LE(计算值, 基线值) | 
| (自6.4版起) | QCOMPARE_LT(计算值, 基线值) | 
| (自6.4版起) | QCOMPARE_NE(计算值, 基线值) | 
| (自6.4版起) | QTRY_COMPARE_EQ(计算值, 基线值) | 
| (自6.4版起) | QTRY_COMPARE_EQ_WITH_TIMEOUT(计算值, 基线值, 超时) | 
| (自6.4版起) | QTRY_COMPARE_GE(计算值, 基线值) | 
| (自6.4版起) | QTRY_COMPARE_GE_WITH_TIMEOUT(计算值, 基线值, 超时) | 
| (自6.4版起) | QTRY_COMPARE_GT(计算值, 基线值) | 
| (自6.4版起) | QTRY_COMPARE_GT_WITH_TIMEOUT(计算值, 基线值, 超时) | 
| (自6.4版起) | QTRY_COMPARE_LE(计算值, 基线值) | 
| (自6.4版起) | QTRY_COMPARE_LE_WITH_TIMEOUT(计算值, 基线值, 超时) | 
| (自6.4版起) | QTRY_COMPARE_LT(计算值, 基线值) | 
| (自6.4版起) | QTRY_COMPARE_LT_WITH_TIMEOUT(计算值, 基线值, 超时) | 
| (自6.4版起) | QTRY_COMPARE_NE(计算值, 基线值) | 
| (自6.4版起) | QTRY_COMPARE_NE_WITH_TIMEOUT(计算值, 基线值, 超时) | 
| (自6.4版起) | Q_CONSTINIT | 
新枚举类型
| (自6.4版起)enum | PolygonMode { Fill, Line } | 
新枚举值
新属性
| 
 | 
新变量
| (自6.4版起) | polygonMode | 
| (自6.4版起) | MacOSVentura | 
| (自6.4版起) | Windows11_21H2 | 
| (自6.4版起) | Windows11_22H2 | 
新QML类型
新QML属性
QML类型 Model
| (自6.4版起) | castsReflections : bool | 
QML 类型 ReflectionProbe
| (自6.4版起) | debugView : bool | 
QML 类型 SceneEnvironment
| (自6.4版起) | skyBoxCubeMap : QtQuick3D::CubeMapTexture | 
| (自6.4版起) | skyboxBlurAmount : float | 
| (自6.4版起) | specularAAEnabled : bool | 
QML 类型 SpriteParticle3D
| (自6.4版起) | castsReflections : bool | 
QML 类型 TableView
| (自6.4版起) | animate : bool | 
| (自6.4版起) | keyNavigationEnabled : bool | 
| (自6.4版起) | pointerNavigationEnabled : bool | 
| (自6.4版起) | selectionBehavior : 枚举类型 | 
QML 类型 View3D
| (自6.4版起) | renderFormat : 枚举类型 | 
QML 类型 WaylandSurface
| (自6.4版起) | isOpaque : bool | 
QML 类型 WebSocket
| (自6.4版起) | negotiatedSubprotocol : QString | 
| (自6.4版起) | requestedSubprotocols : QStringList | 
QML 类型 WebSocketServer
| (自6.4版起) | supportedSubprotocols : QStringList | 
新增 QML 方法
QML 类型 TableView
| (自 6.4 版本起)point | cellAtIndex(QModelIndex modelIndex) | 
| (自 6.4 版起)int | columnAtIndex(QModelIndex modelIndex) | 
| (自 6.4 版本起)QModelIndex | modelIndex(point cell) | 
| (自 6.4 版起)int | rowAtIndex(QModelIndex modelIndex) | 
QML 类型 TreeView
| (自6.4版起) | collapseRecursively(row) | 
| (自6.4版起) | expandRecursively(row, depth) | 
| (自6.4版起) | expandToIndex(QModelIndex index) | 
© 2024 Qt 公司。此处包含的文档贡献为各自所有者的版权。提供的文档受 GNU 自由文档许可协议版本 1.3 的条款许可,由自由软件基金会发布。Qt 及相关标志是芬兰和/或其他国家的 Qt 公司的商标。所有其他商标均为各自所有者的财产。