SHA256
1
0
forked from pool/scribus

16 Commits

Author SHA256 Message Date
a0443dc74b Accepting request 1283918 from KDE:Extra
Update to 1.6.4

OBS-URL: https://build.opensuse.org/request/show/1283918
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/scribus?expand=0&rev=91
2025-06-10 06:56:27 +00:00
Christophe Marin
59abf9ced5 1.6.4
OBS-URL: https://build.opensuse.org/package/show/KDE:Extra/scribus?expand=0&rev=103
2025-06-08 09:09:06 +00:00
f59b91dfb2 Accepting request 1247171 from KDE:Extra
- Add 0001-Fix-build-error-with-poppler-25.02.0.patch: Fix build
  with poppler 25.02.0.

OBS-URL: https://build.opensuse.org/request/show/1247171
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/scribus?expand=0&rev=90
2025-02-20 15:28:13 +00:00
Christophe Marin
3e0b125871 reapply
OBS-URL: https://build.opensuse.org/package/show/KDE:Extra/scribus?expand=0&rev=101
2025-02-19 16:19:01 +00:00
Christophe Marin
7a1bbf9d63 Bah... Revert, that did not work as intended....
OBS-URL: https://build.opensuse.org/package/show/KDE:Extra/scribus?expand=0&rev=100
2025-02-19 16:11:38 +00:00
Christophe Marin
374a6b23d6 - Add 3f0f902d6e47adb45d280947f448bcca6c4e2556.patch: Fix build
with poppler 25.02.0.

OBS-URL: https://build.opensuse.org/package/show/KDE:Extra/scribus?expand=0&rev=99
2025-02-19 15:33:09 +00:00
3b4f83bf48 Accepting request 1236679 from KDE:Extra
- Update to 1.6.3. Check the ChangeLog file for the full list of
  changes.
- Drop patch, merged upstream:
  * fix_build_with_poppler_24.12.0.patch

OBS-URL: https://build.opensuse.org/request/show/1236679
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/scribus?expand=0&rev=89
2025-01-12 10:10:24 +00:00
Christophe Marin
7f44fe5908 OBS-URL: https://build.opensuse.org/package/show/KDE:Extra/scribus?expand=0&rev=97 2025-01-09 18:43:19 +00:00
Christophe Marin
f9de24a2b0 OBS-URL: https://build.opensuse.org/package/show/KDE:Extra/scribus?expand=0&rev=96 2025-01-09 18:34:26 +00:00
Christophe Marin
776fda4fd6 Update to 1.6.3
OBS-URL: https://build.opensuse.org/package/show/KDE:Extra/scribus?expand=0&rev=95
2025-01-09 18:05:13 +00:00
Christophe Marin
13cc8acd02 revert to last rev
OBS-URL: https://build.opensuse.org/package/show/KDE:Extra/scribus?expand=0&rev=94
2025-01-09 17:53:36 +00:00
Christophe Marin
a70158db01 - Add poppler 25.01 compatibility patch:
* fix_build_with_poppler_25.01.0.patch

OBS-URL: https://build.opensuse.org/package/show/KDE:Extra/scribus?expand=0&rev=93
2025-01-09 11:27:33 +00:00
23aeb75955 Accepting request 1233597 from KDE:Extra
OBS-URL: https://build.opensuse.org/request/show/1233597
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/scribus?expand=0&rev=88
2024-12-30 11:50:39 +00:00
Christophe Marin
27ea792001 - Add poppler 24.10 compatibility patch:
* Add fix_build_with_poppler_24.12.0.patch
  * Drop 0001-Fix-build-with-poppler-24.10.0.patch

OBS-URL: https://build.opensuse.org/package/show/KDE:Extra/scribus?expand=0&rev=91
2024-12-27 19:42:56 +00:00
46258da329 Accepting request 1218617 from KDE:Extra
- Add poppler 24.10 compatibility patch:
  * 0001-Fix-build-with-poppler-24.10.0.patch

OBS-URL: https://build.opensuse.org/request/show/1218617
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/scribus?expand=0&rev=87
2024-10-28 14:17:41 +00:00
Christophe Marin
b803e95928 - Add poppler 24.10 compatibility patch:
* 0001-Fix-build-with-poppler-24.10.0.patch

