diff --git a/src/analyzers/blockanalyzer.cpp b/src/analyzers/blockanalyzer.cpp index 7ff0830c0..bb6807a63 100644 --- a/src/analyzers/blockanalyzer.cpp +++ b/src/analyzers/blockanalyzer.cpp @@ -76,7 +76,7 @@ void BlockAnalyzer::resizeEvent(QResizeEvent* e) { // all is explained in analyze().. // +1 to counter -1 in maxSizes, trust me we need this! - m_columns = qMax(static_cast(static_cast(width() + 1) / (WIDTH + 1)), MAX_COLUMNS); + m_columns = qMin(static_cast(static_cast(width() + 1) / (WIDTH + 1)) + 1, MAX_COLUMNS); m_rows = static_cast(static_cast(height() + 1) / (HEIGHT + 1)); // this is the y-offset for drawing from the top of the widget