OpenStructure
init_iplt.py
Go to the documentation of this file.
1 from ost import gui
2 import sip
3 from ost.img import *
4 import ost.img.alg as alg
5 
6 from PyQt4 import QtGui, QtCore
7 from ost.gui.init_menubar import _InitMenuBar
8 
9 
10 def Viewer(image,title=""):
11  app=gui.GostyApp.Instance()
12  viewer=app.CreateDataViewer(image)
13  app.perspective.main_area.AddWidget(title, viewer)
14  return viewer
15 
16 def _InitPanels(app, panels):
17  panels.AddWidgetToPool('ost.gui.PythonShell', 1)
18  if not panels.Restore("img/ui/perspective/panels"):
19  panels.AddWidget(gui.PanelPosition.BOTTOM_PANEL, app.py_shell)
20 
21 def _InitIPLTNextGen():
22  app=gui.GostyApp.Instance()
23  app.SetAppTitle("IPLT - Iplt Next Generation")
24  main_area=app.perspective.main_area
25  _InitPanels(app, app.perspective.panels)
26  _InitMenuBar(app.perspective.GetMenuBar())
27  app.perspective.Restore()
28 
29 _InitIPLTNextGen()