[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: koffice/kexi/tableview
From: Lucijan Busch <lucijan () gmx ! at>
Date: 2003-07-02 18:02:39
[Download RAW message or body]
CVS commit by lucijan:
fixed the annoying painting bug wich sometimes drawed the backgroundaltering stripes to wide
M +27 -19 kexitableview.cpp 1.63
--- koffice/kexi/tableview/kexitableview.cpp #1.62:1.63
@@ -2,5 +2,4 @@
Copyright (C) 2002 Till Busch <till@bux.at>
Lucijan Busch <lucijan@gmx.at>
- Daniel Molkentin <molkentin@kde.org>
Copyright (C) 2003 Joseph Wenninger <jowenn@kde.org>
Copyright (C) 2003 Jaroslaw Staniek <js@iidea.pl>
@@ -86,8 +85,10 @@ KexiTableView::KexiTableView(QWidget *pa
m_rowHeight = fontMetrics().lineSpacing() + 4;
#else
- m_rowHeight = fontMetrics().lineSpacing() + 4;
+ m_rowHeight = fontMetrics().lineSpacing() + 1;
#endif
- if(m_rowHeight < 17)
+
+if(m_rowHeight < 17)
m_rowHeight = 17;
+
m_pBufferPm = 0;
@@ -511,13 +512,16 @@ void KexiTableView::drawContents( QPaint
int r;
- pb->fillRect(0, 0, cw, ch, colorGroup().base());
+// pb->fillRect(0, 0, cw, ch, colorGroup().base());
QPtrListIterator<KexiTableItem> it(*m_contents);
it += rowfirst;
- int maxwc = QMIN(cw, (columnPos(m_numCols - 1) + columnWidth(m_numCols - 1)));
- pb->fillRect(maxwc, 0, cw - maxwc, ch, colorGroup().base());
- pb->fillRect(0, rowPos(rowlast) + m_rowHeight, cw, ch, colorGroup().base());
+// int maxwc = QMIN(cw, (columnPos(m_numCols - 1) + columnWidth(m_numCols - 1)));
+ int maxwc = columnPos(cols() - 1) + columnWidth(cols() - 1);
+ kdDebug() << "KexiTableView::drawContents(): maxwc: " << maxwc << endl;
+// pb->fillRect(maxwc, 0, cw - maxwc, ch, colorGroup().base());
+// pb->fillRect(0, rowPos(rowlast) + m_rowHeight, cw, ch, colorGroup().base());
+ pb->fillRect(cx, cy, cw, ch, colorGroup().base());
for(r = rowfirst; r <= rowlast; r++, ++it)
{
@@ -1280,6 +1286,8 @@ void KexiTableView::columnWidthChanged(
else
// updateContents( columnPos(col), 0, contentsWidth(), contentsHeight() );
- updateContents(columnPos(col), 0, viewport()->width(), contentsHeight());
+ updateContents(contentsX(), 0, viewport()->width(), contentsHeight());
// viewport()->repaint();
+
+// updateContents(0, 0, m_pBufferPm->width(), m_pBufferPm->height());
if (m_pEditor)
{
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic