Hello community,

here is the log from the commit of package plasma5-workspace for 
openSUSE:Factory checked in at 2016-11-04 20:58:35
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/plasma5-workspace (Old)
 and      /work/SRC/openSUSE:Factory/.plasma5-workspace.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "plasma5-workspace"

Changes:
--------
--- /work/SRC/openSUSE:Factory/plasma5-workspace/plasma5-workspace.changes      
2016-10-28 12:26:12.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.plasma5-workspace.new/plasma5-workspace.changes 
2016-11-04 20:58:36.000000000 +0100
@@ -1,0 +2,25 @@
+Wed Nov  2 12:24:35 UTC 2016 - [email protected]
+
+- Call qtpaths with an absolute path in startkde to make sure the
+  system one is used (boo#1004769)
+
+-------------------------------------------------------------------
+Wed Nov  2 11:12:23 UTC 2016 - [email protected]
+
+- Add use-nearest-aspect-ratio-available-wallpaper.diff to improve the
+  selection of wallpapers keeping the same (or as similar as possible)
+  aspect ratio (boo#990257). Include the latest changes submitted
+  upstream to work better with QUAD HD screen resolutions.
+
+-------------------------------------------------------------------
+Tue Nov  1 10:36:40 UTC 2016 - [email protected]
+
+- Update to 5.8.3
+  * New bugfix release
+  * For more details please see:
+    https://www.kde.org/announcements/plasma-5.8.3.php
+- Remove upstream patches:
+  * fix-sddm-theme-logic.diff
+  * remove-sddm-graphicaleffects-dep.patch
+
+-------------------------------------------------------------------

Old:
----
  fix-sddm-theme-logic.diff
  plasma-workspace-5.8.2.tar.xz
  remove-sddm-graphicaleffects-dep.patch

New:
----
  plasma-workspace-5.8.3.tar.xz
  use-nearest-aspect-ratio-available-wallpaper.diff

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

Other differences:
------------------
++++++ plasma5-workspace.spec ++++++
--- /var/tmp/diff_new_pack.2Nk6QA/_old  2016-11-04 20:58:37.000000000 +0100
+++ /var/tmp/diff_new_pack.2Nk6QA/_new  2016-11-04 20:58:37.000000000 +0100
@@ -20,7 +20,7 @@
 
 %bcond_without lang
 Name:           plasma5-workspace
-Version:        5.8.2
+Version:        5.8.3
 Release:        0
 %{!?_plasma5_version: %global _plasma5_version %{version}}
 Summary:        The KDE Plasma Workspace Components
@@ -40,10 +40,8 @@
 # PATCHES 100-200 and above are from upstream 5.8 branch
 # PATCH-FIX-UPSTREAM 
keep-wallpaper-aspect-ratio-wallpaper-on-screen-resolution-change.diff 
[email protected] -- Keep wallpaper aspect ratio on screen resolution change
 Patch100:       
keep-wallpaper-aspect-ratio-wallpaper-on-screen-resolution-change.diff
-# PATCH-FIX-UPSTREAM fix-sddm-theme-logic.diff boo#1003742 [email protected] 
-- Fix sddm logic to use avatar list or text entry when usermodel.count is 0
-Patch101:       fix-sddm-theme-logic.diff
-# PATCH-FIX-UPSTREAM remove-sddm-graphicaleffects-dep.patch kde#371493 
[email protected] -- Remove unused import QtGraphicalEffects
-Patch102:       remove-sddm-graphicaleffects-dep.patch
+# PATCH-FIX-UPSTREAM use-nearest-aspect-ratio-available-wallpaper.diff 
[email protected] -- New distance algorithm to simplify and improve the 
wallpaper selection
+Patch101:       use-nearest-aspect-ratio-available-wallpaper.diff
 # PATCHES 201-300 and above are from upstream master/5.9 branch
 BuildRequires:  breeze5-icons
 BuildRequires:  fdupes
@@ -216,7 +214,6 @@
 %patch3 -p1
 %patch100 -p1
 %patch101 -p1
-%patch102 -p1
 
 %build
   %cmake_kf5 -d build -- -DKDE4_COMMON_PAM_SERVICE=xdm 
-DKDE_DEFAULT_HOME=.kde4 -DCMAKE_INSTALL_LOCALEDIR=%{_kf5_localedir}

++++++ 0001-Rename-qdbus-in-startkde.patch ++++++
--- /var/tmp/diff_new_pack.2Nk6QA/_old  2016-11-04 20:58:37.000000000 +0100
+++ /var/tmp/diff_new_pack.2Nk6QA/_new  2016-11-04 20:58:37.000000000 +0100
@@ -2,11 +2,13 @@
 index 91c8a3c..0c658bd 100644
 --- a/startkde/startkde.cmake
 +++ b/startkde/startkde.cmake
-@@ -21,13 +21,13 @@ unset DYLD_FORCE_FLAT_NAMESPACE
+@@ -20,14 +20,14 @@ unset DYLD_FORCE_FLAT_NAMESPACE
+ # in case we have been started with full pathname spec without being in PATH
  bindir=`echo "$0" | sed -n 's,^\(/.*\)/[^/][^/]*$,\1,p'`
  if [ -n "$bindir" ]; then
-   qbindir=`qtpaths --binaries-dir`
+-  qbindir=`qtpaths --binaries-dir`
 -  qdbus=$qbindir/qdbus
++  qbindir=`/usr/bin/qtpaths --binaries-dir`
 +  qdbus=$qbindir/qdbus-qt5
    case $PATH in
      $bindir|$bindir:*|*:$bindir|*:$bindir:*) ;;

++++++ plasma-workspace-5.8.2.tar.xz -> plasma-workspace-5.8.3.tar.xz ++++++
/work/SRC/openSUSE:Factory/plasma5-workspace/plasma-workspace-5.8.2.tar.xz 
/work/SRC/openSUSE:Factory/.plasma5-workspace.new/plasma-workspace-5.8.3.tar.xz 
differ: char 27, line 1

++++++ use-nearest-aspect-ratio-available-wallpaper.diff ++++++
Index: plasma-workspace-5.8.2/wallpapers/image/image.cpp
===================================================================
--- plasma-workspace-5.8.2.orig/wallpapers/image/image.cpp
+++ plasma-workspace-5.8.2/wallpapers/image/image.cpp
@@ -156,13 +156,14 @@ void Image::setRenderingMode(RenderingMo
 float distance(const QSize& size, const QSize& desired)
 {
     // compute difference of areas
-    float delta = size.width() * size.height() -
-                  desired.width() * desired.height();
-    // scale down to about 1.0
-    delta /= ((desired.width() * desired.height())+(size.width() * 
size.height()))/2;
+    float desiredAspectRatio = ( desired.height() > 0 ) ? desired.width() / 
(float)desired.height() : 0;
+    float candidateAspectRatio = (size.height() > 0 ) ? size.width() / 
(float)size.height() : FLT_MAX;
+
+    float delta = size.width() - desired.width();
+    delta = (delta >= 0.0 ? delta : -delta*2 ); // Penalize for scaling up
+
+    return qAbs(candidateAspectRatio - desiredAspectRatio)*25000 + delta;
 
-    // Difference of areas, slight preference to scale down
-    return delta >= 0.0 ? delta : -delta + 2.0;
 }
 
 QSize resSize(const QString &str)
@@ -187,42 +188,28 @@ void Image::findPreferedImageInPackage(K
         return;
     }
 
-    //qDebug() << "wanted" << m_targetSize << "options" << images;
+    //float targetAspectRatio = (m_targetSize.height() > 0 ) ? 
m_targetSize.width() / (float)m_targetSize.height() : 0;
+    //qDebug() << "wanted" << m_targetSize << "options" << images << "aspect 
ratio" << targetAspectRatio;
 
-    // choose the nearest resolution, always preferring images with the same 
aspect ratio
     float best = FLT_MAX;
-    float bestWithSameAspectRatio = FLT_MAX;
-    float targetAspectRatio = ( m_targetSize.height() > 0 ) ? 
m_targetSize.width() / (float)m_targetSize.height() : 0;
-
     QString bestImage;
-    QString bestImageWithSameAspectRatio;
     foreach (const QString &entry, images) {
         QSize candidate = resSize(QFileInfo(entry).baseName());
         if (candidate == QSize()) {
             continue;
         }
-        float candidateAspectRatio = (candidate.height() > 0 ) ? 
candidate.width() / (float)candidate.height() : FLT_MAX;
+        //float candidateAspectRatio = (candidate.height() > 0 ) ? 
candidate.width() / (float)candidate.height() : FLT_MAX;
 
         double dist = distance(candidate, m_targetSize);
         //qDebug() << "candidate" << candidate << "distance" << dist << 
"aspect ratio" << candidateAspectRatio;
 
-        if ( candidateAspectRatio == targetAspectRatio && 
(bestImageWithSameAspectRatio.isEmpty() || dist < bestWithSameAspectRatio) ) {
-            bestImageWithSameAspectRatio = entry;
-            bestWithSameAspectRatio = dist;
-            //qDebug() << "bestWithSameAspectRatio" << 
bestImageWithSameAspectRatio;
-            if (dist == 0) {
-                break;
-            }
-        } else if (bestImage.isEmpty() || dist < best) {
+        if (bestImage.isEmpty() || dist < best) {
             bestImage = entry;
             best = dist;
             //qDebug() << "best" << bestImage;
         }
     }
 
-    if (!bestImageWithSameAspectRatio.isEmpty()) // Always prefer an image 
with the same aspect ratio as the target (if available)
-       bestImage=bestImageWithSameAspectRatio;
-
     //qDebug() << "best image" << bestImage;
     package.removeDefinition("preferred");
     package.addFileDefinition("preferred", "images/" + bestImage, 
i18n("Recommended wallpaper file"));

Reply via email to