- a cache is specified for QNetworkAccessManager and
- PreferCache is specified using QNetworkRequest's method setAttribute called like
setAttribute(QNetworkRequest::CacheLoadControlAttribute, QNetworkRequest::PreferCache) and
- the network/internet connection is not present
then, the request will still fail when called from a RichText QML Text with
QML QQuickText: Network access is disabled.
However, if you modify the setAttribute call to use QNetworkRequest::AlwaysCache when the network isn't present, then it will work:
(networkAccessible() == QNetworkAccessManager::Accessible ?
I would like to suggest that this is a bug, because if you say you would PreferCache, you don't want it to fail if you have a valid cache entry, but the network isn't present.
For more code context, see this StackOverflow answer by jpnurmi