r24707 by jghali - #16635: Replace hb_subset, removed in harfbuzz 3.0, by hb_subset_or_fail

scribus-commit scribus-commit at lists.scribus.net
Sun Sep 19 11:59:50 UTC 2021


Author: jghali
Date: Sun Sep 19 11:59:50 2021
New Revision: 24707

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=24707
Log:
#16635: Replace hb_subset, removed in harfbuzz 3.0, by hb_subset_or_fail

Modified:
    trunk/Scribus/scribus/fonts/sfnt.cpp

Modified: trunk/Scribus/scribus/fonts/sfnt.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=24707&path=/trunk/Scribus/scribus/fonts/sfnt.cpp
==============================================================================
--- trunk/Scribus/scribus/fonts/sfnt.cpp	(original)
+++ trunk/Scribus/scribus/fonts/sfnt.cpp	Sun Sep 19 11:59:50 2021
@@ -1271,9 +1271,15 @@
 #endif
 #endif
 
+#if HB_VERSION_ATLEAST(2, 9, 0)
+		QScopedPointer<hb_face_t, HbFaceDeleter> hbSubsetFace(hb_subset_or_fail(hbFullFace.get(), hbSubsetInput.get()));
+		if (hbSubsetFace.isNull())
+			return QByteArray();
+#else
 		QScopedPointer<hb_face_t, HbFaceDeleter> hbSubsetFace(hb_subset(hbFullFace.get(), hbSubsetInput.get()));
 		if (hbSubsetFace.isNull())
 			return QByteArray();
+#endif
 
 		QScopedPointer<hb_blob_t, HbBlobDeleter> hbSubsetBlob(hb_face_reference_blob(hbSubsetFace.get()));
 		if (hbSubsetBlob.isNull())




More information about the scribus-commit mailing list