def __init__(self, json_str, runner, master=None):
    j = json.loads(json_str)
    self.name = j['name']
    self.description = j['description']
    self.flag = j['flags'][(len(j['flags']) - 1)]
    self.parameter_type = j['parameter_type']
    self.file_type = ''
    if ('ExistingFile' in self.parameter_type):
        self.file_type = j['parameter_type']['ExistingFile']
    elif ('NewFile' in self.parameter_type):
        self.file_type = j['parameter_type']['NewFile']
    self.optional = j['optional']
    default_value = j['default_value']
    self.runner = runner
    ttk.Frame.__init__(self, master, padding='0.02i')
    self.grid()
    self.label = ttk.Label(self, text=self.name, justify=tk.LEFT)
    self.label.grid(row=0, column=0, sticky=tk.W)
    self.label.columnconfigure(0, weight=1)
    if (not self.optional):
        self.label['text'] = (self.label['text'] + '*')
    fs_frame = ttk.Frame(self, padding='0.0i')
    self.value = tk.StringVar()
    self.entry = ttk.Entry(fs_frame, width=45, justify=tk.LEFT, textvariable=self.value)
    self.entry.grid(row=0, column=0, sticky=tk.NSEW)
    self.entry.columnconfigure(0, weight=1)
    if default_value:
        self.value.set(default_value)
    self.open_button = ttk.Button(fs_frame, width=4, text='...', command=self.select_file, padding='0.02i')
    self.open_button.grid(row=0, column=1, sticky=tk.E)
    self.open_button.columnconfigure(0, weight=1)
    fs_frame.grid(row=1, column=0, sticky=tk.NSEW)
    fs_frame.columnconfigure(0, weight=10)
    fs_frame.columnconfigure(1, weight=1)
    self.columnconfigure(0, weight=1)
    self.rowconfigure(0, weight=1)
    self.rowconfigure(1, weight=1)
    if (_platform == 'darwin'):
        self.entry.bind('<Command-Key-a>', self.select_all)
    else:
        self.entry.bind('<Control-Key-a>', self.select_all)
def __init__(self, json_str, runner, master=None):
    j = json.loads(json_str)
    self.name = j['name']
    self.description = j['description']
    self.flag = j['flags'][(len(j['flags']) - 1)]
    self.parameter_type = j['parameter_type']
    self.file_type = 
    if ('ExistingFile' in self.parameter_type):
        self.file_type = j['parameter_type']['ExistingFile']
    elif ('NewFile' in self.parameter_type):
        self.file_type = j['parameter_type']['NewFile']
    self.optional = j['optional']
    default_value = j['default_value']
    self.runner = runner
    ttk.Frame.__init__(self, master, padding='0.02i')
    self.grid()
    self.label = ttk.Label(self, text=self.name, justify=tk.LEFT)
    self.label.grid(row=0, column=0, sticky=tk.W)
    self.label.columnconfigure(0, weight=1)
    if (not self.optional):
        self.label['text'] = (self.label['text'] + '*')
    fs_frame = ttk.Frame(self, padding='0.0i')
    self.value = tk.StringVar()
    self.entry = ttk.Entry(fs_frame, width=45, justify=tk.LEFT, textvariable=self.value)
    self.entry.grid(row=0, column=0, sticky=tk.NSEW)
    self.entry.columnconfigure(0, weight=1)
    if default_value:
        self.value.set(default_value)
    self.open_button = ttk.Button(fs_frame, width=4, text='...', command=self.select_file, padding='0.02i')
    self.open_button.grid(row=0, column=1, sticky=tk.E)
    self.open_button.columnconfigure(0, weight=1)
    fs_frame.grid(row=1, column=0, sticky=tk.NSEW)
    fs_frame.columnconfigure(0, weight=10)
    fs_frame.columnconfigure(1, weight=1)
    self.columnconfigure(0, weight=1)
    self.rowconfigure(0, weight=1)
    self.rowconfigure(1, weight=1)
    if (_platform == 'darwin'):
        self.entry.bind('<Command-Key-a>', self.select_all)
    else:
        self.entry.bind('<Control-Key-a>', self.select_all)