MCPcopy Index your code
hub / github.com/matplotlib/matplotlib / _auto_set_column_width

Method _auto_set_column_width

lib/matplotlib/table.py:514–520  ·  view source on GitHub ↗

Automatically set width for column.

(self, col, renderer)

Source from the content-addressed store, hash-verified

512 self.stale = True
513
514 def _auto_set_column_width(self, col, renderer):
515 """Automatically set width for column."""
516 cells = [cell for key, cell in self._cells.items() if key[1] == col]
517 max_width = max((cell.get_required_width(renderer) for cell in cells),
518 default=0)
519 for cell in cells:
520 cell.set_width(max_width)
521
522 def auto_set_font_size(self, value=True):
523 """Automatically set font size."""

Callers 1

_update_positionsMethod · 0.95

Calls 2

get_required_widthMethod · 0.80
set_widthMethod · 0.45

Tested by

no test coverage detected