Qt 6.5 中的新类和函数

This page contains a comprehensive list of all new classes and functions introduced in Qt 6.5.

新名称空间

namespace QtCanBus
namespace QtProtobuf

新类

A
QAbstractGrpcChannel
QAbstractGrpcClient
QAbstractGrpcCredentials
QAbstractProtobufSerializer
QAccessibleSelectionInterface
B
QBluetoothPermission
C
QCalendarPermission
QCameraPermission
QCanDbcFileParser
QCanFrameProcessor
QCanMessageDescription
QCanSignalDescription
QCanUniqueIdDescription
QContactsPermission
G
QGrpcCallCredentials
QGrpcCallReply
QGrpcChannel
QGrpcChannelCredentials
QGrpcCredentials
QGrpcHttp2Channel
QGrpcInsecureCallCredentials
QGrpcInsecureChannelCredentials
QGrpcOperation
QGrpcSslCredentials
QGrpcStatus
QGrpcStream
QGrpcUserPasswordCredentials
H
QHttp1Configuration
L
QLatin1StringMatcher
QLocationPermission
M
MultiplexValueRange ( QCanSignalDescription )
QMicrophonePermission
P
ParseResult ( QDomDocument )
ParseResult ( QCanFrameProcessor )
QPermission
QProtobufMessage
QProtobufMessageDeleter
QProtobufSerializer
Q
QQuickAttachedPropertyPropagator
S
QScreenCapture
U
QUtiMimeConverter
W
QWaylandApplication ( QNativeInterface )

新成员函数

QAbstractOAuth2 :

void setSslConfiguration (const QSslConfiguration & configuration )
QSslConfiguration sslConfiguration () const
void sslConfigurationChanged (const QSslConfiguration & configuration )

QAccessibleInterface :

QAccessibleSelectionInterface * selectionInterface ()

QAnyStringView :

void chop (qsizetype n )
QAnyStringView chopped (qsizetype n ) const
QAnyStringView first (qsizetype n ) const
QAnyStringView last (qsizetype n ) const
QAnyStringView sliced (qsizetype pos ) const
QAnyStringView sliced (qsizetype pos , qsizetype n ) const
void truncate (qsizetype n )

QBasicTimer :

void start (std::chrono::milliseconds duration , QObject * object )
void start (std::chrono::milliseconds duration , Qt::TimerType timerType , QObject * obj )

QByteArray :

QByteArray::iterator erase (QByteArray::const_iterator it )
QByteArray fromEcmaUint8Array (emscripten::val uint8array )
QByteArray & removeAt (qsizetype pos )
QByteArray & removeFirst ()
QByteArray & removeLast ()
emscripten::val toEcmaUint8Array ()

QCoreApplication :

Qt::PermissionStatus checkPermission (const QPermission & permission )
void requestPermission (const QPermission & permission , const QObject * context , Functor functor )

QCryptographicHash :

QCryptographicHash::Algorithm algorithm () const
QCryptographicHash & operator= (QCryptographicHash && other )
bool supportsAlgorithm (QCryptographicHash::Algorithm method )
void swap (QCryptographicHash & other )

QDate :

QDateTime endOfDay () const
QDateTime startOfDay () const

QDateTime :

QDateTime currentDateTime (const QTimeZone & zone )
QDateTime fromMSecsSinceEpoch (qint64 msecs )
QDateTime fromSecsSinceEpoch (qint64 secs )
QTimeZone timeRepresentation () const

QDebug :

QDebug & operator<< (const std::basic_string<Char, Args...> & s )
QDebug & operator<< (std::basic_string_view<Char, Args...> s )

QDomDocument :

QDomDocument::ParseResult setContent (const QByteArray & data , QDomDocument::ParseOptions options )
QDomDocument::ParseResult setContent (QAnyStringView data , QDomDocument::ParseOptions options )
QDomDocument::ParseResult setContent (QIODevice * device , QDomDocument::ParseOptions options )
QDomDocument::ParseResult setContent (QXmlStreamReader * reader , QDomDocument::ParseOptions options )

QGlyphRun :

void setSourceString (const QString & sourceString )
void setStringIndexes (const QList<qsizetype> & stringIndexes )
QString sourceString () const
QList<qsizetype> stringIndexes () const

QGuiApplication :

void setBadgeNumber (qint64 number )

QHttp1Configuration :

bool operator!= (const QHttp1Configuration & lhs , const QHttp1Configuration & rhs )
bool operator== (const QHttp1Configuration & lhs , const QHttp1Configuration & rhs )
size_t qHash (const QHttp1Configuration & key , size_t seed )

QHttpServerRequest :

QHostAddress localAddress () const
quint16 localPort () const
quint16 remotePort () const

QHttpServerResponder :

void sendResponse (const QHttpServerResponse & response )

QLatin1StringView :

int compare (QUtf8StringView str , Qt::CaseSensitivity cs ) const

QLibraryInfo :

bool isSharedBuild ()

QLowEnergyController :

void readRssi ()
void rssiRead (qint16 rssi )

QMessageLogger :

