Skip to content

Commit

Permalink
Demo ability to go directly to pre-defined "views". This optimizer-on…
Browse files Browse the repository at this point in the history
…ly view for Confocal completely obsoletes the separate optimizer gui module.
  • Loading branch information
latchr committed Jul 6, 2015
1 parent de47d58 commit 44b7b8d
Show file tree
Hide file tree
Showing 3 changed files with 941 additions and 899 deletions.
18 changes: 18 additions & 0 deletions gui/confocal/confocalgui.py
Original file line number Diff line number Diff line change
Expand Up @@ -450,6 +450,7 @@ def initMainUI(self, e=None):

# Connect the default view action
self._mw.restore_default_view_Action.triggered.connect(self.restore_default_view)
self._mw.optimizer_only_view_Action.triggered.connect(self.small_optimizer_view)



Expand Down Expand Up @@ -1559,3 +1560,20 @@ def restore_default_view(self):
self._mw.addDockWidget(QtCore.Qt.DockWidgetArea(2), self._mw.depth_scan_dockWidget)
self._mw.addDockWidget(QtCore.Qt.DockWidgetArea(2), self._mw.optimizer_dockWidget)

# Resize window to default size
self._mw.resize(1255, 939)

def small_optimizer_view(self):
""" Rearrange the DockWidgets to produce a small optimizer interface
"""
# Hide the other dock widgets
self._mw.xy_scan_dockWidget.hide()
self._mw.scan_control_dockWidget.hide()
self._mw.depth_scan_dockWidget.hide()

# Show the optimizer dock widget, and re-dock
self._mw.optimizer_dockWidget.show()
self._mw.optimizer_dockWidget.setFloating(False)

# Resize the window to small dimensions
self._mw.resize(1000, 360)
Loading

0 comments on commit 44b7b8d

Please sign in to comment.