Tuple indicating the number of rows and columns in the Layout.

def shape(self):
        "Tuple indicating the number of rows and columns in the Layout."
        num = len(self)
        if num <= self._max_cols:
            return (1, num)
        nrows = num // self._max_cols
        last_row_cols = num % self._max_cols
        return nrows+(1 if last_row_cols else 0), min(num, self._max_cols)