def menuViewsSave_Click(self, event): # Find the specified view in the views list for view in Global.views: if view.menu == self.selectedViewMenu: view.showBitsNone = self.menuShowBitsNone.isChecked() view.showBitsActive = self.menuShowBitsActive.isChecked() view.showBitsPredicted = self.menuShowBitsPredicted.isChecked() view.showCellsNone = self.menuShowCellsNone.isChecked() view.showCellsLearning = self.menuShowCellsLearning.isChecked() view.showCellsActive = self.menuShowCellsActive.isChecked() view.showCellsPredicted = self.menuShowCellsPredicted.isChecked() view.showProximalSegmentsNone = self.menuShowProximalSegmentsNone.isChecked() view.showProximalSegmentsActive = self.menuShowProximalSegmentsActive.isChecked() view.showProximalSegmentsPredicted = self.menuShowProximalSegmentsPredicted.isChecked() view.showProximalSynapsesNone = self.menuShowProximalSynapsesNone.isChecked() view.showProximalSynapsesConnected = self.menuShowProximalSynapsesConnected.isChecked() view.showProximalSynapsesActive = self.menuShowProximalSynapsesActive.isChecked() view.showProximalSynapsesPredicted = self.menuShowProximalSynapsesPredicted.isChecked() view.showDistalSegmentsNone = self.menuShowDistalSegmentsNone.isChecked() view.showDistalSegmentsActive = self.menuShowDistalSegmentsActive.isChecked() view.showDistalSynapsesNone = self.menuShowDistalSynapsesNone.isChecked() view.showDistalSynapsesConnected = self.menuShowDistalSynapsesConnected.isChecked() view.showDistalSynapsesActive = self.menuShowDistalSynapsesActive.isChecked() Global.saveConfig() break
def main(): app = QtGui.QApplication(sys.argv) app.setStyleSheet("QGroupBox { border: 1px solid gray; }") Global.appPath = os.path.abspath(os.path.join(__file__, '..')) Global.loadConfig() Global.project = Project() Global.simulationForm = SimulationForm() Global.nodeSelectorForm = NodeSelectorForm() Global.nodeInformationForm = NodeInformationForm() Global.outputForm = OutputForm() Global.mainForm = MainForm() # Create and display the splash screen start = time.time() splash_pix = QtGui.QPixmap(Global.appPath + '/images/splash.png') splash = QtGui.QSplashScreen(splash_pix, QtCore.Qt.WindowStaysOnTopHint) splash.setMask(splash_pix.mask()) splash.show() while time.time() - start < 3: time.sleep(0.001) app.processEvents() splash.close() # Show start form startForm = StartForm() startForm.show() sys.exit(app.exec_())
def menuViewsSave_Click(self, event): # Find the specified view in the views list for view in Global.views: if view.menu == self.selectedViewMenu: view.showBitsNone = self.menuShowBitsNone.isChecked() view.showBitsActive = self.menuShowBitsActive.isChecked() view.showBitsPredicted = self.menuShowBitsPredicted.isChecked() view.showCellsNone = self.menuShowCellsNone.isChecked() view.showCellsLearning = self.menuShowCellsLearning.isChecked() view.showCellsActive = self.menuShowCellsActive.isChecked() view.showCellsPredicted = self.menuShowCellsPredicted.isChecked( ) view.showProximalSegmentsNone = self.menuShowProximalSegmentsNone.isChecked( ) view.showProximalSegmentsActive = self.menuShowProximalSegmentsActive.isChecked( ) view.showProximalSegmentsPredicted = self.menuShowProximalSegmentsPredicted.isChecked( ) view.showProximalSynapsesNone = self.menuShowProximalSynapsesNone.isChecked( ) view.showProximalSynapsesConnected = self.menuShowProximalSynapsesConnected.isChecked( ) view.showProximalSynapsesActive = self.menuShowProximalSynapsesActive.isChecked( ) view.showProximalSynapsesPredicted = self.menuShowProximalSynapsesPredicted.isChecked( ) view.showDistalSegmentsNone = self.menuShowDistalSegmentsNone.isChecked( ) view.showDistalSegmentsActive = self.menuShowDistalSegmentsActive.isChecked( ) view.showDistalSynapsesNone = self.menuShowDistalSynapsesNone.isChecked( ) view.showDistalSynapsesConnected = self.menuShowDistalSynapsesConnected.isChecked( ) view.showDistalSynapsesActive = self.menuShowDistalSynapsesActive.isChecked( ) Global.saveConfig() break