rename num_rows etc to max_rows for clarity
rename num_rows etc to max_rows for clarity

It can be the case when calculating row-first that the number of columns ends up allowing all cells to be accomodated in fewer rows. For example, if you have 6 items, and set nrows=4, then ncols=2, but 6 items can be accomodated in 3 rows.

ipython/ipython,ipython/ipython