Material: fix build failure with Qt6

setCodec() has been removed from QTextStream
This commit is contained in:
wmayer
2023-11-02 11:24:45 +01:00
committed by wwmayer
parent 54c4ee4b78
commit d99658b3da

View File

@@ -232,7 +232,9 @@ std::shared_ptr<Material> MaterialLibrary::saveMaterial(std::shared_ptr<Material
if (file.open(QIODevice::WriteOnly | QIODevice::Text)) {
QTextStream stream(&file);
#if QT_VERSION < QT_VERSION_CHECK(6,0,0)
stream.setCodec("UTF-8");
#endif
stream.setGenerateByteOrderMark(true);
// Write the contents