def METHOD_NAME(self, widths):
    # `widths` can be None. If it is, then default widths are set.
    columns = self.model.column_list
    if not widths:
        widths = [column.default_width for column in columns]
    for column, width in zip(columns, widths):
        if width == 0:  # column was hidden before.
            width = column.default_width
        self._header_view.resizeSection(column.logical_index, width)