mesh on selection

master
Theophile Terraz 2025-10-01 10:29:14 +02:00
parent 706a900c8e
commit 911a2bbbff
1 changed files with 10 additions and 3 deletions

View File

@ -55,7 +55,7 @@ class MeshingDialog(PamhyrDialog):
self._space_step = 50.0
self._lplan = False
self._lm = "3"
self._linear = False
self._linear = True
self._begin_cs = -1
self._end_cs = -1
self._begin_dir = "un"
@ -89,8 +89,15 @@ class MeshingDialog(PamhyrDialog):
self.combobox_add_items("comboBox_begin_rk", profiles)
self.combobox_add_items("comboBox_end_rk", profiles)
if len(self.parent.tableView.selectedIndexes()) <= 1:
self.set_combobox_text("comboBox_begin_rk", profiles[0])
self.set_combobox_text("comboBox_end_rk", profiles[-1])
else:
r = self.parent.tableView\
.selectionModel()\
.selectedRows()
self.set_combobox_text("comboBox_begin_rk", profiles[r[0].row()])
self.set_combobox_text("comboBox_end_rk", profiles[r[-1].row()])
@property
def profiles(self):