New Classes and Functions in Qt 5.9

This page contains a comprehensive list of all new classes and functions introduced in Qt 5.9. Links to new APIs in previous Qt 5 releases are found at the bottom of this page.

New Classes

New Member Functions

Class QAbstractFileEngine:

virtual id() const

Class QDir:

isEmpty(QDir::Filters filters) const

Class QStorageInfo:

subvolume() const

Class QTemporaryDir:

filePath(const QString &fileName) const

Class QObject:

startTimer(std::chrono::milliseconds time, Qt::TimerType timerType)

Class QDataStream:

operator<<(qfloat16 f)
operator<<(std::nullptr_t ptr)
operator>>(qfloat16 &f)
operator>>(std::nullptr_t &ptr)

Class QThreadPool:

tryTake(QRunnable *runnable)

Class QByteArray:

toHex(char separator) const

Class QStringRef:

constBegin() const
constEnd() const
isRightToLeft() const

Class QTimeZone:

fromCFTimeZone(CFTimeZoneRef timeZone)
fromNSTimeZone(const NSTimeZone *timeZone)
toCFTimeZone() const
toNSTimeZone() const

Class QVarLengthArray:

append(T &&t)
push_back(T &&t)

Class QHelpSearchEngine:

search(const QString &searchInput)
searchInput() const
searchResultCount() const
searchResults(int start, int end) const

Class QHelpSearchQueryWidget:

searchInput() const
setSearchInput(const QString &searchInput)

Class QGeoCodeReply:


Class QIconEngine:

scaledPixmap(const QSize &size, QIcon::Mode mode, QIcon::State state, qreal scale)

Class QImage:

reinterpretAsFormat(QImage::Format format)

Class TouchPoint:


Class QOffscreenSurface:

nativeHandle() const
setNativeHandle(void *handle)

Class QWindow:

parent(QWindow::AncestorMode mode) const
setFlag(Qt::WindowType flag, bool on)

Class QOpenGLShaderProgram:

addCacheableShaderFromSourceCode(QOpenGLShader::ShaderType type, const QByteArray &source)
addCacheableShaderFromSourceCode(QOpenGLShader::ShaderType type, const QString &source)
addCacheableShaderFromSourceCode(QOpenGLShader::ShaderType type, const char *source)
addCacheableShaderFromSourceFile(QOpenGLShader::ShaderType type, const QString &fileName)

Class QOpenGLTexture:

setCompressedData(int mipLevel, int layer, int layerCount, QOpenGLTexture::CubeMapFace cubeFace, int dataSize, const void *data, const QOpenGLPixelTransferOptions *const options)
setData(int mipLevel, int layer, int layerCount, QOpenGLTexture::CubeMapFace cubeFace, QOpenGLTexture::PixelFormat sourceFormat, QOpenGLTexture::PixelType sourceType, const void *data, const QOpenGLPixelTransferOptions *const options)

Class QTextDocument:

toRawText() const

Class QPlatformScreen:

virtual currentMode() const
virtual manufacturer() const
virtual model() const
virtual modes() const
virtual preferredMode() const
virtual serialNumber() const

Class QPlatformTheme:

virtual standardButtonShortcut(int button) const

Class QGeoRouteReply:


Class QGeoCameraCapabilities:

maximumFieldOfView() const
minimumFieldOfView() const
overzoomEnabled() const
setMaximumFieldOfView(double maximumFieldOfView)
setMinimumFieldOfView(double minimumFieldOfView)
setOverzoomEnabled(bool overzoomEnabled)

Class QPlaceReply:


Class QNetworkAccessManager:

addStrictTransportSecurityHosts(const QVector<QHstsPolicy> &knownHosts)
clearConnectionCache()
isStrictTransportSecurityEnabled() const
redirectPolicy() const
setRedirectPolicy(QNetworkRequest::RedirectPolicy policy)
setStrictTransportSecurityEnabled(bool enabled)
strictTransportSecurityHosts() const

Class QNetworkReply:


Class QNetworkConfiguration:

connectTimeout() const
setConnectTimeout(int timeout)

Class QHostInfo:

lookupHost(const QString &name, Functor functor)
lookupHost(const QString &name, const QObject *context, Functor functor)
lookupHost(const QString &name, const QObject *receiver, PointerToMemberFunction function)

Class QNearFieldTarget:

disconnect()
keepConnection() const
maxCommandLength() const
setKeepConnection(bool isPersistent)

Class QWindowsWindowFunctions:


Class QGeoCircle:

extendCircle(const QGeoCoordinate &coordinate)

Class QGeoRectangle:

extendRectangle(const QGeoCoordinate &coordinate)

Class QGeoShape:


Class QQmlEngine:

offlineStorageDatabaseFilePath(const QString &databaseName) const

Class QQmlError:

messageType() const
setMessageType(QtMsgType messageType)

Class QQuickWindow:


Class QSGTexture:

anisotropyLevel() const
setAnisotropyLevel(QSGTexture::AnisotropyLevel level)

Class QCanBus:

availableDevices(const QString &plugin, QString *errorMessage) const

Class QCanBusFrame:

hasBitrateSwitch() const
hasErrorStateIndicator() const
setBitrateSwitch(bool bitrateSwitch)
setErrorStateIndicator(bool errorStateIndicator)

Class QWebSocketServer:

handleConnection(QTcpSocket *socket) const

Class QSizePolicy:

transposed() const

Class QWidget:

setWindowFlag(Qt::WindowType flag, bool on)

Class QSystemTrayIcon:

showMessage(const QString &title, const QString &message, const QIcon &icon, int millisecondsTimeoutHint)

Class QUndoCommand:

isObsolete() const
setObsolete(bool obsolete)

Class QSplitter:

replaceWidget(int index, QWidget *widget)

Class QFileDialog:


Class QRenderCaptureReply:

saveImage(const QString &fileName) const

Class QQuickStyle:


New Functions in Namespaces

addRow(const char *format, ...)
qmlDebug(const QObject *object)
qmlWarning(const QObject *object)

New Global Functions

operator!=(QHostAddress::SpecialAddress lhs, const QHostAddress &rhs)
qChecksum(const char *data, uint len, Qt::ChecksumType standard)
qMakeStaticByteArrayMatcher(const char (&)[N] pattern)
qmlRegisterModule(const char *uri, int versionMajor, int versionMinor)

New Enum Types

enum RedirectPolicy { ManualRedirectPolicy, NoLessSafeRedirectPolicy, SameOriginRedirectPolicy, UserVerifiedRedirectPolicy }
enum AnisotropyLevel { AnisotropyNone, Anisotropy2x, Anisotropy4x, Anisotropy8x, Anisotropy16x }
enum ChecksumType { ChecksumIso3309, ChecksumItuV41 }

New Typedefs

New Properties

New Variables

New QML Types

New QML Properties

New QML Signals

New QML Methods

Additions to Other Qt 5 Releases