Пример #1
0
def main():
    if '-h' in sys.argv:
        print "See https://earthref.org/PmagPy/cookbook/#pmag_gui.py for a complete tutorial"
        sys.exit()
    from programs import pmag_gui
    from pmagpy import pmag
    print '-I- Starting Pmag GUI 3 - please be patient'
    # if redirect is true, wxpython makes its own output window for stdout/stderr
    app = wx.App(redirect=True)
    app.frame = pmag_gui.MagMainFrame(DM=3)
    working_dir = pmag.get_named_arg_from_sys('-WD', '.')
    ## this causes an error with Canopy Python
    ## (it works with brew Python)
    ## need to use these lines for Py2app
    if working_dir == '.':
        app.frame.on_change_dir_button(None)

    app.frame.Show()
    app.frame.Center()
    ## use for debugging:
    #if '-i' in sys.argv:
    #    import wx.lib.inspection
    #    wx.lib.inspection.InspectionTool().Show()
    app.MainLoop()
Пример #2
0
 def setUp(self):
     self.app = wx.App()
     self.frame = pmag_gui.MagMainFrame(PROJECT_WD, DM=3, dmodel=DMODEL)
     self.frame.get_wd_data()
     self.pnl = self.frame.GetChildren()[0]
Пример #3
0
 def setUp(self):
     self.app = wx.App()
     self.frame = pmag_gui.MagMainFrame(project2_WD, dmodel=dmodel2, DM=2.5)
     self.pnl = self.frame.GetChildren()[0]
Пример #4
0
 def setUp(self):
     self.app = wx.App()
     self.frame = pmag_gui.MagMainFrame(core_depthplot_WD)
     self.pnl = self.frame.GetChildren()[0]
     self.core_window = pmag_menu_dialogs.core_depthplot(
         self.frame, self.frame.WD)