#!/usr/bin/env python # # make_png_camm # .png to .camm GUI wrapper # # Neil Gershenfeld # CBA MIT 2/19/11 # # (c) Massachusetts Institute of Technology 2011 # Permission granted for experimental and personal use; # license for commercial sale available from MIT. # # imports # import wx,sys from fab_set import fab_frame from panel_control import control_panel from panel_png import png_panel from panel_png_path import png_path_panel from panel_path_camm import path_camm_panel # # command line # print "command line: make_png_camm [input_file [size]]" print " input_file = input .camm file (optional)" print " size = image panel size (optional)" # # start wx # app = wx.App() # # add panels to frame # frame = fab_frame("make_png_camm",sys.argv) frame.control_panel = control_panel(frame) frame.sizer.Add(frame.control_panel,(0,0),span=(1,3),flag=wx.ALIGN_CENTER_HORIZONTAL) frame.camm_panel = path_camm_panel(frame) frame.sizer.Add(frame.camm_panel,(1,2)) frame.png_path_panel = png_path_panel(frame) frame.sizer.Add(frame.png_path_panel,(1,1)) frame.png_panel = png_panel(frame) frame.sizer.Add(frame.png_panel,(1,0)) # # defaults # frame.set_png_camm() # # fit and show frame # frame.Fit() frame.Show() # # start mainloop # app.MainLoop()