From kde-core-devel Sat Jul 05 13:08:23 2008 From: Michael Leupold Date: Sat, 05 Jul 2008 13:08:23 +0000 To: kde-core-devel Subject: Text in tabs being cut off Message-Id: <200807051508.23165.lemma () confuego ! org> X-MARC-Message: https://marc.info/?l=kde-core-devel&m=121526335523921 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--Boundary-00=_HJ3bItYAHhNAHh2" --Boundary-00=_HJ3bItYAHhNAHh2 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline Hi there, a while ago I wrote a small patch to fix a bug causing some characters (like 'A' or 'y') being cut off in a tabbar. The bug is already on the TT task tracker but I figured it might be nice to have this fix in qt-copy. Do you think it's ok to commit? Regards, Michael --Boundary-00=_HJ3bItYAHhNAHh2 Content-Type: text/x-diff; charset="utf-8"; name="0236-fix-qt-qtabbar-size.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0236-fix-qt-qtabbar-size.diff" qt-bugs@ issue : N216195 Trolltech task ID : 216537 bugs.kde.org number : 162737 applied: no author: Michael Leupold This patch fixes some characters in a tabbar being cut-off due to a wrong size hint (visible if using a kstyle). --- src/gui/widgets/qtabbar.cpp (Revision 820510) +++ src/gui/widgets/qtabbar.cpp (Arbeitskopie) @@ -1084,7 +1084,7 @@ QStyleOptionTabV2 opt; initStyleOption(&opt, index); opt.text = d->tabList.at(index).text; - QSize iconSize = tab->icon.isNull() ? QSize() : opt.iconSize; + QSize iconSize = tab->icon.isNull() ? QSize(0, 0) : opt.iconSize; int hframe = style()->pixelMetric(QStyle::PM_TabBarTabHSpace, &opt, this); int vframe = style()->pixelMetric(QStyle::PM_TabBarTabVSpace, &opt, this); const QFontMetrics fm = fontMetrics(); --Boundary-00=_HJ3bItYAHhNAHh2--