void fatal (const QLoggingCategory & cat , const char * msg , ...) const
void fatal (QMessageLogger::CategoryFunction catFunc , const char * msg , ...) const
QDebug fatal () const
QDebug fatal (const QLoggingCategory & cat ) const
QDebug fatal (QMessageLogger::CategoryFunction catFunc ) const

QMetaMethod :

bool invoke (QObject * obj , Qt::ConnectionType type , QMetaMethodReturnArgument ret , Args &&... arguments ) const
bool invoke (QObject * obj , Qt::ConnectionType type , Args &&... arguments ) const
bool invoke (QObject * obj , QMetaMethodReturnArgument ret , Args &&... arguments ) const
bool invoke (QObject * obj , Args &&... arguments ) const
bool invokeOnGadget (void * gadget , QMetaMethodReturnArgument ret , Args &&... arguments ) const
bool invokeOnGadget (void * gadget , Args &&... arguments ) const

QMetaObject :

bool invokeMethod (QObject * obj , const char * member , Qt::ConnectionType type , QMetaMethodReturnArgument r , Args &&... args )
bool invokeMethod (QObject * obj , const char * member , Qt::ConnectionType type , Args &&... args )
bool invokeMethod (QObject * obj , const char * member , QMetaMethodReturnArgument r , Args &&... args )
bool invokeMethod (QObject * obj , const char * member , Args &&... args )
QObject * newInstance (Args &&... arguments ) const

QMetaType :

bool isCopyConstructible () const
bool isDefaultConstructible () const
bool isDestructible () const
bool isMoveConstructible () const
QDebug operator<< (QDebug d , QMetaType m )
int qRegisterMetaType (QMetaType meta )
void registerType () const

QEGLContext :

virtual void invalidateContext () = 0

QNetworkRequest :

QHttp1Configuration http1Configuration () const
void setHttp1Configuration (const QHttp1Configuration & configuration )

QOpenGLBuffer :

QOpenGLBuffer & operator= (QOpenGLBuffer && other )
void swap (QOpenGLBuffer & other )

QOpenGLWidget :

QOpenGLWidget::TargetBuffer currentTargetBuffer () const
GLuint defaultFramebufferObject (QOpenGLWidget::TargetBuffer targetBuffer ) const
QImage grabFramebuffer (QOpenGLWidget::TargetBuffer targetBuffer )
void makeCurrent (QOpenGLWidget::TargetBuffer targetBuffer )

QQmlApplicationEngine :

void loadFromModule (QAnyStringView uri , QAnyStringView typeName )

QQmlComponent :

bool isBound () const
void loadFromModule (QAnyStringView uri , QAnyStringView typeName , QQmlComponent::CompilationMode mode )

QQmlEngine :

void offlineStoragePathChanged ()
T singletonInstance (QAnyStringView uri , QAnyStringView typeName )

QQuickGraphicsConfiguration :

bool isAutomaticPipelineCacheEnabled () const
void setAutomaticPipelineCache (bool enable )
void setDebugLayer (bool enable )
void setDebugMarkers (bool enable )
void setPipelineCacheLoadFile (const QString & filename )
void setPipelineCacheSaveFile (const QString & filename )
void setPreferSoftwareDevice (bool enable )

QRectF :

QRectF fromDOMRect (emscripten::val domRect )
emscripten::val toDOMRect () const

QRegularExpression :

QRegularExpressionMatchIterator globalMatchView (QStringView subjectView , qsizetype offset , QRegularExpression::MatchType matchType , QRegularExpression::MatchOptions matchOptions ) const
QRegularExpressionMatch matchView (QStringView subjectView , qsizetype offset , QRegularExpression::MatchType matchType , QRegularExpression::MatchOptions matchOptions ) const

QSGRenderNode :

const QMatrix4x4 * projectionMatrix () const

QString :

QString & append (QUtf8StringView str )
QString::iterator erase (QString::const_iterator it )
QString & insert (qsizetype position , QUtf8StringView str )
QString & operator+= (QUtf8StringView str )
QString & prepend (QUtf8StringView str )
QString & removeAt (qsizetype pos )
QString & removeFirst ()
QString & removeLast ()

QStringView :

int compare (QUtf8StringView str , Qt::CaseSensitivity cs ) const

QSvgGenerator :

QSvgGenerator::SvgVersion svgVersion () const

QTextLayout :

QList<QGlyphRun> glyphRuns (int from , int length , QTextLayout::GlyphRunRetrievalFlags retrievalFlags ) const

QTextLine :

QList<QGlyphRun> glyphRuns (int from , int length , QTextLayout::GlyphRunRetrievalFlags retrievalFlags ) const

QTimeZone :

QTimeZone asBackendZone () const
int fixedSecondsAheadOfUtc () const
QTimeZone fromDurationAheadOfUtc (std::chrono::seconds offset )
QTimeZone fromSecondsAheadOfUtc (int offset )
bool isUtcOrFixedOffset (Qt::TimeSpec spec )
bool isUtcOrFixedOffset () const
Qt::TimeSpec timeSpec () const

