From 129568baf9da34272127507a138ec30af888b40c Mon Sep 17 00:00:00 2001 From: pravindalve Date: Fri, 26 Mar 2021 14:54:07 +0530 Subject: Thermo package slot added to Distillation input --- DockWidgets/DockWidgetDistillationColumn.py | 11 +- DockWidgets/DockWidgetDistillationColumn.ui | 381 +++++++++++---------- .../DockWidgetDistillationColumn.cpython-37.pyc | Bin 5219 -> 5603 bytes .../DockWidgetMaterialStream.cpython-37.pyc | Bin 8254 -> 8254 bytes Undo.dat | Bin 0 -> 1788 bytes 5 files changed, 207 insertions(+), 185 deletions(-) diff --git a/DockWidgets/DockWidgetDistillationColumn.py b/DockWidgets/DockWidgetDistillationColumn.py index dea2391..e93ed47 100644 --- a/DockWidgets/DockWidgetDistillationColumn.py +++ b/DockWidgets/DockWidgetDistillationColumn.py @@ -102,6 +102,13 @@ class DockWidgetDistillationColumn(QDockWidget,ui_dialog): self.input_dict.append(self.cb4) self.input_dict.append(self.le8) + self.lines = [line.rstrip('\n') for line in open('thermopackage.txt')] + for j in self.lines: + self.cbTP.addItem(str(j)) + self.cbTP.setCurrentText(self.obj.variables['thermo_package']['value']) + + self.input_dict.append(self.cbTP) + # self.input_dict = [self.le1, self.le2, self.le3, self.cb5, self.le5, self.cb1, self.cb2, self.le6, self.le7, self.cb3, self.cb4, self.le8] except Exception as e: @@ -154,7 +161,9 @@ class DockWidgetDistillationColumn(QDockWidget,ui_dialog): print(temp+8) self.dict.append(int(self.input_dict[temp+9].text())) print(temp+9) - + self.dict.append(self.input_dict[temp+10].currentText()) + print(temp + 10) + print("param ", self.dict) self.obj.param_setter(self.dict) self.hide() diff --git a/DockWidgets/DockWidgetDistillationColumn.ui b/DockWidgets/DockWidgetDistillationColumn.ui index 7e63254..95f258b 100644 --- a/DockWidgets/DockWidgetDistillationColumn.ui +++ b/DockWidgets/DockWidgetDistillationColumn.ui @@ -9,7 +9,7 @@ 0 0 - 392 + 382 700 @@ -31,10 +31,10 @@ - 10 + 0 30 - 361 - 621 + 351 + 451 @@ -47,194 +47,207 @@ Input Data - - - - 10 - 10 - 331 - 204 - - - - Parameter Selection - - - - QLayout::SetFixedSize - - - - - - 0 - 0 - + + + + + Parameter Selection + + + + QLayout::SetFixedSize - - 0 - - - - General - - - - - - QLayout::SetDefaultConstraint - - - 0 - - - - - - - - Condenser - - - - - - - - TextLabel - - - - - - - TextLabel + + + + + 0 + 0 + + + + 0 + + + + General + + + + + + QLayout::SetDefaultConstraint - - - - - - TextLabel - - - - - - - - - - - - - TextLabel - - - - - - - false - - - - - - - TextLabel - - - - - - - TextLabel + + 0 - - - - - - - + - - - - - - Reboiler - - - - - - - - TextLabel - - - - - - - TextLabel - - - - - - - TextLabel - - + + + + Condenser + + + + + + + + TextLabel + + + + + + + TextLabel + + + + + + + TextLabel + + + + + + + + + + + + + TextLabel + + + + + + + false + + + + + + + TextLabel + + + + + + + TextLabel + + + + + + + + + + - - - - false - - - - - - - - - - - - - - - - TextLabel - - + + + + + Reboiler + + + + + + + + TextLabel + + + + + + + TextLabel + + + + + + + TextLabel + + + + + + + false + + + + + + + + + + + + + + + + TextLabel + + + + - - - - - - - - - - - 10 - 270 - 331 - 21 - - - - Submit - - + + + + + + + + + + + + + + + Thermo Package + + + + + + + + + + + + + + + + + + Submit + + + + diff --git a/DockWidgets/__pycache__/DockWidgetDistillationColumn.cpython-37.pyc b/DockWidgets/__pycache__/DockWidgetDistillationColumn.cpython-37.pyc index af05fb7..900b9c6 100644 Binary files a/DockWidgets/__pycache__/DockWidgetDistillationColumn.cpython-37.pyc and b/DockWidgets/__pycache__/DockWidgetDistillationColumn.cpython-37.pyc differ diff --git a/DockWidgets/__pycache__/DockWidgetMaterialStream.cpython-37.pyc b/DockWidgets/__pycache__/DockWidgetMaterialStream.cpython-37.pyc index f2c5b98..395ced6 100644 Binary files a/DockWidgets/__pycache__/DockWidgetMaterialStream.cpython-37.pyc and b/DockWidgets/__pycache__/DockWidgetMaterialStream.cpython-37.pyc differ diff --git a/Undo.dat b/Undo.dat index e69de29..8ff5ac0 100644 Binary files a/Undo.dat and b/Undo.dat differ -- cgit