Hello community,

here is the log from the commit of package calendarsupport for openSUSE:Factory 
checked in at 2020-11-25 19:29:31
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/calendarsupport (Old)
 and      /work/SRC/openSUSE:Factory/.calendarsupport.new.5913 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "calendarsupport"

Wed Nov 25 19:29:31 2020 rev:58 rq:850459 version:20.08.3

Changes:
--------
--- /work/SRC/openSUSE:Factory/calendarsupport/calendarsupport.changes  
2020-11-10 13:35:12.288980004 +0100
+++ 
/work/SRC/openSUSE:Factory/.calendarsupport.new.5913/calendarsupport.changes    
    2020-11-25 19:30:19.618554912 +0100
@@ -1,0 +2,6 @@
+Tue Nov 24 11:30:13 UTC 2020 - Christophe Giboudeaux <[email protected]>
+
+- Add upstream patch to fix build with Qt 5.15.2:
+  * 0001-Port-away-from-deprecated-QPrinter-functions.patch
+
+-------------------------------------------------------------------

New:
----
  0001-Port-away-from-deprecated-QPrinter-functions.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ calendarsupport.spec ++++++
--- /var/tmp/diff_new_pack.nbND8I/_old  2020-11-25 19:30:20.306555589 +0100
+++ /var/tmp/diff_new_pack.nbND8I/_new  2020-11-25 19:30:20.310555592 +0100
@@ -29,6 +29,8 @@
 Group:          Development/Libraries/KDE
 URL:            https://www.kde.org
 Source:         
https://download.kde.org/stable/release-service/%{version}/src/%{name}-%{version}.tar.xz
+# PATCH-FIX-UPSTREAM
+Patch0:         0001-Port-away-from-deprecated-QPrinter-functions.patch
 BuildRequires:  extra-cmake-modules >= %{kf5_version}
 BuildRequires:  kdepim-apps-libs-devel
 BuildRequires:  kf5-filesystem
@@ -88,7 +90,7 @@
 %lang_package
 
 %prep
-%setup -q
+%autosetup -p1
 
 %build
 %cmake_kf5 -d build

++++++ 0001-Port-away-from-deprecated-QPrinter-functions.patch ++++++
From b4193facb223bd5b73a65318dec8ced51b66adf7 Mon Sep 17 00:00:00 2001
From: Nicolas Fella <[email protected]>
Date: Wed, 9 Sep 2020 17:26:46 +0200
Subject: [PATCH] Port away from deprecated QPrinter functions

This implies changing from QPrinter::Orientation to QPageLayout::Orientation. 
The actual values are the same tough.
---
 src/printing/calprintdefaultplugins.cpp | 14 +++++++-------
 src/printing/calprintdefaultplugins.h   | 10 +++++-----
 src/printing/calprinter.cpp             |  6 +++---
 src/printing/calprintpluginbase.cpp     |  8 ++++----
 src/printing/calprintpluginbase.h       |  2 +-
 src/printing/printplugin.h              |  4 ++--
 src/printing/yearprint.cpp              |  6 +++---
 src/printing/yearprint.h                |  2 +-
 8 files changed, 26 insertions(+), 26 deletions(-)

diff --git a/src/printing/calprintdefaultplugins.cpp 
b/src/printing/calprintdefaultplugins.cpp
index 862b74d..e3d802d 100644
--- a/src/printing/calprintdefaultplugins.cpp
+++ b/src/printing/calprintdefaultplugins.cpp
@@ -805,7 +805,7 @@ void CalPrintDay::print(QPainter &p, int width, int height)
         QString line1 = local.toString(mFromDate, QLocale::ShortFormat);
         QString line2 = local.toString(mToDate, QLocale::ShortFormat);
         QString title;
-        if (orientation() == QPrinter::Landscape) {
+        if (orientation() == QPageLayout::Landscape) {
             title = i18nc("date from-to", "%1 - %2", line1, line2);
         } else {
             title = i18nc("date from-\nto", "%1 -\n%2", line1, line2);
@@ -1050,14 +1050,14 @@ void CalPrintWeek::saveConfig()
     }
 }
 
-QPrinter::Orientation CalPrintWeek::defaultOrientation() const
+QPageLayout::Orientation CalPrintWeek::defaultOrientation() const
 {
     if (mWeekPrintType == Filofax) {
-        return QPrinter::Portrait;
+        return QPageLayout::Portrait;
     } else if (mWeekPrintType == SplitWeek) {
-        return QPrinter::Portrait;
+        return QPageLayout::Portrait;
     } else {
-        return QPrinter::Landscape;
+        return QPageLayout::Landscape;
     }
 }
 
