diff options
Diffstat (limited to 'src/ui_table.py')
-rw-r--r-- | src/ui_table.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/ui_table.py b/src/ui_table.py index 08b99f3..7640ace 100644 --- a/src/ui_table.py +++ b/src/ui_table.py @@ -163,7 +163,7 @@ class SystemTableRow: def __init__(self, parent, pol, row_number): self.parent = parent self.pol = pol - pol.row = self + self.row_number = row_number self.angle = pol.angle self.delta = pol.delta @@ -211,6 +211,10 @@ class SystemTable(QTableWidget): self.vh = self.verticalHeader() self.vh.setSectionResizeMode(QHeaderView.ResizeToContents) + def renumber_rows(self): + for i, row in enumerate(self.rows): + row.row_number = i + def populate(self, system): self.system = system |