123 |
# of the table and will destroy it when done. Otherwise you |
# of the table and will destroy it when done. Otherwise you |
124 |
# would need to keep a reference to it and call its Destroy |
# would need to keep a reference to it and call its Destroy |
125 |
# method later. |
# method later. |
126 |
self.SetTable(self.table, true) |
self.SetTable(self.table, True) |
127 |
|
|
128 |
#self.SetMargins(0,0) |
#self.SetMargins(0,0) |
129 |
|
|
131 |
# column widths automatically but it would cause a traversal of |
# column widths automatically but it would cause a traversal of |
132 |
# the entire table which for large .dbf files can take a very |
# the entire table which for large .dbf files can take a very |
133 |
# long time. |
# long time. |
134 |
#self.AutoSizeColumns(false) |
#self.AutoSizeColumns(False) |
135 |
|
|
136 |
self.SetSelectionMode(wxGrid.wxGridSelectRows) |
self.SetSelectionMode(wxGrid.wxGridSelectRows) |
137 |
|
|
432 |
self.grid.Subscribe(ROW_SELECTED, self.rows_selected) |
self.grid.Subscribe(ROW_SELECTED, self.rows_selected) |
433 |
self.parent.Subscribe(SHAPES_SELECTED, self.select_shapes) |
self.parent.Subscribe(SHAPES_SELECTED, self.select_shapes) |
434 |
|
|
435 |
|
# if there is already a selection present, update the grid |
436 |
|
# accordingly |
437 |
|
sel = self.get_selected().keys() |
438 |
|
for i in sel: |
439 |
|
self.grid.SelectRow(i, True) |
440 |
|
|
441 |
def make_grid(self, table): |
def make_grid(self, table): |
442 |
"""Override the derived method to return a LayerTableGrid. |
"""Override the derived method to return a LayerTableGrid. |
443 |
""" |
""" |