QTransform :

QTransform & rotate (qreal a , Qt::Axis axis , qreal distanceToPlane )
QTransform & rotateRadians (qreal a , Qt::Axis axis , qreal distanceToPlane )

QUtf8StringView :

int compare (QUtf8StringView str , Qt::CaseSensitivity cs ) const
int compare (QStringView str , Qt::CaseSensitivity cs ) const
int compare (QLatin1StringView str , Qt::CaseSensitivity cs ) const

QVulkanInstance :

void clearDebugOutputFilters ()
void installDebugOutputFilter (QVulkanInstance::DebugUtilsFilter filter )

QWebEngineProfile :

bool isPushServiceEnabled () const
void setPushServiceEnabled (bool enable )

QWebEngineUrlRequestInfo :

QHash<QByteArray, QByteArray> httpHeaders () const

QWebSocket :

void errorOccurred (QAbstractSocket::SocketError error )

名称空间中的新函数

bool currentTestResolved ()
void qRegisterTestCase (const QString & name , QTest::TestEntryFunction entryFunction )
char * toString (const QKeySequence & ks )

新宏

Q_DECLARE_EXPORTED_LOGGING_CATEGORY ( name , EXPORT_MACRO )
Q_PROCESSOR_LOONGARCH
Q_PROCESSOR_LOONGARCH_32
Q_PROCESSOR_LOONGARCH_64
void Q_UNREACHABLE_RETURN (...)
qCFatal ( category , const char * message , ...)
qCFatal ( category )

新枚举类型

enum class ParseOption { Default, UseNamespaceProcessing, PreserveSpacingOnlyNodes }
enum TargetBuffer { LeftBuffer, RightBuffer }
enum class SvgVersion { SvgTiny12, Svg11 }
enum GlyphRunRetrievalFlag { RetrieveGlyphIndexes, RetrieveGlyphPositions, RetrieveStringIndexes, RetrieveString, DefaultRetrievalFlags, RetrieveAll }
enum Initialization { LocalTime, UTC }
enum DebugMessageSeverityFlag { VerboseSeverity, InfoSeverity, WarningSeverity, ErrorSeverity }
enum DebugMessageTypeFlag { GeneralMessage, ValidationMessage, PerformanceMessage }
enum class PermissionStatus { Undetermined, Granted, Denied }

新类型别名

DebugUtilsFilter

新特性

新的变量

dstAlpha
separateBlendFactors
srcAlpha
Android12
Android12L
Android13
Windows10_22H2

新 QML 类型

E
ExtendedSceneEnvironment
F
Fog
G
geoSatelliteInfo
I
InfiniteGrid
S
SatelliteSource
ScreenCapture
设置

新 QML 特性

QML 类型 Camera :

levelOfDetailBias : float

QML 类型 CaptureSession :

screenCapture : ScreenCapture

QML 类型 DebugSettings :

materialOverride : enumeration
wireframeEnabled : bool

QML 类型 DynamicRigidBody :

kinematicEulerRotation : vector4d
kinematicPivot : vector3d
kinematicPosition : vector3d
kinematicRotation : vector3d

QML 类型 Item :

layer.live : bool

QML 类型 MediaPlayer :

playing : bool

QML 类型 Model :

levelOfDetailBias : real

QML 类型 PickResult :

instanceIndex : int

QML 类型 PrincipledMaterial :

vertexColorsEnabled : bool

QML 类型 ReflectionProbe :

texture : CubeMapTexture

QML 类型 RenderStats :

drawCallCount : quint64
drawVertexCount : quint64
effectGenerationTime : qint64
extendedDataCollectionEnabled : bool
graphicsAPIName : string
imageDataSize : quint64
materialGenerationTime : qint64
meshDataSize : quint64
pipelineCount : int
pipelineCreationTime : qint64
renderPassCount : int
vmemAllocCount : quint32
vmemUsedBytes : quint64

QML 类型 SceneEnvironment :

aoEnabled : float
debugSettings : QtQuick3D::DebugSettings
fog : QtQuick3D::Fog
scissorRect : rect

QML 类型 SpecularGlossyMaterial :

vertexColorsEnabled : bool

QML 类型 TableView :

editTriggers : enumeration
resizableColumns : bool
resizableRows : bool

QML 类型 TapHandler :

exclusiveSignals : enumeration

QML 类型 TreeViewDelegate :

editing : bool

新 QML 信号

frameDone (float timestep )
layoutChanged ()

新 QML 方法

QML 类型 Locale :

string toString (int i )
string toString (double f , char format , int precision )
string toString (Date date , string format )
string toString (Date date , FormatType format )

QML 类型 TableView :

closeEditor ()
edit (QModelIndex modelIndex )
Item itemAtIndex (QModelIndex index )
positionViewAtIndex (QModelIndex index , PositionMode mode , point offset , rect subRect )

QML 类型 TestCase :

bool waitForPolish (object windowOrItem , int timeout )

版权所有  © 2014-2025 乐数软件    

工业和信息化部: 粤ICP备14079481号-1