<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">Index: Scribus/scribus/plugins/import/pdf/importpdf.cpp
===================================================================
--- Scribus/scribus/plugins/import/pdf/importpdf.cpp	(revision 26663)
+++ Scribus/scribus/plugins/import/pdf/importpdf.cpp	(revision 26668)
@@ -462,11 +462,11 @@
 
 			if (dev-&gt;isOk())
 			{
-				OCGs* ocg = pdfDoc-&gt;getOptContentConfig();
+				POPPLER_CONST_25_02 OCGs* ocg = pdfDoc-&gt;getOptContentConfig();
 				if (ocg &amp;&amp; ocg-&gt;hasOCGs())
 				{
 					QStringList ocgNames;
-					Array *order = ocg-&gt;getOrderArray();
+					POPPLER_CONST_25_02 Array *order = ocg-&gt;getOrderArray();
 					if (order)
 					{
 						for (int i = 0; i &lt; order-&gt;getLength (); ++i)
Index: Scribus/scribus/plugins/import/pdf/importpdfconfig.h
===================================================================
--- Scribus/scribus/plugins/import/pdf/importpdfconfig.h	(revision 26663)
+++ Scribus/scribus/plugins/import/pdf/importpdfconfig.h	(revision 26668)
@@ -27,4 +27,10 @@
 #define POPPLER_CONST_083
 #endif
 
+#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(25, 2, 0)
+#define POPPLER_CONST_25_02 const
+#else
+#define POPPLER_CONST_25_02
 #endif
+
+#endif
Index: Scribus/scribus/plugins/import/pdf/slaoutput.cpp
===================================================================
--- Scribus/scribus/plugins/import/pdf/slaoutput.cpp	(revision 26663)
+++ Scribus/scribus/plugins/import/pdf/slaoutput.cpp	(revision 26668)
@@ -1685,7 +1685,7 @@
 
 	auto&amp; graphicState = m_graphicStack.top();
 	graphicState.strokeColor = getColor(state-&gt;getStrokeColorSpace(), state-&gt;getStrokeColor(), &amp;graphicState.strokeShade);
-	
+
 	QString output = convertPath(state-&gt;getPath());
 	if ((m_Elements-&gt;count() != 0) &amp;&amp; (output == m_coords))			// Path is the same as in last fill
 	{
@@ -2393,8 +2393,9 @@
 #endif
 	m_graphicStack.top().clipPath = savedClip;
 	m_inPattern--;
+	m_doc-&gt;m_Selection-&gt;clear();
+
 	gElements = m_groupStack.pop();
-	m_doc-&gt;m_Selection-&gt;clear();
 	if (gElements.Items.count() &gt; 0)
 	{
 		for (int dre = 0; dre &lt; gElements.Items.count(); ++dre)
@@ -2932,7 +2933,7 @@
 	{
 		if (dictRef-&gt;isNull())
 			return;
-		OCGs *contentConfig = m_catalog-&gt;getOptContentConfig();
+		POPPLER_CONST_25_02 OCGs *contentConfig = m_catalog-&gt;getOptContentConfig();
 		OptionalContentGroup *oc;
 		if (dictRef-&gt;isRef())
 		{
@@ -3084,7 +3085,11 @@
 #if POPPLER_ENCODED_VERSION &lt; POPPLER_VERSION_ENCODE(22, 4, 0)
 	int tmpBufLen = 0;
 #endif
+#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(25, 2, 0)
+	std::vector&lt;int&gt; codeToGID;
+#else
 	int *codeToGID = nullptr;
+#endif
 	const double *textMat = nullptr;
 	double m11, m12, m21, m22, fontSize;
 	SplashCoord mat[4] = { 1.0, 0.0, 0.0, 1.0 };
@@ -3244,10 +3249,20 @@
 			}
 			else
 			{
+#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(25, 2, 0)
+				codeToGID.clear();
+#else
 				codeToGID = nullptr;
+#endif
 				n = 0;
 			}
-#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(24, 11, 0)
+#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(25, 2, 0)
+			if (!(fontFile = m_fontEngine-&gt;loadTrueTypeFont(std::move(id), fontsrc, std::move(codeToGID), fontLoc-&gt;fontNum)))
+			{
+				error(errSyntaxError, -1, "Couldn't create a font for '{0:s}'", gfxFont-&gt;getName() ? gfxFont-&gt;getName()-&gt;c_str() : "(unnamed)");
+				goto err2;
+			}
+#elif POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(24, 11, 0)
 			if (!(fontFile = m_fontEngine-&gt;loadTrueTypeFont(std::move(id), fontsrc, codeToGID, n, fontLoc-&gt;fontNum)))
 			{
 				error(errSyntaxError, -1, "Couldn't create a font for '{0:s}'", gfxFont-&gt;getName() ? gfxFont-&gt;getName()-&gt;c_str() : "(unnamed)");
@@ -3278,6 +3293,18 @@
 #endif
 			break;
 		case fontCIDType0COT:
+#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(25, 2, 0)
+			if (((GfxCIDFont*) gfxFont)-&gt;getCIDToGIDLen() &gt; 0)
+			{
+				codeToGID = ((GfxCIDFont*) gfxFont)-&gt;getCIDToGID();
+				n = codeToGID.size();
+			}
+			else
+			{
+				codeToGID.clear();
+				n = 0;
+			}
+#else
 			if (((GfxCIDFont *) gfxFont)-&gt;getCIDToGID())
 			{
 				n = ((GfxCIDFont *) gfxFont)-&gt;getCIDToGIDLen();
@@ -3289,7 +3316,15 @@
 				codeToGID = nullptr;
 				n = 0;
 			}
-#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(24, 11, 0)
+#endif
+#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(25, 2, 0)
+			if (!(fontFile = m_fontEngine-&gt;loadOpenTypeCFFFont(std::move(id), fontsrc, std::move(codeToGID), fontLoc-&gt;fontNum)))
+			{
+				error(errSyntaxError, -1, "Couldn't create a font for '{0:s}'",
+					gfxFont-&gt;getName() ? gfxFont-&gt;getName()-&gt;c_str() : "(unnamed)");
+				goto err2;
+			}
+#elif POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(24, 11, 0)
 			if (!(fontFile = m_fontEngine-&gt;loadOpenTypeCFFFont(std::move(id), fontsrc, codeToGID, n, fontLoc-&gt;fontNum)))
 			{
 				error(errSyntaxError, -1, "Couldn't create a font for '{0:s}'",
@@ -3307,6 +3342,15 @@
 			break;
 		case fontCIDType2:
 		case fontCIDType2OT:
+#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(25, 2, 0)
+			codeToGID.clear();
+			n = 0;
+			if (((GfxCIDFont*) gfxFont)-&gt;getCIDToGIDLen() &gt; 0)
+			{
+				codeToGID = ((GfxCIDFont*) gfxFont)-&gt;getCIDToGID();
+				n = codeToGID.size();
+			}
+#else
 			codeToGID = nullptr;
 			n = 0;
 			if (((GfxCIDFont *) gfxFont)-&gt;getCIDToGID())
@@ -3318,6 +3362,7 @@
 					memcpy(codeToGID, ((GfxCIDFont *)gfxFont)-&gt;getCIDToGID(), n * sizeof(*codeToGID));
 				}
 			}
+#endif
 			else
 			{
 #if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(24, 11, 0)
@@ -3338,7 +3383,9 @@
 #endif
 				if (! ff)
 					goto err2;
-#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(22, 2, 0)
+#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(25, 2, 0)
+				codeToGID = ((GfxCIDFont*) gfxFont)-&gt;getCodeToGIDMap(ff.get());
+#elif POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(22, 2, 0)
 				codeToGID = ((GfxCIDFont*) gfxFont)-&gt;getCodeToGIDMap(ff.get(), &amp;n);
 				ff.reset();
 #else
@@ -3346,7 +3393,13 @@
 				delete ff;
 #endif
 			}
-#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(24, 11, 0)
+#if POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(25, 2, 0)
+			if (!(fontFile = m_fontEngine-&gt;loadTrueTypeFont(std::move(id), fontsrc, std::move(codeToGID), fontLoc-&gt;fontNum)))
+			{
+				error(errSyntaxError, -1, "Couldn't create a font for '{0:s}'", gfxFont-&gt;getName() ? gfxFont-&gt;getName()-&gt;c_str() : "(unnamed)");
+				goto err2;
+			}
+#elif POPPLER_ENCODED_VERSION &gt;= POPPLER_VERSION_ENCODE(24, 11, 0)
 			if (!(fontFile = m_fontEngine-&gt;loadTrueTypeFont(std::move(id), fontsrc, codeToGID, n, fontLoc-&gt;fontNum)))
 			{
 				error(errSyntaxError, -1, "Couldn't create a font for '{0:s}'", gfxFont-&gt;getName() ? gfxFont-&gt;getName()-&gt;c_str() : "(unnamed)");
</pre></body></html>