From: Manuel Nickschas Date: Wed, 17 Sep 2008 15:28:29 +0000 (+0200) Subject: Fix line spacing being wrong for some people (partially cut off ChatLines) X-Git-Tag: 0.3.1~276 X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=commitdiff_plain;h=49fd75e982cfddf27a59429d25acb03c8b9e6c75 Fix line spacing being wrong for some people (partially cut off ChatLines) --- diff --git a/src/qtui/chatitem.cpp b/src/qtui/chatitem.cpp index 9519d60c..50d74f5e 100644 --- a/src/qtui/chatitem.cpp +++ b/src/qtui/chatitem.cpp @@ -63,7 +63,6 @@ qreal ChatItem::setGeometry(qreal w, qreal h) { prepareGeometryChange(); _boundingRect.setWidth(w); if(h < 0) h = computeHeight(); - //if(h < 0) h = fontMetrics()->lineSpacing(); // only contents can be multi-line _boundingRect.setHeight(h); if(haveLayout()) updateLayout(); return h; @@ -296,7 +295,7 @@ void ContentsChatItem::updateLayout() { int col = finder.nextWrapColumn(); line.setNumColumns(col >= 0 ? col - line.textStart() : layout()->text().length()); line.setPosition(QPointF(0, h)); - h += line.height() + fontMetrics()->leading(); + h += fontMetrics()->lineSpacing(); } layout()->endLayout(); }