def get_workflow_select_item(self, item_number, workflow_name, item_text): name = Gtk.Label(workflow_name) name.set_use_markup(True) guiutils.set_margins(name, 0, 8, 0, 0) label = Gtk.Label(item_text) label.set_use_markup(True) label.set_justify(Gtk.Justification.CENTER) item_vbox = Gtk.VBox(False, 2) item_vbox.pack_start(guiutils.get_centered_box([name]), False, False, 0) item_vbox.pack_start(guiutils.get_centered_box([label]), False, False, 0) guiutils.set_margins(item_vbox, 12, 18, 12, 12) widget = Gtk.EventBox() widget.connect("button-press-event", lambda w, e: self.selected_callback(w, item_number)) widget.set_can_focus(True) widget.add_events(Gdk.EventMask.KEY_PRESS_MASK) widget.add(item_vbox) widget.item_number = item_number self.set_item_color(widget) return widget
def get_workflow_select_item(self, item_number, workflow_name, item_text): name = Gtk.Label(workflow_name) name.set_use_markup(True) guiutils.set_margins(name, 0, 8, 0, 0) label = Gtk.Label(item_text) label.set_use_markup(True) label.set_justify(Gtk.Justification.CENTER) item_vbox = Gtk.VBox(False, 2) item_vbox.pack_start(guiutils.get_centered_box([name]), False, False, 0) item_vbox.pack_start(guiutils.get_centered_box([label]), False, False, 0) guiutils.set_margins(item_vbox, 12, 18, 12, 12) widget = Gtk.EventBox() widget.connect("button-press-event", lambda w,e: self.selected_callback(w, item_number)) #widget.connect("button-release-event", lambda w,e: release_callback(self, w, e)) widget.set_can_focus(True) widget.add_events(Gdk.EventMask.KEY_PRESS_MASK) widget.add(item_vbox) widget.item_number = item_number self.set_item_color(widget) return widget
def launch_phantom(): respaths.PHANTOM_JAR if _phantom_found == False: info_row = guiutils.get_centered_box([Gtk.Label(_("Phantom2D tool has not been installed on your system."))]) link_info_row = guiutils.get_centered_box([Gtk.Label(_("Install instructions:"))]) link = Gtk.LinkButton.new("https://github.com/jliljebl/phantom2D") link_row = guiutils.get_centered_box([link]) dir_info_row = guiutils.get_centered_box([Gtk.Label(_("Install directory for Phantom2D tool:"))]) dir_label = Gtk.Label(respaths.PHANTOM_JAR.rstrip("/Phantom2D.jar")) dir_label.set_selectable(True) dir_row = guiutils.get_centered_box([Gtk.Label(respaths.PHANTOM_JAR.rstrip("/Phantom2D.jar"))]) dir_row.set_margin_top(8) panel = Gtk.VBox() panel.pack_start(info_row, False, False, 0) panel.pack_start(guiutils.pad_label(12, 24), False, False, 0) panel.pack_start(link_info_row, False, False, 0) panel.pack_start(link_row, False, False, 0) panel.pack_start(guiutils.pad_label(12, 24), False, False, 0) panel.pack_start(dir_info_row, False, False, 0) panel.pack_start(dir_row, False, False, 0) dialogutils.panel_ok_dialog(_("Phantom2D not found"), panel) return FLOG = open(userfolders.get_cache_dir() + "log_phantom", 'w') subprocess.Popen([str(respaths.LAUNCH_DIR + "flowbladephantom") + " " + str(respaths.PHANTOM_JAR) \ + " profile" + " " + _get_underscored_profile() \ + " cachefolder " + userfolders.get_cache_dir() + appconsts.PHANTOM_DIR + "/" + appconsts.PHANTOM_DISK_CACHE_DIR], shell=True, stdin=FLOG, stdout=FLOG, stderr=FLOG) print "Phantom2D launched"
def _check_transition_handles(from_req, from_handle, to_req, to_handle, length): if from_req > from_handle or to_req > to_handle: SPACE_TAB = " " info_text = _( "To create a rendered transition you need enough media overlap from both clips!\n\n" ) first_clip_info = None if from_req > from_handle: first_clip_info = \ _("<b>FIRST CLIP MEDIA OVERLAP:</b> ") + \ SPACE_TAB + _("Available <b>") + str(from_handle) + _("</b> frame(s), " ) + \ SPACE_TAB + _("Required <b>") + str(from_req) + _("</b> frame(s)") second_clip_info = None if to_req > to_handle: second_clip_info = \ _("<b>SECOND CLIP MEDIA OVERLAP:</b> ") + \ SPACE_TAB + _("Available <b>") + str(to_handle) + _("</b> frame(s), ") + \ SPACE_TAB + _("Required <b>") + str(to_req) + _("</b> frame(s) ") img = Gtk.Image.new_from_file( (respaths.IMAGE_PATH + "transition_wrong.png")) img2 = Gtk.Image.new_from_file( (respaths.IMAGE_PATH + "transition_right.png")) img2.set_margin_bottom(24) label1 = Gtk.Label(_("Current situation, not enought media overlap:")) label1.set_margin_bottom(12) label2 = Gtk.Label(_("You need more media overlap:")) label2.set_margin_bottom(12) label2.set_margin_top(24) label3 = Gtk.Label(info_text) label3.set_use_markup(True) if first_clip_info != None: label4 = Gtk.Label(first_clip_info) label4.set_use_markup(True) if second_clip_info != None: label5 = Gtk.Label(second_clip_info) label5.set_use_markup(True) row1 = guiutils.get_centered_box([label1]) row2 = guiutils.get_centered_box([img]) row3 = guiutils.get_centered_box([label2]) row4 = guiutils.get_centered_box([img2]) row5 = guiutils.get_centered_box([label3]) rows = [row1, row2, row3, row4] if first_clip_info != None: row6 = guiutils.get_left_justified_box([label4]) rows.append(row6) if second_clip_info != None: row7 = guiutils.get_left_justified_box([label5]) rows.append(row7) dialogutils.warning_message_with_panels( _("More media overlap needed to create transition!"), "", gui.editor_window.window, True, dialogutils.dialog_destroy, rows) return False return True
def __init__(self): Gtk.Dialog.__init__( self, _("Workflow First Run Wizard"), gui.editor_window.window, Gtk.DialogFlags.MODAL | Gtk.DialogFlags.DESTROY_WITH_PARENT, (_("Select Preset Workflow and Continue"), Gtk.ResponseType.ACCEPT)) self.selection = STANDARD_PRESET info_label_text_1 = _("<b>Welcome to Flowblade 2.4</b>") info_label_1 = Gtk.Label(info_label_text_1) info_label_1.set_use_markup(True) info_label_text_2 = _( "<b>Flowblade 2.4</b> comes with a configurable workflow.") info_label_2 = Gtk.Label(info_label_text_2) info_label_2.set_use_markup(True) INDENT = " " info_label_text_6 = INDENT + "\u2022" + _(" You can select which <b>tools</b> you want to use.\n") + \ INDENT + "\u2022" + _(" Many timeline edit <b>behaviours</b> are configurable.\n") info_label_6 = Gtk.Label(info_label_text_6) info_label_6.set_use_markup(True) info_label_text_3 = _("<b>Select Workflow Preset</b>") info_label_3 = Gtk.Label(info_label_text_3) info_label_3.set_use_markup(True) guiutils.set_margins(info_label_3, 0, 4, 0, 0) info_label_text_7 = _( "You can change and configure individual tools and behaviours <b>anytime</b>" ) info_label_7 = Gtk.Label(info_label_text_7) info_label_7.set_use_markup(True) info_label_text_4 = _(" by pressing ") info_label_4 = Gtk.Label(info_label_text_4) info_label_4.set_use_markup(True) icon = Gtk.Image.new_from_file(respaths.IMAGE_PATH + "workflow.png") info_label_text_5 = _(" icon.") info_label_5 = Gtk.Label(info_label_text_5) workflow_name = _("<b>Standard</b>") stadard_preset_workflow_text_1 = _( "Standard workflow has the <b>Move</b> tool as default tool\nand presents a workflow\nsimilar to most video editors." ) workflow_select_item_1 = self.get_workflow_select_item( STANDARD_PRESET, workflow_name, stadard_preset_workflow_text_1) workflow_name = _("<b>Film Style</b>") filmstyle_preset_workflow_text_2 = _( "Film Style workflow has the <b>Insert</b> tool as default tool\nand employs insert style editing.\nThis was the workflow in previous versions of the application." ) workflow_select_item_2 = self.get_workflow_select_item( FILM_STYLE_PRESET, workflow_name, filmstyle_preset_workflow_text_2) workflow_name = _("<b>Keep Existing Worflow</b>") keep_workflow_text_2 = _( "Select this if you have installed new version and wish to keep your existing workflow." ) workflow_select_item_3 = self.get_workflow_select_item( KEEP_EXISTING, workflow_name, keep_workflow_text_2) self.workflow_items = [ workflow_select_item_1, workflow_select_item_2, workflow_select_item_3 ] panel_vbox = Gtk.VBox(False, 2) panel_vbox.pack_start(guiutils.get_pad_label(24, 12), False, False, 0) panel_vbox.pack_start(guiutils.get_centered_box([info_label_1]), False, False, 0) panel_vbox.pack_start(guiutils.get_pad_label(24, 12), False, False, 0) panel_vbox.pack_start(guiutils.get_left_justified_box([info_label_2]), False, False, 0) panel_vbox.pack_start(guiutils.get_left_justified_box([info_label_6]), False, False, 0) panel_vbox.pack_start(guiutils.get_pad_label(24, 24), False, False, 0) panel_vbox.pack_start(guiutils.get_centered_box([info_label_3]), False, False, 0) panel_vbox.pack_start(workflow_select_item_1, False, False, 0) panel_vbox.pack_start(workflow_select_item_2, False, False, 0) panel_vbox.pack_start(workflow_select_item_3, False, False, 0) panel_vbox.pack_start(guiutils.get_pad_label(24, 48), False, False, 0) panel_vbox.pack_start(guiutils.get_centered_box([info_label_7]), False, False, 0) panel_vbox.pack_start( guiutils.get_centered_box([info_label_4, icon, info_label_5]), False, False, 0) panel_vbox.pack_start(guiutils.get_pad_label(24, 24), False, False, 0) alignment = dialogutils.get_alignment2(panel_vbox) self.vbox.pack_start(alignment, True, True, 0) dialogutils.set_outer_margins(self.vbox) dialogs._default_behaviour(self) self.connect('response', self.done) self.show_all()
def __init__(self): self.dialog = Gtk.Dialog( _("JACK Audio Manager"), None, Gtk.DialogFlags.MODAL | Gtk.DialogFlags.DESTROY_WITH_PARENT, (_("Close").encode('utf-8'), Gtk.ResponseType.CLOSE)) start_up_label = Gtk.Label( label=_("Start JACK output on application start-up")) self.startup_check_button = Gtk.CheckButton() if editorpersistance.prefs.jack_start_up_op == appconsts.JACK_ON_START_UP_YES: self.startup_check_button.set_active(True) self.startup_check_button.connect("toggled", lambda w, e: start_op_changed(w), None) start_row = guiutils.get_checkbox_row_box(self.startup_check_button, start_up_label) self.frequency_select = Gtk.ComboBoxText() cur_value_index = 0 count = 0 for freq in _jack_frequencies: self.frequency_select.append_text(str(freq)) if freq == editorpersistance.prefs.jack_frequency: cur_value_index = count count = count + 1 self.frequency_select.set_active(cur_value_index) self.frequency_select.connect( "changed", lambda w, e: frequency_changed(w.get_active()), None) freq_row = guiutils.get_two_column_box_right_pad( Gtk.Label(label="JACK frequency Hz:"), self.frequency_select, 190, 15) self.output_type_select = Gtk.ComboBoxText() self.output_type_select.append_text(_("Audio")) self.output_type_select.append_text(_("Sync Master Timecode")) # Indexes correspond with appconsts.JACK_OUT_AUDIO, appconsts.JACK_OUT_SYNC values self.output_type_select.set_active( editorpersistance.prefs.jack_output_type) self.output_type_select.connect( "changed", lambda w, e: output_type_changed(w.get_active()), None) output_row = guiutils.get_two_column_box_right_pad( Gtk.Label(label="JACK output type:"), self.output_type_select, 190, 15) vbox_props = Gtk.VBox(False, 2) vbox_props.pack_start(freq_row, False, False, 0) vbox_props.pack_start(output_row, False, False, 0) vbox_props.pack_start(start_row, False, False, 0) vbox_props.pack_start(guiutils.pad_label(8, 12), False, False, 0) props_frame = guiutils.get_named_frame(_("Properties"), vbox_props) self.jack_output_status_value = Gtk.Label(label="<b>OFF</b>") self.jack_output_status_value.set_use_markup(True) self.jack_output_status_label = Gtk.Label(label="JACK output is ") status_row = guiutils.get_centered_box( [self.jack_output_status_label, self.jack_output_status_value]) self.dont_use_button = Gtk.Button(_("Stop JACK Output")) self.use_button = Gtk.Button(_("Start JACK Output")) self.use_button.connect("clicked", lambda w: use_jack_clicked(self)) self.dont_use_button.connect( "clicked", lambda w: _convert_to_original_media_project()) self.set_gui_state() c_box_2 = Gtk.HBox(True, 8) c_box_2.pack_start(self.dont_use_button, True, True, 0) c_box_2.pack_start(self.use_button, True, True, 0) row2_onoff = Gtk.HBox(False, 2) row2_onoff.pack_start(Gtk.Label(), True, True, 0) row2_onoff.pack_start(c_box_2, False, False, 0) row2_onoff.pack_start(Gtk.Label(), True, True, 0) vbox_onoff = Gtk.VBox(False, 2) vbox_onoff.pack_start(guiutils.pad_label(12, 4), False, False, 0) vbox_onoff.pack_start(status_row, False, False, 0) vbox_onoff.pack_start(guiutils.pad_label(12, 12), False, False, 0) vbox_onoff.pack_start(row2_onoff, False, False, 0) onoff_frame = guiutils.get_named_frame(_("Output Status"), vbox_onoff) # Pane vbox = Gtk.VBox(False, 2) vbox.pack_start(props_frame, False, False, 0) vbox.pack_start(onoff_frame, False, False, 0) alignment = Gtk.Alignment.new(0.5, 0.5, 1.0, 1.0) alignment.set_padding(12, 12, 12, 12) alignment.add(vbox) self.dialog.vbox.pack_start(alignment, True, True, 0) dialogutils.default_behaviour(self.dialog) self.dialog.connect('response', dialogutils.dialog_destroy) self.dialog.show_all() global _dialog _dialog = self
def __init__(self): Gtk.Dialog.__init__(self, _("Workflow First Run Wizard"), gui.editor_window.window, Gtk.DialogFlags.MODAL | Gtk.DialogFlags.DESTROY_WITH_PARENT, (_("Select Preset Workflow and Continue").encode('utf-8'), Gtk.ResponseType.ACCEPT)) self.selection = STANDARD_PRESET info_label_text_1 = _("<b>Welcome to Flowblade 2.0</b>") info_label_1 = Gtk.Label(info_label_text_1) info_label_1.set_use_markup(True) info_label_text_2 = _("<b>Flowblade 2.0</b> comes with a configurable workflow.") info_label_2 = Gtk.Label(info_label_text_2) info_label_2.set_use_markup(True) INDENT = " " info_label_text_6 = INDENT + u"\u2022" + _(" You can select which <b>tools</b> you want to use.\n") + \ INDENT + u"\u2022" + _(" Many timeline edit <b>behaviours</b> are configurable.\n") info_label_6 = Gtk.Label(info_label_text_6) info_label_6.set_use_markup(True) info_label_text_3 = _("<b>Select Workflow Preset</b>") info_label_3 = Gtk.Label(info_label_text_3) info_label_3.set_use_markup(True) guiutils.set_margins(info_label_3, 0, 4, 0, 0) info_label_text_7 = _("You can change and configure individual tools and behaviours <b>anytime</b>") info_label_7 = Gtk.Label(info_label_text_7) info_label_7.set_use_markup(True) info_label_text_4 = _(" by pressing ") info_label_4 = Gtk.Label(info_label_text_4) info_label_4.set_use_markup(True) icon = Gtk.Image.new_from_file(respaths.IMAGE_PATH + "workflow.png") info_label_text_5 = _(" icon.") info_label_5 = Gtk.Label(info_label_text_5) workflow_name = _("<b>Standard</b>") stadard_preset_workflow_text_1 = _("Standard workflow has the <b>Move</b> tool as default tool\nand presents a workflow\nsimilar to most video editors.") workflow_select_item_1 = self.get_workflow_select_item(STANDARD_PRESET, workflow_name, stadard_preset_workflow_text_1) workflow_name = _("<b>Film Style</b>") filmstyle_preset_workflow_text_2 = _("Film Style workflow has the <b>Insert</b> tool as default tool\nand employs insert style editing.\nThis was the workflow in previous versions of the application.") workflow_select_item_2 = self.get_workflow_select_item(FILM_STYLE_PRESET, workflow_name, filmstyle_preset_workflow_text_2) self.workflow_items = [workflow_select_item_1, workflow_select_item_2] panel_vbox = Gtk.VBox(False, 2) panel_vbox.pack_start(guiutils.get_pad_label(24, 12), False, False, 0) panel_vbox.pack_start(guiutils.get_centered_box([info_label_1]), False, False, 0) panel_vbox.pack_start(guiutils.get_pad_label(24, 12), False, False, 0) panel_vbox.pack_start(guiutils.get_left_justified_box([info_label_2]), False, False, 0) panel_vbox.pack_start(guiutils.get_left_justified_box([info_label_6]), False, False, 0) panel_vbox.pack_start(guiutils.get_pad_label(24, 24), False, False, 0) panel_vbox.pack_start(guiutils.get_centered_box([info_label_3]), False, False, 0) panel_vbox.pack_start(workflow_select_item_1, False, False, 0) panel_vbox.pack_start(workflow_select_item_2, False, False, 0) panel_vbox.pack_start(guiutils.get_pad_label(24, 48), False, False, 0) panel_vbox.pack_start(guiutils.get_centered_box([info_label_7]), False, False, 0) panel_vbox.pack_start(guiutils.get_centered_box([info_label_4, icon, info_label_5]), False, False, 0) panel_vbox.pack_start(guiutils.get_pad_label(24, 24), False, False, 0) alignment = dialogutils.get_alignment2(panel_vbox) self.vbox.pack_start(alignment, True, True, 0) dialogutils.set_outer_margins(self.vbox) dialogs._default_behaviour(self) self.connect('response', self.done) self.show_all()
def __init__(self): self.dialog = gtk.Dialog(_("JACK Audio Manager"), None, gtk.DIALOG_MODAL | gtk.DIALOG_DESTROY_WITH_PARENT, (_("Close").encode('utf-8'), gtk.RESPONSE_CLOSE)) start_up_label = gtk.Label(_("Start JACK output on application start-up")) self.startup_check_button = gtk.CheckButton() if editorpersistance.prefs.jack_start_up_op == appconsts.JACK_ON_START_UP_YES: self.startup_check_button.set_active(True) self.startup_check_button.connect("toggled", lambda w,e: start_op_changed(w), None) start_row = guiutils.get_checkbox_row_box(self.startup_check_button, start_up_label) self.frequency_select = gtk.combo_box_new_text() cur_value_index = 0 count = 0 for freq in _jack_frequencies: self.frequency_select.append_text(str(freq)) if freq == editorpersistance.prefs.jack_frequency: cur_value_index = count count = count + 1 self.frequency_select.set_active(cur_value_index) self.frequency_select.connect("changed", lambda w,e: frequency_changed(w.get_active()), None) freq_row = guiutils.get_two_column_box_right_pad(gtk.Label("JACK frequency Hz:"), self.frequency_select, 190, 15) self.output_type_select = gtk.combo_box_new_text() self.output_type_select.append_text(_("Audio")) self.output_type_select.append_text(_("Sync Master Timecode")) # Indexes correspond with appconsts.JACK_OUT_AUDIO, appconsts.JACK_OUT_SYNC values self.output_type_select.set_active(editorpersistance.prefs.jack_output_type) self.output_type_select.connect("changed", lambda w,e: output_type_changed(w.get_active()), None) output_row = guiutils.get_two_column_box_right_pad(gtk.Label("JACK output type:"), self.output_type_select, 190, 15) vbox_props = gtk.VBox(False, 2) vbox_props.pack_start(freq_row, False, False, 0) vbox_props.pack_start(output_row, False, False, 0) vbox_props.pack_start(start_row, False, False, 0) vbox_props.pack_start(guiutils.pad_label(8, 12), False, False, 0) props_frame = guiutils.get_named_frame(_("Properties"), vbox_props) self.jack_output_status_value = gtk.Label("<b>OFF</b>") self.jack_output_status_value.set_use_markup(True) self.jack_output_status_label = gtk.Label("JACK output is ") status_row = guiutils.get_centered_box([self.jack_output_status_label, self.jack_output_status_value]) self.dont_use_button = gtk.Button(_("Stop JACK Output")) self.use_button = gtk.Button(_("Start JACK Output")) self.use_button.connect("clicked", lambda w: use_jack_clicked(self)) self.dont_use_button.connect("clicked", lambda w: _convert_to_original_media_project()) self.set_gui_state() c_box_2 = gtk.HBox(True, 8) c_box_2.pack_start(self.dont_use_button, True, True, 0) c_box_2.pack_start(self.use_button, True, True, 0) row2_onoff = gtk.HBox(False, 2) row2_onoff.pack_start(gtk.Label(), True, True, 0) row2_onoff.pack_start(c_box_2, False, False, 0) row2_onoff.pack_start(gtk.Label(), True, True, 0) vbox_onoff = gtk.VBox(False, 2) vbox_onoff.pack_start(guiutils.pad_label(12, 4), False, False, 0) vbox_onoff.pack_start(status_row, False, False, 0) vbox_onoff.pack_start(guiutils.pad_label(12, 12), False, False, 0) vbox_onoff.pack_start(row2_onoff, False, False, 0) onoff_frame = guiutils.get_named_frame(_("Output Status"), vbox_onoff) # Pane vbox = gtk.VBox(False, 2) vbox.pack_start(props_frame, False, False, 0) vbox.pack_start(onoff_frame, False, False, 0) alignment = gtk.Alignment(0.5, 0.5, 1.0, 1.0) alignment.set_padding(12, 12, 12, 12) alignment.add(vbox) self.dialog.vbox.pack_start(alignment, True, True, 0) dialogutils.default_behaviour(self.dialog) self.dialog.connect('response', dialogutils.dialog_destroy) self.dialog.show_all() global _dialog _dialog = self
def __init__(self): GObject.GObject.__init__(self) self.set_modal(True) self.set_transient_for(gui.editor_window.window) self.set_title(_("Add Media Plugin")) self.connect("delete-event", lambda w, e:_close_window()) # categories_list is list of form [("category_name", [category_items]), ...] # with category_items list of form ["item_name", ...] self.plugin_select = guicomponents.CategoriesModelComboBoxWithData(_get_categories_list()) self.plugin_select.set_changed_callback(self._plugin_selection_changed) plugin_label = Gtk.Label(label=_("Media Plugin:")) plugin_select_row = guiutils.get_two_column_box(plugin_label, self.plugin_select.widget, 220) global MONITOR_HEIGHT MONITOR_HEIGHT = int(MONITOR_WIDTH * float(current_sequence().profile.display_aspect_den()) / float(current_sequence().profile.display_aspect_num())) self.screenshot_canvas = cairoarea.CairoDrawableArea2(MONITOR_WIDTH, MONITOR_HEIGHT, self._draw_screenshot) screenshot_row = guiutils.get_centered_box([self.screenshot_canvas ]) guiutils.set_margins(screenshot_row, 12, 12, 0, 0) self.frame_display = Gtk.Label(_("Clip Frame")) self.frame_display.set_margin_right(2) self.frame_select = Gtk.SpinButton.new_with_range (0, 200, 1) self.frame_select.set_value(0) self.preview_button = Gtk.Button(_("Preview")) self.preview_button.connect("clicked", lambda w: self._show_preview()) control_panel = Gtk.HBox(False, 2) control_panel.pack_start(self.frame_display, False, False, 0) control_panel.pack_start(self.frame_select, False, False, 0) control_panel.pack_start(Gtk.Label(), True, True, 0) control_panel.pack_start(self.preview_button, False, False, 0) guiutils.set_margins(control_panel, 0, 24, 0, 0) self.editors_box = Gtk.HBox(False, 0) self.editors_box.set_size_request(270, 185) self.import_select = Gtk.ComboBoxText() self.import_select.append_text(_("Add as Container Clip")) self.import_select.append_text(_("Add as Rendered Media")) self.import_select.set_active(0) self.import_select.connect("changed", lambda w: self._export_action_changed(w)) import_row = guiutils.get_left_justified_box([Gtk.Label(_("Import Action:")), guiutils.pad_label(12,12), self.import_select]) guiutils.set_margins(import_row,8,0,0,0) self.length_spin = Gtk.SpinButton.new_with_range (25, 100000, 1) self.length_spin.set_value(200) length_row = guiutils.get_left_justified_box([Gtk.Label(_("Plugin Media Length:")), guiutils.pad_label(12,12), self.length_spin]) self.encoding_button = Gtk.Button(_("Encode settings")) self.encoding_button.set_sensitive(False) self.encoding_button.connect("clicked", lambda w: self._set_encoding_button_pressed()) self.encoding_info = Gtk.Label() self.encoding_info.set_markup("<small>" + "Not set" + "</small>") self.encoding_info.set_max_width_chars(32) self.encoding_info.set_sensitive(False) encoding_row = guiutils.get_left_justified_box([self.encoding_button, guiutils.pad_label(12,12), self.encoding_info]) import_panel = Gtk.VBox(False, 2) import_panel.pack_start(length_row, False, False, 0) import_panel.pack_start(import_row, False, False, 0) import_panel.pack_start(encoding_row, False, False, 0) import_panel.pack_start(Gtk.Label(), True, True, 0) values_row = Gtk.HBox(True, 8) values_row.pack_start(self.editors_box, False, False, 0) values_row.pack_start(import_panel, False, False, 0) #values_row. close_button = guiutils.get_sized_button(_("Close"), 150, 32) close_button.connect("clicked", lambda w: _close_clicked()) self.add_button = guiutils.get_sized_button(_("Add Media Plugin"), 150, 32) self.add_button.connect("clicked", lambda w: _add_media_plugin()) #self.load_info_2 = Gtk.Label() buttons_row = Gtk.HBox(False, 0) #buttons_row.pack_start(self.load_info_2, False, False, 0) buttons_row.pack_start(Gtk.Label(), True, True, 0) buttons_row.pack_start(close_button, False, False, 0) buttons_row.pack_start(self.add_button, False, False, 0) guiutils.set_margins(buttons_row, 24, 0, 0, 0) vbox = Gtk.VBox(False, 2) vbox.pack_start(plugin_select_row, False, False, 0) vbox.pack_start(screenshot_row, False, False, 0) vbox.pack_start(control_panel, False, False, 0) vbox.pack_start(values_row, False, False, 0) vbox.pack_start(Gtk.Label(), True, True, 0) vbox.pack_start(buttons_row, False, False, 0) alignment = guiutils.set_margins(vbox, 8, 8, 12, 12) self.add(alignment) self.set_position(Gtk.WindowPosition.CENTER) self.show_all() self.plugin_select.set_selected(_plugins[0].name) self._display_current_render_data()