[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdebase/workspace/plasma/applets/digital-clock
From: Beat Wolf <asraniel () fryx ! ch>
Date: 2009-09-01 20:07:18
Message-ID: 1251835638.006607.17070.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 1018539 by beatwolf:
fix the layout in vertical panels
BUG:188918
M +4 -2 clock.cpp
--- trunk/KDE/kdebase/workspace/plasma/applets/digital-clock/clock.cpp #1018538:1018539
@@ -135,16 +135,17 @@
if (m_showDate || showTimezone()) {
const QFont f(KGlobalSettings::smallestReadableFont());
const QFontMetrics metrics(f);
+ qDebug() <<"sizes" << f.pointSize() << f.pixelSize();
// if there's enough vertical space, wrap the words
if (contentsRect().height() < f.pointSize() * 6) {
QSize s = metrics.size(Qt::TextSingleLine, m_dateString);
w = s.width() + metrics.width(" ");
- h = s.height();
+ h = f.pointSize();
//kDebug(96669) << "uS: singleline" << w;
} else {
QSize s = metrics.size(Qt::TextWordWrap, m_dateString);
w = s.width();
- h = s.height();
+ h = f.pointSize();
//kDebug(96669) << "uS: wordwrap" << w;
}
@@ -168,6 +169,7 @@
// kDebug(96669) << contentsRect();
} else {
// We have a fixed width, set some sensible height
+ qDebug() << "height" << h;
setMinimumHeight(h);
setMinimumWidth(0);
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic