diff options
author | SaurabhAgarwala | 2019-12-24 18:51:46 +0530 |
---|---|---|
committer | SaurabhAgarwala | 2019-12-24 18:51:46 +0530 |
commit | 6eb53b150dd4fde58996c826960e0c8adf2c5b00 (patch) | |
tree | a5376e9bbf7f4c6046a2645f23df60511bd3bf88 | |
parent | 69b7cbf63b47cc5144626434ce9d0cfc17c5f5ad (diff) | |
download | Chemical-Simulator-GUI-6eb53b150dd4fde58996c826960e0c8adf2c5b00.tar.gz Chemical-Simulator-GUI-6eb53b150dd4fde58996c826960e0c8adf2c5b00.tar.bz2 Chemical-Simulator-GUI-6eb53b150dd4fde58996c826960e0c8adf2c5b00.zip |
Shortcut keys added, typo corrected
-rw-r--r-- | main.ui | 8 | ||||
-rw-r--r-- | mainApp.py | 16 |
2 files changed, 18 insertions, 6 deletions
@@ -185,7 +185,7 @@ <property name="title"> <string>Compounds</string> </property> - <addaction name="actionSelect_compouns"/> + <addaction name="actionSelect_compounds"/> </widget> <widget class="QMenu" name="menuHelp"> <property name="title"> @@ -256,7 +256,7 @@ <widget class="QWidget" name="scrollAreaWidgetContents"> <property name="geometry"> <rect> - <x>0</x> + <x>-5</x> <y>0</y> <width>222</width> <height>978</height> @@ -1111,7 +1111,7 @@ <addaction name="actionEquation_oriented"/> <addaction name="actionSequential_mode"/> <addaction name="separator"/> - <addaction name="actionSelect_compouns"/> + <addaction name="actionSelect_compounds"/> </widget> <action name="actionZoomIn"> <property name="icon"> @@ -1158,7 +1158,7 @@ <string>Sequential mode</string> </property> </action> - <action name="actionSelect_compouns"> + <action name="actionSelect_compounds"> <property name="icon"> <iconset> <normaloff>icons/compoundSelector.png</normaloff>icons/compoundSelector.png</iconset> @@ -95,19 +95,31 @@ class MainApp(QMainWindow,ui): menu bar like new,zoom,comounds selector, simulation options. ''' def menuBar(self): - self.actionSelect_compouns.triggered.connect(self.selectCompounds) + self.actionSelect_compounds.triggered.connect(self.selectCompounds) + self.actionSelect_compounds.setShortcut('Ctrl+C') self.actionZoomIn.triggered.connect(self.zoomin) + self.actionZoomIn.setShortcut('Ctrl++') self.actionNew_Flowsheet.triggered.connect(self.new) + self.actionNew_Flowsheet.setShortcut('Ctrl+N') self.actionZoomOut.triggered.connect(self.zoomout) + self.actionZoomOut.setShortcut('Ctrl+-') self.actionResetZoom.triggered.connect(self.zoomReset) + self.actionResetZoom.setShortcut('Ctrl+R') self.actionHelp.triggered.connect(self.help) + self.actionHelp.setShortcut('Ctrl+H') self.actionSequential_mode.triggered.connect(partial(self.simulate,'SM')) + self.actionSequential_mode.setShortcut('Ctrl+M') self.actionEquation_oriented.triggered.connect(partial(self.simulate,'EQN')) + self.actionEquation_oriented.setShortcut('Ctrl+E') # self.actionUndo_2.triggered.connect(self.undoStack.undo) # self.actionRedo.triggered.connect(self.undoStack.redo) self.actionSave_2.triggered.connect(self.save) + self.actionSave_2.setShortcut('Ctrl+S') self.actionOpen.triggered.connect(self.open) + self.actionOpen.setShortcut('Ctrl+O') self.actionTerminate.triggered.connect(self.terminate) + self.actionTerminate.setShortcut('Ctrl+T') + ''' Handles all the buttons of different components. @@ -189,7 +201,7 @@ class MainApp(QMainWindow,ui): if(self.zoomcount>0): for i in range(self.zoomcount): self.zoomout() - elif(self.zoomcount<0): + elif(self.zoomcount<0): for i in range(abs(self.zoomcount)): self.zoomin() |