OBS-URL: https://build.opensuse.org/package/show/KDE:Extra/scribus?expand=0&rev=89
2024-10-25 14:40:06 +00:00
8 changed files with 244 additions and 18 deletions

View File

@@ -0,0 +1,132 @@
From 857b62b7e88eb024539650a3de3c9b26c338ff64 Mon Sep 17 00:00:00 2001
From: jghali <jghali@11d20701-8431-0410-a711-e3c959e3b870>
Date: Fri, 6 Jun 2025 23:40:58 +0000
Subject: [PATCH] Fix build with PoDoFo 1.0.0
git-svn-id: svn://scribus.net/trunk/Scribus@26920 11d20701-8431-0410-a711-e3c959e3b870
---
scribus/pdf_analyzer.cpp | 31 +++++++++++++++++++++++++++++++
scribus/pdflib_core.cpp | 18 ++++++++++++++++++
2 files changed, 49 insertions(+)
diff --git a/scribus/pdf_analyzer.cpp b/scribus/pdf_analyzer.cpp
index d923148..3ecff48 100644
--- a/scribus/pdf_analyzer.cpp
+++ b/scribus/pdf_analyzer.cpp
@@ -276,7 +276,11 @@ bool PDFAnalyzer::inspectCanvas(PdfCanvas* canvas, QList<PDFColorSpace> & usedCo
try
{
// start parsing the content stream
+#if (PODOFO_VERSION >= PODOFO_MAKE_VERSION(1, 0, 0))
+ PdfContentReaderArgs tokenizerArgs;
+#else
PdfContentReaderArgs tokenizerArgs = { PdfContentReaderFlags::DontFollowXObjectForms };
+#endif
PdfContentStreamReader tokenizer(*canvas, tokenizerArgs);
PdfContent pdfContent;
PdfVariant var;
@@ -289,13 +293,29 @@ bool PDFAnalyzer::inspectCanvas(PdfCanvas* canvas, QList<PDFColorSpace> & usedCo
while (tokenizer.TryReadNext(pdfContent))
{
++tokenNumber;
+#if (PODOFO_VERSION >= PODOFO_MAKE_VERSION(1, 0, 0))
+ if (pdfContent.GetType() == PdfContentType::Operator)
+#else
if (pdfContent.Type == PdfContentType::Operator)
+#endif
{
args.clear();
+#if (PODOFO_VERSION >= PODOFO_MAKE_VERSION(1, 0, 0))
+ const auto& pdfContentStack = pdfContent.GetStack();
+ size_t stackSize = pdfContentStack.size();
+ for (size_t i = 0; i < stackSize; ++i)
+ args.append(pdfContentStack[stackSize - 1 - i]);
+#else
+
size_t stackSize = pdfContent.Stack.size();
for (size_t i = 0; i < stackSize; ++i)
args.append(pdfContent.Stack[stackSize - 1 - i]);
+#endif
+#if (PODOFO_VERSION >= PODOFO_MAKE_VERSION(1, 0, 0))
+ switch (pdfContent.GetOperator())
+#else
switch (pdfContent.Operator)
+#endif
{
case PdfOperator::q:
gsStack.push(currGS);
@@ -677,12 +697,23 @@ bool PDFAnalyzer::inspectCanvas(PdfCanvas* canvas, QList<PDFColorSpace> & usedCo
}
args.clear();
}
+#if (PODOFO_VERSION >= PODOFO_MAKE_VERSION(1, 0, 0))
+ if (pdfContent.GetType() == PdfContentType::DoXObject)
+#else
if (pdfContent.Type == PdfContentType::DoXObject)
+#endif
{
args.clear();
+#if (PODOFO_VERSION >= PODOFO_MAKE_VERSION(1, 0, 0))
+ const auto& pdfContentStack = pdfContent.GetStack();
+ size_t stackSize = pdfContentStack.size();
+ for (size_t i = 0; i < stackSize; ++i)
+ args.append(pdfContentStack[stackSize - 1 - i]);
+#else
size_t stackSize = pdfContent.Stack.size();
for (size_t i = 0; i < stackSize; ++i)
args.append(pdfContent.Stack[stackSize - 1 - i]);
+#endif
if (!processedNamedXObj.contains(args[0].GetName()))
{
if (args.size() == 1 && args[0].IsName() && xObjectsDict)
diff --git a/scribus/pdflib_core.cpp b/scribus/pdflib_core.cpp
index 3465ccd..5c6ebd1 100644
--- a/scribus/pdflib_core.cpp
+++ b/scribus/pdflib_core.cpp
@@ -9834,7 +9834,11 @@ bool PDFLibCore::PDF_EmbeddedPDF(PageItem* c, const QString& fn, double sx, doub
PoDoFo::PdfPage& page = doc->GetPages().GetPageAt(qMin(qMax(1, c->pixm.imgInfo.actualPageNumber), c->pixm.imgInfo.numberOfPages) - 1);
PoDoFo::PdfObject& pageObj = page.GetObject();
PoDoFo::PdfObject* contents = page.GetContents() ? &(page.GetContents()->GetObject()) : nullptr;
+#if (PODOFO_VERSION >= PODOFO_MAKE_VERSION(1, 0, 0))
+ const PoDoFo::PdfObject* resources = &(page.GetResources().GetObject());
+#else
PoDoFo::PdfObject* resources = page.GetResources() ? &(page.GetResources()->GetObject()) : nullptr;
+#endif
PoDoFo::PdfDictionary* pageObjDict = pageObj.IsDictionary() ? &(pageObj.GetDictionary()) : nullptr;
for (PoDoFo::PdfDictionary* par = pageObjDict, *parentDict = nullptr; par && !resources; par = parentDict)
{
@@ -9855,8 +9859,15 @@ bool PDFLibCore::PDF_EmbeddedPDF(PageItem* c, const QString& fn, double sx, doub
importedObjects[page.GetObject().GetIndirectReference()] = xObj;
writer.startObj(xObj);
PutDoc("<<\n/Type /XObject\n/Subtype /Form\n/FormType 1");
+#if (PODOFO_VERSION >= PODOFO_MAKE_VERSION(1, 0, 0))
+ PoDoFo::Rect pageRect = page.GetArtBoxRaw().GetNormalized(); // Because scimagedataloader_pdf use ArtBox
+ double rotation = 0;
+ if (!page.TryGetRotationRaw(rotation))
+ rotation = 0;
+#else
PoDoFo::Rect pageRect = page.GetArtBox(true); // Because scimagedataloader_pdf use ArtBox
int rotation = page.GetRotationRaw();
+#endif
double imgWidth = (rotation == 90 || rotation == 270) ? pageRect.Height : pageRect.Width;
double imgHeight = (rotation == 90 || rotation == 270) ? pageRect.Width : pageRect.Height;
QTransform pageM;
@@ -9976,8 +9987,15 @@ bool PDFLibCore::PDF_EmbeddedPDF(PageItem* c, const QString& fn, double sx, doub
importedObjects[page.GetObject().GetIndirectReference()] = xObj;
writer.startObj(xObj);
PutDoc("<<\n/Type /XObject\n/Subtype /Form\n/FormType 1");
+#if (PODOFO_VERSION >= PODOFO_MAKE_VERSION(1, 0, 0))
+ PoDoFo::Rect pageRect = page.GetArtBoxRaw().GetNormalized(); // Because scimagedataloader_pdf use ArtBox
+ double rotation = 0;
+ if (!page.TryGetRotationRaw(rotation))
+ rotation = 0;
+#else
PoDoFo::Rect pageRect = page.GetArtBox(true); // Because scimagedataloader_pdf use ArtBox
int rotation = page.GetRotationRaw();
+#endif
double imgWidth = (rotation == 90 || rotation == 270) ? pageRect.Height : pageRect.Width;
double imgHeight = (rotation == 90 || rotation == 270) ? pageRect.Width : pageRect.Height;
QTransform pageM;
--
2.49.0

View File

@@ -0,0 +1,30 @@
From 5386d1fd7e33d94d9caa33b1f166e60c1338e5e5 Mon Sep 17 00:00:00 2001
From: jghali <jghali@11d20701-8431-0410-a711-e3c959e3b870>
Date: Tue, 3 Jun 2025 22:50:26 +0000
Subject: [PATCH] Fix build with poppler 25.06.0
git-svn-id: svn://scribus.net/trunk/Scribus@26919 11d20701-8431-0410-a711-e3c959e3b870
---
scribus/plugins/import/pdf/slaoutput.cpp | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/scribus/plugins/import/pdf/slaoutput.cpp b/scribus/plugins/import/pdf/slaoutput.cpp
index 418df0a..3c65c3f 100644
--- a/scribus/plugins/import/pdf/slaoutput.cpp
+++ b/scribus/plugins/import/pdf/slaoutput.cpp
@@ -606,7 +606,12 @@ bool SlaOutputDev::handleWidgetAnnot(Annot* annota, double xCoor, double yCoor,
FormWidget *fm = m_formWidgets->getWidget(i);
if (!fm)
continue;
+#if POPPLER_ENCODED_VERSION >= POPPLER_VERSION_ENCODE(25, 06, 0)
+ std::shared_ptr<AnnotWidget> anoSharedPtr = fm->getWidgetAnnotation();
+ AnnotWidget* ano = anoSharedPtr.get();
+#else
AnnotWidget *ano = fm->getWidgetAnnotation();
+#endif
if (!ano)
continue;
if (ano != (AnnotWidget*) annota)
--
2.49.0

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:7eff9b1f47e372e56bb369f1dbe18fe49101789b5e6bcfdb7890e0346b641383
size 73129400

View File

@@ -1,6 +0,0 @@
-----BEGIN PGP SIGNATURE-----
iF0EABECAB0WIQRlWL6E0nJzpDihURmL6kgRiuvuZAUCZm2mxQAKCRCL6kgRiuvu
ZArHAJ0Ru6M6nyTplBSK4zzmPb2q7eqHrACfYR3rpqPw7A2/Acw3CDJ/NL8St5U=
=hugY
-----END PGP SIGNATURE-----

3
scribus-1.6.4.tar.xz Normal file
View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:533be7af03acfaa736ec5f7a3fc2562abd200fef5ca2a7cdee02b5f44d61829e
size 74761856

6
scribus-1.6.4.tar.xz.asc Normal file
View File

@@ -0,0 +1,6 @@
-----BEGIN PGP SIGNATURE-----
iF0EABECAB0WIQRlWL6E0nJzpDihURmL6kgRiuvuZAUCaAUFVAAKCRCL6kgRiuvu
ZFWiAKCAiEPNRcY2nmc8xFn5u1zudqqvLACdFLIANX9Q1CoXHCXjLYdE9vG1Yio=
=G20f
-----END PGP SIGNATURE-----

View File

@@ -1,3 +1,53 @@
-------------------------------------------------------------------
Sun Jun 8 08:55:14 UTC 2025 - Christophe Marin <christophe@krop.fr>
- Update to 1.6.4:
* Avoid custom font encodings when embedding TTF fonts in PDFs.
* Fixes to PDF import and export, and checkbox rendering on MS
Edge.
* Fixes for PDF/X-4 export when attempting to use ICC profile
unsuitable for output.
* Fixes some images being incorrectly imported as black when
importing PDF.
* Addressed compilation issues when building against newer
versions of poppler.
* Added new Python functions for page sizing, bounding boxes
for page items, min/max word kerning and a fix to locked
layer detection.
* Updated translation files
- Drop patch, merged upstream:
* 0001-Fix-build-error-with-poppler-25.02.0.patch
- Add patches:
* 0001-Fix-build-with-poppler-25.06.0.patch
* 0001-Fix-build-with-PoDoFo-1.0.0.patch
-------------------------------------------------------------------
Sun Feb 16 09:05:59 UTC 2025 - Bjørn Lie <bjorn.lie@gmail.com>
- Add 0001-Fix-build-error-with-poppler-25.02.0.patch: Fix build
with poppler 25.02.0.
-------------------------------------------------------------------
Thu Jan 9 18:00:48 UTC 2025 - Christophe Marin <christophe@krop.fr>
- Update to 1.6.3. Check the ChangeLog file for the full list of
changes.
- Drop patch, merged upstream:
* fix_build_with_poppler_24.12.0.patch
-------------------------------------------------------------------
Fri Dec 20 17:14:05 UTC 2024 - Bjørn Lie <bjorn.lie@gmail.com>
- Add poppler 24.10 compatibility patch:
* Add fix_build_with_poppler_24.12.0.patch
* Drop 0001-Fix-build-with-poppler-24.10.0.patch
-------------------------------------------------------------------
Fri Oct 25 14:39:51 UTC 2024 - Christophe Marin <christophe@krop.fr>
- Add poppler 24.10 compatibility patch:
* 0001-Fix-build-with-poppler-24.10.0.patch
-------------------------------------------------------------------
Tue Jul 2 14:52:57 UTC 2024 - Christophe Marin <christophe@krop.fr>

View File

@@ -1,7 +1,7 @@
#
# spec file for package scribus
#
# Copyright (c) 2022 SUSE LLC
# Copyright (c) 2025 SUSE LLC
# Copyright (c) Peter Linnell and 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
@@ -19,13 +19,21 @@
%bcond_without podofo
%bcond_without released
%{?sle15_python_module_pythons}
%if 0%{?suse_version} > 1500
%define pyver python3
%else
%define pyver python311
%endif
Name: scribus
Version: 1.6.2
Version: 1.6.4
Release: 0
Summary: Page Layout and Desktop Publishing (DTP)
License: GPL-2.0-or-later
URL: https://www.scribus.net/
# https://sourceforge.net/projects/scribus/files/scribus/1.6.2/
# https://sourceforge.net/projects/scribus/files/scribus/1.6.4/
Source0: %{name}-%{version}.tar.xz
%if %{with released}
Source1: %{name}-%{version}.tar.xz.asc
@@ -33,8 +41,10 @@ Source2: scribus.keyring
%endif
# PATCH-FIX-OPENSUSE
Patch0: 0001-Make-sure-information-displayed-on-the-about-window-.patch
# PATCH-FIX-UPSTREAM poppler...
# PATCH-FIX-UPSTREAM
Patch1: 0001-Fix-build-with-poppler-25.06.0.patch
# PATCH-FIX-UPSTREAM
Patch2: 0001-Fix-build-with-PoDoFo-1.0.0.patch
BuildRequires: cmake >= 3.14.0
BuildRequires: cups-devel
BuildRequires: dos2unix
@@ -56,7 +66,7 @@ BuildRequires: libwpd-devel
BuildRequires: libwpg-devel
BuildRequires: libzmf-devel
BuildRequires: pkgconfig
BuildRequires: python3-devel
BuildRequires: %{pyver}-devel
BuildRequires: cmake(Qt5Core) >= 5.14.0
BuildRequires: cmake(Qt5Gui)
BuildRequires: cmake(Qt5LinguistTools)
@@ -68,7 +78,6 @@ BuildRequires: cmake(Qt5Widgets)
BuildRequires: cmake(Qt5Xml)
BuildRequires: pkgconfig(GraphicsMagick)
BuildRequires: pkgconfig(cairo)
BuildRequires: pkgconfig(libpng16)
BuildRequires: pkgconfig(fontconfig)
BuildRequires: pkgconfig(freetype2)
BuildRequires: pkgconfig(harfbuzz)
@@ -77,13 +86,14 @@ BuildRequires: pkgconfig(icu-i18n)
BuildRequires: pkgconfig(icu-uc)
BuildRequires: pkgconfig(lcms2)
BuildRequires: pkgconfig(libjpeg)
BuildRequires: pkgconfig(libpng16)
BuildRequires: pkgconfig(libxml-2.0)
BuildRequires: pkgconfig(openssl)
BuildRequires: pkgconfig(poppler) > 21.03.0
BuildRequires: pkgconfig(zlib)
Requires: hicolor-icon-theme
Recommends: python3-Pillow
Recommends: python3-tk
Recommends: %{pyver}-Pillow
Recommends: %{pyver}-tk
Recommends: scribus-doc
# Not packaged anymore
Provides: scribus-devel = %{version}
@@ -114,7 +124,11 @@ find . -type f \( -iname \*.py -o -iname \*.cpp -o -iname \*.h \) -exec dos2unix
# Unused test file still using QQC1
rm scribus/ui/qml/qtq_test1.qml
%if 0%{?suse_version} > 1500
find . \( -name "*.py" -o -name "*.html" \) -exec sed -i 's#/usr/bin/env python.*#/usr/bin/python3#' {} \;
%else
find . \( -name "*.py" -o -name "*.html" \) -exec sed -i 's#/usr/bin/env python.*#/usr/bin/python3.11#' {} \;
%endif
%build
# Don't use the %%cmake macro, it causes crashes when starting scribus