Automatically set the widths of given columns to optimal sizes. Parameters ---------- col : int or sequence of ints The indices of the columns to auto-scale.
(self, col)
| 495 | cell.set_y(bottoms[row]) |
| 496 | |
| 497 | def auto_set_column_width(self, col): |
| 498 | """ |
| 499 | Automatically set the widths of given columns to optimal sizes. |
| 500 | |
| 501 | Parameters |
| 502 | ---------- |
| 503 | col : int or sequence of ints |
| 504 | The indices of the columns to auto-scale. |
| 505 | """ |
| 506 | col1d = np.atleast_1d(col) |
| 507 | if not np.issubdtype(col1d.dtype, np.integer): |
| 508 | raise TypeError("col must be an int or sequence of ints.") |
| 509 | for cell in col1d: |
| 510 | self._autoColumns.append(cell) |
| 511 | |
| 512 | self.stale = True |
| 513 | |
| 514 | def _auto_set_column_width(self, col, renderer): |
| 515 | """Automatically set width for column.""" |
no outgoing calls