From atlantik-devel Wed Sep 11 04:00:57 2002 From: Rob Kaper Date: Wed, 11 Sep 2002 04:00:57 +0000 To: atlantik-devel Subject: Bug#47254: [atlantik-devel] Bug#47254: atlantik-devel] Bug#47254: small image text in both themes X-MARC-Message: https://marc.info/?l=atlantik-devel&m=103171705421229 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--Boundary-00=_5/rf9b2M/nFAs8R" --Boundary-00=_5/rf9b2M/nFAs8R Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Saturday 31 August 2002 17:43, Rick Fournier wrote: > On August 31, 2002 11:25 am, Rob Kaper wrote: > > On Saturday 31 August 2002 09:18, rick@help-desk.ca wrote: > > > small image text in both themes make it imposible to read the estates > > > name, cost and owner when they display in the middle of the board > > > > What version of Qt? More people have complained about this but I cannot > > reproduce it myself. :-/ > > Rob > > im running qt-3.0.5 2 wich was install via freebsd ports Can you try the attached patch? Rob =2D-=20 Rob Kaper | Gimme some love, gimme some skin, cap@capsi.com | if we ain't got that then we ain't got much www.capsi.com | and we ain't got nothing, nothing! -- "Nothing" by A --Boundary-00=_5/rf9b2M/nFAs8R Content-Type: text/x-diff; charset="iso-8859-1"; name="estatedetailsfontsize.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="estatedetailsfontsize.diff" Index: libatlantikui/estatedetails.cpp =================================================================== RCS file: /home/kde/kdegames/atlantik/libatlantikui/estatedetails.cpp,v retrieving revision 1.11 diff -u -3 -d -p -r1.11 estatedetails.cpp --- libatlantikui/estatedetails.cpp 2002/08/15 10:56:25 1.11 +++ libatlantikui/estatedetails.cpp 2002/09/11 03:59:47 @@ -151,7 +151,11 @@ void EstateDetails::paintEvent(QPaintEve // Estate name painter.setPen(Qt::white); - painter.setFont(QFont(KGlobalSettings::generalFont().family(), KGlobalSettings::generalFont().pointSize() * 2, QFont::Bold)); + int fontSize = KGlobalSettings::generalFont().pointSize(); + if (fontSize == -1) + fontSize = KGlobalSettings::generalFont().pixelSize(); + + painter.setFont(QFont(KGlobalSettings::generalFont().family(), fontSize * 2, QFont::Bold)); painter.drawText(KDialog::marginHint(), KDialog::marginHint(), width()-KDialog::marginHint(), titleHeight, Qt::AlignJustify, m_estate->name()); painter.setPen(Qt::black); @@ -160,34 +164,34 @@ void EstateDetails::paintEvent(QPaintEve // Estate group if (m_estate->estateGroup()) { - xText = titleHeight - KGlobalSettings::generalFont().pointSize() - KDialog::marginHint(); - painter.setFont(QFont(KGlobalSettings::generalFont().family(), KGlobalSettings::generalFont().pointSize(), QFont::Bold)); + xText = titleHeight - fontSize - KDialog::marginHint(); + painter.setFont(QFont(KGlobalSettings::generalFont().family(), fontSize, QFont::Bold)); painter.drawText(5, xText, width()-10, titleHeight, Qt::AlignRight, m_estate->estateGroup()->name().upper()); } - xText = titleHeight + KGlobalSettings::generalFont().pointSize() + 5; - painter.setFont(QFont(KGlobalSettings::generalFont().family(), KGlobalSettings::generalFont().pointSize(), QFont::Normal)); + xText = titleHeight + fontSize + 5; + painter.setFont(QFont(KGlobalSettings::generalFont().family(), fontSize, QFont::Normal)); // Price if (m_estate->price()) { painter.drawText(5, xText, i18n("Price: %1").arg(m_estate->price())); - xText += (KGlobalSettings::generalFont().pointSize() + 5); + xText += (fontSize + 5); } // Owner, houses, isMortgaged if (m_estate->canBeOwned()) { painter.drawText(5, xText, i18n("Owner: %1").arg(m_estate->owner() ? m_estate->owner()->name() : i18n("unowned"))); - xText += (KGlobalSettings::generalFont().pointSize() + 5); + xText += (fontSize + 5); if (m_estate->isOwned()) { painter.drawText(5, xText, i18n("Houses: %1").arg(m_estate->houses())); - xText += (KGlobalSettings::generalFont().pointSize() + 5); + xText += (fontSize + 5); painter.drawText(5, xText, i18n("Mortgaged: %1").arg(m_estate->isMortgaged() ? i18n("Yes") : i18n("No"))); - xText += (KGlobalSettings::generalFont().pointSize() + 5); + xText += (fontSize + 5); } } --Boundary-00=_5/rf9b2M/nFAs8R-- (Complete bug history is available at http://bugs.kde.org/db/47/47254.html) _______________________________________________ atlantik-devel mailing list atlantik-devel@mail.kde.org http://mail.kde.org/mailman/listinfo/atlantik-devel