@@ -1099,7 +1099,7 @@ void CalPrintWeek::print(QPainter &p, int width, int 
height)
         do {
             line1 = local.toString(curWeek.addDays(-6), QLocale::ShortFormat);
             line2 = local.toString(curWeek, QLocale::ShortFormat);
-            if (orientation() == QPrinter::Landscape) {
+            if (orientation() == QPageLayout::Landscape) {
                 title = i18nc("date from-to", "%1 - %2", line1, line2);
             } else {
                 title = i18nc("date from-\nto", "%1 -\n%2", line1, line2);
@@ -1126,7 +1126,7 @@ void CalPrintWeek::print(QPainter &p, int width, int 
height)
         do {
             line1 = local.toString(curWeek.addDays(-6), QLocale::ShortFormat);
             line2 = local.toString(curWeek, QLocale::ShortFormat);
-            if (orientation() == QPrinter::Landscape) {
+            if (orientation() == QPageLayout::Landscape) {
                 title = i18nc("date from - to (week number)", "%1 - %2 (Week 
%3)",
                               line1, line2, curWeek.weekNumber());
             } else {
diff --git a/src/printing/calprintdefaultplugins.h 
b/src/printing/calprintdefaultplugins.h
index 4df72f6..3f62d0b 100644
--- a/src/printing/calprintdefaultplugins.h
+++ b/src/printing/calprintdefaultplugins.h
@@ -53,9 +53,9 @@ public:
     }
 
     QWidget *createConfigWidget(QWidget *) override;
-    Q_REQUIRED_RESULT QPrinter::Orientation defaultOrientation() const override
+    Q_REQUIRED_RESULT QPageLayout::Orientation defaultOrientation() const 
override
     {
-        return QPrinter::Portrait;
+        return QPageLayout::Portrait;
     }
 
 public:
@@ -166,7 +166,7 @@ public:
     /**
       Returns the default orientation for the eWeekPrintType.
     */
-    QPrinter::Orientation defaultOrientation() const override;
+    QPageLayout::Orientation defaultOrientation() const override;
 
 public:
     void print(QPainter &p, int width, int height) override;
@@ -222,9 +222,9 @@ public:
     }
 
     QWidget *createConfigWidget(QWidget *) override;
-    QPrinter::Orientation defaultOrientation() const override
+    QPageLayout::Orientation defaultOrientation() const override
     {
-        return QPrinter::Landscape;
+        return QPageLayout::Landscape;
     }
 
 public:
diff --git a/src/printing/calprinter.cpp b/src/printing/calprinter.cpp
index 182e0e3..10e9db6 100644
--- a/src/printing/calprinter.cpp
+++ b/src/printing/calprinter.cpp
@@ -126,13 +126,13 @@ void CalPrinter::doPrint(PrintPlugin *selectedStyle, 
CalPrinter::ePrintOrientati
     QPrinter printer;
     switch (dlgorientation) {
     case eOrientPlugin:
-        printer.setOrientation(selectedStyle->defaultOrientation());
+        printer.setPageOrientation(selectedStyle->defaultOrientation());
         break;
     case eOrientPortrait:
-        printer.setOrientation(QPrinter::Portrait);
+        printer.setPageOrientation(QPageLayout::Portrait);
         break;
     case eOrientLandscape:
-        printer.setOrientation(QPrinter::Landscape);
+        printer.setPageOrientation(QPageLayout::Landscape);
         break;
     case eOrientPrinter:
         break;
diff --git a/src/printing/calprintpluginbase.cpp 
b/src/printing/calprintpluginbase.cpp
index e96f3b2..9db198e 100644
--- a/src/printing/calprintpluginbase.cpp
+++ b/src/printing/calprintpluginbase.cpp
@@ -232,9 +232,9 @@ void CalPrintPluginBase::setPrintFooter(bool printFooter)
     mPrintFooter = printFooter;
 }
 
-QPrinter::Orientation CalPrintPluginBase::orientation() const
+QPageLayout::Orientation CalPrintPluginBase::orientation() const
 {
-    return mPrinter ? mPrinter->orientation() : QPrinter::Portrait;
+    return mPrinter ? mPrinter->pageLayout().orientation() : 
QPageLayout::Portrait;
 }
 
 QColor CalPrintPluginBase::getTextColor(const QColor &c) const
@@ -326,7 +326,7 @@ int CalPrintPluginBase::headerHeight() const
 {
     if (mHeaderHeight >= 0) {
         return mHeaderHeight;
-    } else if (orientation() == QPrinter::Portrait) {
+    } else if (orientation() == QPageLayout::Portrait) {
         return PORTRAIT_HEADER_HEIGHT;
     } else {
         return LANDSCAPE_HEADER_HEIGHT;
@@ -356,7 +356,7 @@ int CalPrintPluginBase::footerHeight() const
 
     if (mFooterHeight >= 0) {
         return mFooterHeight;
-    } else if (orientation() == QPrinter::Portrait) {
+    } else if (orientation() == QPageLayout::Portrait) {
         return PORTRAIT_FOOTER_HEIGHT;
     } else {
         return LANDSCAPE_FOOTER_HEIGHT;
diff --git a/src/printing/calprintpluginbase.h 
b/src/printing/calprintpluginbase.h
index ff1113c..b3d41ac 100644
--- a/src/printing/calprintpluginbase.h
+++ b/src/printing/calprintpluginbase.h
@@ -108,7 +108,7 @@ public:
     */
     static int weekdayColumn(int weekday);
 
-    QPrinter::Orientation orientation() const;
+    QPageLayout::Orientation orientation() const;
 
     /** Returns the height of the page header. If the height was explicitly
         set using setHeaderHeight, that value is returned, otherwise a
diff --git a/src/printing/printplugin.h b/src/printing/printplugin.h
index 57afdfe..73bf467 100644
--- a/src/printing/printplugin.h
+++ b/src/printing/printplugin.h
@@ -140,9 +140,9 @@ public:
       config settings), implement this function in your subclass and
       return the desired orientation.
     */
-    virtual QPrinter::Orientation defaultOrientation() const
+    virtual QPageLayout::Orientation defaultOrientation() const
     {
-        return QPrinter::Portrait;
+        return QPageLayout::Portrait;
     }
 
     /**
diff --git a/src/printing/yearprint.cpp b/src/printing/yearprint.cpp
index 3287ca6..e57a1c4 100644
--- a/src/printing/yearprint.cpp
+++ b/src/printing/yearprint.cpp
@@ -82,9 +82,9 @@ void CalPrintYear::saveConfig()
     }
 }
 
-QPrinter::Orientation CalPrintYear::defaultOrientation() const
+QPageLayout::Orientation CalPrintYear::defaultOrientation() const
 {
-    return (mPages == 1) ? QPrinter::Landscape : QPrinter::Portrait;
+    return (mPages == 1) ? QPageLayout::Landscape : QPageLayout::Portrait;
 }
 
 void CalPrintYear::setDateRange(const QDate &from, const QDate &to)
@@ -131,7 +131,7 @@ void CalPrintYear::print(QPainter &p, int width, int height)
         QString stdate = locale.toString(start, QLocale::ShortFormat);
         QString endate = locale.toString(end, QLocale::ShortFormat);
         QString title;
-        if (orientation() == QPrinter::Landscape) {
+        if (orientation() == QPageLayout::Landscape) {
             title = i18nc("date from - to", "%1 - %2", stdate, endate);
         } else {
             title = i18nc("date from -\nto", "%1 -\n%2", stdate, endate);
diff --git a/src/printing/yearprint.h b/src/printing/yearprint.h
index e59bf87..cd46a50 100644
--- a/src/printing/yearprint.h
+++ b/src/printing/yearprint.h
@@ -48,7 +48,7 @@ public:
     }
 
     QWidget *createConfigWidget(QWidget *) override;
-    Q_REQUIRED_RESULT QPrinter::Orientation defaultOrientation() const 
override;
+    Q_REQUIRED_RESULT QPageLayout::Orientation defaultOrientation() const 
override;
 
 public:
     void print(QPainter &p, int width, int height) override;
-- 
2.29.2
_______________________________________________
openSUSE Commits mailing list -- [email protected]
To unsubscribe, email [email protected]
List Netiquette: https://en.opensuse.org/openSUSE:Mailing_list_netiquette
List Archives: 
https://lists.opensuse.org/archives/list/[email protected]

Reply via email to