~ubuntu-branches/debian/experimental/qtcurve/experimental

« back to all changes in this revision

Viewing changes to qt4/kwin/qtcurveshadowconfiguration.h

  • Committer: Package Import Robot
  • Author(s): Boris Pek, Thanks to Scarlett Clark
  • Date: 2015-07-26 04:17:05 UTC
  • mfrom: (1.1.1)
  • Revision ID: package-import@ubuntu.com-20150726041705-yuxbierbpely1fvp
Tags: 1.8.18+git20150711-a3fff13-1
* Upstream Git snapshot (1.8.18-242-ga3fff13) is taken from:
  http://quickgit.kde.org/?p=qtcurve.git
* Localization files are taken from last stable release (1.8.18).
* Fixed in upstream:
  - gtk2-engines-qtcurve: inkscape 0.91 crashes after palette mouse-over
    (Closes: #786831)
  - gtk2-engines-qtcurve: massive memory leak in mysql-workbench
    (Closes: #682162)
* Update debian/patches:
  - delete qt53-build-fix.diff (fixed in upstream)
  - add enable-translations.patch
* Update debian/control:
  - bump Standards-Version to 3.9.6 (was 3.9.5): no changes required
  - update Build-Depends for transition from KDE4 to KF5:
    + delete dependencies from: kdebase-workspace-dev and qtdeclarative5-dev
    + add dependencies from: extra-cmake-modules, kio-dev,
      libkf5archive-dev, libkf5config-dev, libkf5configwidgets-dev,
      libkf5i18n-dev, libkf5kdelibs4support-dev, libkf5widgetsaddons-dev,
      libkf5xmlgui-dev, libqt5x11extras5-dev, libxcb1-dev, pkg-config
      [Thanks to Scarlett Clark]
  - delete package kwin-style-qtcurve: it is not available for KF5 yet
    (LP: #1452218)
  - package kde-style-qtcurve now provides package kde-style-qtcurve-qt4
  - package kde-style-qtcurve is "Multi-Arch: same" now
  - metapackage qtcurve now depends on kde-style-qtcurve-qt5 and recommends
    kwin-decoration-oxygen, oxygen-icon-theme and oxygencursors
* Update debian/rules:
  - build using kf5 libraries instead of kde4
  - update configure flags
  - use xz compression in packages
* Update debian/kde-style-qtcurve.install:
  there are no KDE4 related files anymore.
* Update debian/kde-style-qtcurve-qt5.install.
* Update debian/copyright.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*****************************************************************************
2
2
 *   Copyright 2007 - 2010 Craig Drummond <craig.p.drummond@gmail.com>       *
3
 
 *   Copyright 2013 - 2013 Yichao Yu <yyc1992@gmail.com>                     *
 
3
 *   Copyright 2013 - 2015 Yichao Yu <yyc1992@gmail.com>                     *
4
4
 *                                                                           *
5
5
 *   This program is free software; you can redistribute it and/or modify    *
6
6
 *   it under the terms of the GNU Lesser General Public License as          *
30
30
 
31
31
class KConfig;
32
32
 
33
 
namespace KWinQtCurve
34
 
{
35
 
 
36
 
class QtCurveShadowConfiguration
37
 
{
38
 
    public:
39
 
 
40
 
    enum ColorType
41
 
    {
42
 
        CT_FOCUS     = 0,
43
 
        CT_HOVER     = 1,
 
33
namespace QtCurve {
 
34
namespace KWin {
 
35
 
 
36
class ShadowConfig {
 
37
public:
 
38
    enum ColorType {
 
39
        CT_FOCUS = 0,
 
40
        CT_HOVER = 1,
44
41
        CT_SELECTION = 2,
45
 
        CT_TITLEBAR  = 3,
46
 
        CT_GRAY      = 4,
47
 
        CT_CUSTOM    = 5
 
42
        CT_TITLEBAR = 3,
 
43
        CT_GRAY = 4,
 
44
        CT_CUSTOM = 5
48
45
    };
49
46
 
50
 
    enum ShadowType
51
 
    {
52
 
        SH_ACTIVE   = 0,
 
47
    enum ShadowType {
 
48
        SH_ACTIVE = 0,
53
49
        SH_INACTIVE = 1
54
50
    };
55
51
 
56
 
    enum Constants
57
 
    {
58
 
        MIN_SIZE   = 10,
59
 
        MAX_SIZE   = 100,
 
52
    enum {
 
53
        MIN_SIZE = 10,
 
54
        MAX_SIZE = 100,
60
55
        MIN_OFFSET = 0,
61
56
        MAX_OFFSET = 20
62
57
    };
63
58
 
64
 
    QtCurveShadowConfiguration(QPalette::ColorGroup);
65
 
 
66
 
    virtual ~QtCurveShadowConfiguration() { }
 
59
    ShadowConfig(QPalette::ColorGroup);
67
60
 
68
61
    void                 defaults();
69
62
    void                 load(KConfig *cfg);
88
81
    const QColor &       midColor() const             { return m_color; }
89
82
    const QColor &       outerColor() const           { return m_color; }
90
83
 
91
 
    bool operator == (const QtCurveShadowConfiguration& other) const
 
84
    bool operator == (const ShadowConfig& other) const
92
85
    {
93
86
        return  m_colorGroup == other.m_colorGroup &&
94
87
                m_size == other.m_size &&
98
91
                m_shadowType == other.m_shadowType;
99
92
    }
100
93
 
101
 
    private:
102
 
 
 
94
private:
103
95
    QPalette::ColorGroup m_colorGroup;
104
96
    int                  m_size,
105
97
                         m_hOffset,
110
102
};
111
103
 
112
104
}
 
105
}
113
106
 
114
107
#endif