BUG: Auto-detect terminal size on max_col/max_row==0