[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-panel-devel
Subject: [PATCH] BUG 184905 Size of the panel changes when the plasma theme
From: <wppan () redflag-linux ! com>
Date: 2009-08-03 3:17:44
Message-ID: 4A7656D8.2030102 () redflag-linux ! com
[Download RAW message or body]
Hi, all
These days I've been working on BUG 184905.
I found that the size of panel changes when it receives a thememChanged
signal from Plasma::Theme::defaultTheme(). And this signal is sended
when we change the plasma theme or enable/disable window effects.
The reason is that the margins of panel's layout isn't equal to the
margins of panel's background.
(kdebase/workspace/plasma/containments/panel/panel.cpp line 678-684)
And I found that it is not necessary to adjust margins for toolBoxItem,
(kdebase/workspace/plasma/containments/panel/panel.cpp line 553-568)
because the geometry of toolBoxItem is controlled by Plasma::Containment.
I'm not sure whether my understanding is correct. ):
Regards
--
ÅËÎÀƽ(Peter Pan)
Red Flag Software Co., Ltd
["kdebase-panel-size-increasing.patch" (text/x-patch)]
Index: panel.cpp
===================================================================
--- panel.cpp (版本 1006104)
+++ panel.cpp (工作副本)
@@ -550,23 +550,6 @@
//invalidate the layout and set again
if (layout()) {
- switch (location()) {
- case LeftEdge:
- rightWidth = qMin(rightWidth, qMax(qreal(1), size().width() - \
KIconLoader::SizeMedium));
- break;
- case RightEdge:
- leftWidth = qMin(leftWidth, qMax(qreal(1), size().width() - \
KIconLoader::SizeMedium));
- break;
- case TopEdge:
- bottomHeight = qMin(bottomHeight, qMax(qreal(1), size().height() - \
KIconLoader::SizeMedium));
- break;
- case BottomEdge:
- topHeight = qMin(topHeight, qMax(qreal(1), size().height() - \
KIconLoader::SizeMedium));
- break;
- default:
- break;
- }
-
qreal oldLeft = leftWidth;
qreal oldTop = topHeight;
qreal oldRight = rightWidth;
_______________________________________________
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic