SVN commit 1023328 by alexmerry: SVN_SILENT: put the comment by the code it refers to M +1 -1 taskitemlayout.cpp --- trunk/KDE/kdebase/workspace/plasma/applets/tasks/taskitemlayout.cpp #1023327:1023328 @@ -182,10 +182,10 @@ return m_maxRows; } - // in this case rows are columns, columns are rows... //TODO basicPreferredSize isn't the optimal source here because it changes because of margins probably QSizeF itemSize = m_itemPositions.first()->basicPreferredSize(); if (m_layoutOrientation == Qt::Vertical) { + // in this case rows are columns, columns are rows... maxRows = qMin(qMax(1, int(m_groupItem->geometry().width() / itemSize.width())), m_maxRows); } else { maxRows = qMin(qMax(1, int(m_groupItem->geometry().height() / itemSize.height())), m_maxRows);