Hello community, here is the log from the commit of package libkdecoration2 for openSUSE:Factory checked in at 2015-12-29 12:57:01 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/libkdecoration2 (Old) and /work/SRC/openSUSE:Factory/.libkdecoration2.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Package is "libkdecoration2" Changes: -------- --- /work/SRC/openSUSE:Factory/libkdecoration2/libkdecoration2.changes 2015-11-24 22:27:12.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.libkdecoration2.new/libkdecoration2.changes 2015-12-29 12:57:02.000000000 +0100 @@ -1,0 +2,16 @@ +Tue Dec 15 17:49:56 UTC 2015 - hrvoje.senjan@gmail.com + +- Update to 5.5.1: + * Bugfix release + * For more details please see: + https://www.kde.org/announcements/plasma-5.5.1.php + +------------------------------------------------------------------- +Sat Dec 12 17:32:05 UTC 2015 - hrvoje.senjan@gmail.com + +- Update to 5.5.0: + * For more details please see: + https://dot.kde.org/2015/12/08/plasma-55-beautiful-new-artwork +- Move to cmake(...) BuildRequires where possible + +------------------------------------------------------------------- Old: ---- kdecoration-5.4.3.tar.xz New: ---- kdecoration-5.5.1.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ libkdecoration2.spec ++++++ --- /var/tmp/diff_new_pack.9hDXip/_old 2015-12-29 12:57:03.000000000 +0100 +++ /var/tmp/diff_new_pack.9hDXip/_new 2015-12-29 12:57:03.000000000 +0100 @@ -19,14 +19,14 @@ %define lname libkdecorations2-5 %define lname_private libkdecorations2private5 Name: libkdecoration2 -Version: 5.4.3 +Version: 5.5.1 Release: 0 BuildRequires: cmake >= 2.8.12 BuildRequires: extra-cmake-modules >= 0.0.11 BuildRequires: kf5-filesystem -BuildRequires: pkgconfig(Qt5Core) >= 5.4.0 -BuildRequires: pkgconfig(Qt5Gui) >= 5.4.0 -BuildRequires: pkgconfig(Qt5Test) >= 5.4.0 +BuildRequires: cmake(Qt5Core) >= 5.4.0 +BuildRequires: cmake(Qt5Gui) >= 5.4.0 +BuildRequires: cmake(Qt5Test) >= 5.4.0 Summary: KDE's window decorations library License: GPL-2.0+ Group: System/GUI/KDE @@ -43,7 +43,7 @@ Group: Development/Libraries/C and C++ Requires: %{lname_private} = %{version} Requires: %{lname} = %{version} -Requires: pkgconfig(Qt5Gui) >= 5.4.0 +Requires: cmake(Qt5Gui) >= 5.4.0 Obsoletes: libkdecorations-devel %description devel ++++++ kdecoration-5.4.3.tar.xz -> kdecoration-5.5.1.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kdecoration-5.4.3/CMakeLists.txt new/kdecoration-5.5.1/CMakeLists.txt --- old/kdecoration-5.4.3/CMakeLists.txt 2015-11-05 13:32:14.000000000 +0100 +++ new/kdecoration-5.5.1/CMakeLists.txt 2015-12-15 11:19:58.000000000 +0100 @@ -1,5 +1,5 @@ project(decoration-api) -set(PROJECT_VERSION "5.4.3") +set(PROJECT_VERSION "5.5.1") cmake_minimum_required(VERSION 2.8.12 FATAL_ERROR) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kdecoration-5.4.3/README.md new/kdecoration-5.5.1/README.md --- old/kdecoration-5.4.3/README.md 2015-11-05 13:32:14.000000000 +0100 +++ new/kdecoration-5.5.1/README.md 2015-12-15 11:19:58.000000000 +0100 @@ -12,6 +12,36 @@ * Decoration API for implementing a Decoration theme * Private API to implement the backend part (e.g. from Window Manager side) +## Providing a Decoration + +To provide a custom decoration one needs to create a plugin and provide an own implementation +of KDecoration2::Decoration. For a framework to load and find the plugin it needs to be compiled +with the proper json metadata. An example for such metadata (deco.json): + + { + "KPlugin": { + "Id": "org.kde.myAweseomeDecoration", + "ServiceTypes": [ + "org.kde.kdecoration2" + ] + }, + "org.kde.kdecoration2": { + "blur": false, /* blur behind not needed */ + "kcmodule": true /* comes with a configuration module */ + } + } + +To simplify one can use the KPluginFactory macro from the KCoreAddons framework: + + K_PLUGIN_FACTORY_WITH_JSON( + MyAwesomeDecorationFactory, + "deco.json", + registerPluginMyAwesomeDecoration::Decoration(); + ) + +The plugin needs to get installed to `${PLUGIN_INSTALL_DIR}/org.kde.kdecoration2`. + + ## Links - Home page: https://projects.kde.org/projects/kde/workspace/kdecoration diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kdecoration-5.4.3/src/decoration.h new/kdecoration-5.5.1/src/decoration.h --- old/kdecoration-5.4.3/src/decoration.h 2015-11-05 13:32:14.000000000 +0100 +++ new/kdecoration-5.5.1/src/decoration.h 2015-12-15 11:19:58.000000000 +0100 @@ -33,6 +33,10 @@ class QPainter; class QWheelEvent; +/** + * @brief Framework for creating window decorations. + * + **/ namespace KDecoration2 { @@ -41,6 +45,32 @@ class DecorationButton; class DecorationSettings; +/** + * @brief Base class for the Decoration. + * + * To provide a Decoration one needs to inherit from this class. The framework will instantiate + * an instance of the inherited class for each DecoratedClient. + * + * The main tasks of the Decoration is to provide borders around the DecoratedClient. For this + * the Deocration provides border sizes: those should be adjusted depending on the state of the + * DecoratedClient. E.g. commonly a maximized DecoratedClient does not have borders on the side, + * only the title bar. + * + * Whenever the visual representation of the Decoration changes the slot @link Decoration::update @endlink + * should be invoked to request a repaint. The framework will in return invoke the + * @link Decoration::paint @endlink method. This method needs to be implemented by inheriting + * classes. + * + * A Decoration commonly provides buttons for interaction. E.g. a close button to close the + * DecoratedClient. For such actions the Decoration provides slots which should be connected to + * the clicked signals of the buttons. For convenience the framework provides the @link DecorationButton @endlink + * and the @link DecorationButtonGroup @endlink for easier layout. It is not required to use those, + * if one uses different ways to represent the actions one needs to filter the events accordingly. + * + * @see DecoratedClient + * @see DecorationButton + * @see DecorationButtonGroup + **/ class KDECORATIONS2_EXPORT Decoration : public QObject { Q_OBJECT @@ -123,6 +153,15 @@ **/ QSharedPointer<DecorationSettings> settings() const; + /** + * Implement this method in inheriting classes to provide the rendering. + * + * The @p painter is set up to paint on an internal QPaintDevice. The painting is + * implicitly double buffered. + * + * @param painter The painter which needs to be used for rendering + * @param repaintArea The region which needs to be repainted. + **/ virtual void paint(QPainter *painter, const QRect &repaintArea) = 0; virtual bool event(QEvent *event) override; @@ -159,6 +198,16 @@ void shadowChanged(const QSharedPointer<DecorationShadow> &shadow); protected: + /** + * Constructor for the Decoration. + * + * The @p args are used by the decoration framework to pass meta information + * to the Decoration. An inheriting class is supposed to pass the args to the + * parent class. + * + * @param parent The parent of the Decoration + * @param args Additional arguments passed in from the framework + **/ explicit Decoration(QObject *parent, const QVariantList &args); void setBorders(const QMargins &borders); void setResizeOnlyBorders(const QMargins &borders); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kdecoration-5.4.3/src/decorationbutton.cpp new/kdecoration-5.5.1/src/decorationbutton.cpp --- old/kdecoration-5.4.3/src/decorationbutton.cpp 2015-11-05 13:32:14.000000000 +0100 +++ new/kdecoration-5.5.1/src/decorationbutton.cpp 2015-12-15 11:19:58.000000000 +0100 @@ -33,10 +33,12 @@ namespace KDecoration2 { +#ifndef DOXYGEN_SHOULD_SKIP_THIS uint qHash(const DecorationButtonType &type) { return static_cast<uint>(type); } +#endif DecorationButton::Private::Private(DecorationButtonType type, const QPointer<Decoration> &decoration, DecorationButton *parent) : decoration(decoration) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kdecoration-5.4.3/src/decorationbutton.h new/kdecoration-5.5.1/src/decorationbutton.h --- old/kdecoration-5.4.3/src/decorationbutton.h 2015-11-05 13:32:14.000000000 +0100 +++ new/kdecoration-5.5.1/src/decorationbutton.h 2015-12-15 11:19:58.000000000 +0100 @@ -37,7 +37,9 @@ class DecorationButtonPrivate; class Decoration; +#ifndef DOXYGEN_SHOULD_SKIP_THIS uint KDECORATIONS2_EXPORT qHash(const DecorationButtonType &type); +#endif /** * @brief A button to be used in a Decoration. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kdecoration-5.4.3/src/decorationbuttongroup.cpp new/kdecoration-5.5.1/src/decorationbuttongroup.cpp --- old/kdecoration-5.4.3/src/decorationbuttongroup.cpp 2015-11-05 13:32:14.000000000 +0100 +++ new/kdecoration-5.5.1/src/decorationbuttongroup.cpp 2015-12-15 11:19:58.000000000 +0100 @@ -45,7 +45,9 @@ emit q->geometryChanged(geometry); } +namespace { static bool s_layoutRecursion = false; +} void DecorationButtonGroup::Private::updateLayout() { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kdecoration-5.4.3/src/decorationsettings.h new/kdecoration-5.5.1/src/decorationsettings.h --- old/kdecoration-5.4.3/src/decorationsettings.h 2015-11-05 13:32:14.000000000 +0100 +++ new/kdecoration-5.5.1/src/decorationsettings.h 2015-12-15 11:19:58.000000000 +0100 @@ -33,14 +33,47 @@ class DecorationBridge; class DecorationSettingsPrivate; +/** + * @brief Common settings for the Decoration. + * + * This class gets injected into the Decoration and provides recommendations for the + * Decoration. The Decoration is suggested to honor the settings, but may decide that some + * settings don't fit the design and ignore them. + * + * @see Decoration + **/ class KDECORATIONS2_EXPORT DecorationSettings : public QObject { Q_OBJECT + /** + * Whether the feature to put a DecoratedClient on all desktops is available. + * + * If this feature is not available a Decoration might decide to not show the + * DecorationButtonType::OnAllDesktops. + **/ Q_PROPERTY(bool onAllDesktopsAvailable READ isOnAllDesktopsAvailable NOTIFY onAllDesktopsAvailableChanged) + /** + * Whether the Decoration will be rendered with an alpha channel. + * + * If no alpha channel is available a Decoration should not use round borders. + **/ Q_PROPERTY(bool alphaChannelSupported READ isAlphaChannelSupported NOTIFY alphaChannelSupportedChanged) + /** + * Whether the Decoration should close the DecoratedClient when double clicking on the + * DecorationButtonType::Menu. + **/ Q_PROPERTY(bool closeOnDoubleClickOnMenu READ isCloseOnDoubleClickOnMenu NOTIFY closeOnDoubleClickOnMenuChanged) + /** + * The suggested ordering of the decoration buttons on the left. + **/ Q_PROPERTY(QVectorKDecoration2::DecorationButtonType decorationButtonsLeft READ decorationButtonsLeft NOTIFY decorationButtonsLeftChanged) + /** + * The suggested ordering of the decoration buttons on the right. + **/ Q_PROPERTY(QVectorKDecoration2::DecorationButtonType decorationButtonsRight READ decorationButtonsRight NOTIFY decorationButtonsRightChanged) + /** + * The suggested border size. + **/ Q_PROPERTY(KDecoration2::BorderSize borderSize READ borderSize NOTIFY borderSizeChanged) /** * The fundamental unit of space that should be used for sizes, expressed in pixels. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kdecoration-5.4.3/src/decorationshadow.cpp new/kdecoration-5.5.1/src/decorationshadow.cpp --- old/kdecoration-5.4.3/src/decorationshadow.cpp 2015-11-05 13:32:14.000000000 +0100 +++ new/kdecoration-5.5.1/src/decorationshadow.cpp 2015-12-15 11:19:58.000000000 +0100 @@ -115,6 +115,8 @@ return QRect(0, d->innerShadowRect.top(), d->innerShadowRect.left(), d->innerShadowRect.height()); } +#ifndef DOXYGEN_SHOULD_SKIP_THIS + #define DELEGATE(type, name) \ type DecorationShadow::name() const \ { \ @@ -151,6 +153,7 @@ SETTER(const QImage&, setShadow, shadow) #undef SETTER +#endif void DecorationShadow::setPadding(const QMargins &margins) {