From 4cbd36572dab36ef43da6730c8e50e3f27f1fc06 Mon Sep 17 00:00:00 2001 From: Charles Dang Date: Tue, 6 Oct 2020 13:57:38 +1100 Subject: [PATCH] Fixed some sections showing --- src/gui/dialogs/outro.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/gui/dialogs/outro.cpp b/src/gui/dialogs/outro.cpp index 5b207fe2087..b2cf620acd3 100644 --- a/src/gui/dialogs/outro.cpp +++ b/src/gui/dialogs/outro.cpp @@ -54,11 +54,11 @@ outro::outro(const game_classification& info) continue; } - // Split the names into chunks of 5 - static const unsigned chunk_size = 5; + // Split the names into chunks of 5. Use float for proper ceil function! + static const float chunk_size = 5.0; const unsigned num_names = about.names.size(); - const unsigned num_chunks = std::max(1, std::ceil(num_names / chunk_size)); + const unsigned num_chunks = std::ceil(num_names / chunk_size); for(std::size_t i = 0; i < num_chunks; ++i) { std::stringstream ss;