Merge lp:~nico-inattendu/luciole/bp_cinelerra_export into lp:luciole/0.8
- bp_cinelerra_export
- Merge into 0.8
Proposed by
NicoInattendu
Status: | Merged |
---|---|
Merged at revision: | not available |
Proposed branch: | lp:~nico-inattendu/luciole/bp_cinelerra_export |
Merge into: | lp:luciole/0.8 |
Prerequisite: | lp:~nico-inattendu/luciole/bp-libglade-to-gtkbuilder |
Diff against target: |
1159 lines (+967/-21) 12 files modified
Makefile (+20/-3) RELEASE (+19/-0) _version.py (+5/-10) lucioLib/gui/gui_controller.py (+12/-1) lucioLib/gui/luciole_export_tool_window.py (+183/-0) lucioLib/lucioExport/__init__.py (+1/-0) lucioLib/lucioExport/luciole_export_tool.py (+281/-0) lucioLib/luciole_controller.py (+12/-4) lucioLib/luciole_et.py (+60/-0) templates/cinelerra_template.xml (+104/-0) ui/export_file.glade (+254/-0) ui/luciole.glade (+16/-3) |
To merge this branch: | bzr merge lp:~nico-inattendu/luciole/bp_cinelerra_export |
Related bugs: | |
Related blueprints: |
Add export to cinelerra file format
(Medium)
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
NicoInattendu | Approve | ||
Review via email: mp+15734@code.launchpad.net |
Commit message
Description of the change
To post a comment you must log in.
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'Makefile' |
2 | --- Makefile 2009-12-07 07:25:24 +0000 |
3 | +++ Makefile 2009-12-07 07:25:24 +0000 |
4 | @@ -44,6 +44,8 @@ |
5 | SOURCE_DIR=./ |
6 | PREFIX ?= /usr |
7 | LIBDIR ?= /lib |
8 | +BASEDIR= `basename $(PWD)` |
9 | + |
10 | all: compile |
11 | @echo "Done" |
12 | @echo "Type: 'make install' now" |
13 | @@ -91,7 +93,7 @@ |
14 | install: make-install-dirs |
15 | install -m 644 $(CURDIR)/$(SOURCE_DIR)luciole.py $(DESTDIR)$(PREFIX)$(LIBDIR)/luciole |
16 | install -m 644 $(CURDIR)/$(SOURCE_DIR)_version.py $(DESTDIR)$(PREFIX)$(LIBDIR)/luciole |
17 | - install -m 644 $(CURDIR)/$(SOURCE_DIR)ui/luciole.glade $(DESTDIR)$(PREFIX)/share/luciole/ui |
18 | + install -m 644 $(CURDIR)/$(SOURCE_DIR)ui/*.glade $(DESTDIR)$(PREFIX)/share/luciole/ui |
19 | install -m 644 $(CURDIR)/$(SOURCE_DIR)images/*.png $(DESTDIR)$(PREFIX)/share/luciole/images |
20 | install -m 644 $(CURDIR)/$(SOURCE_DIR)sounds/*.ogg $(DESTDIR)$(PREFIX)/share/luciole/sounds |
21 | install -m 644 $(CURDIR)/$(SOURCE_DIR)lucioLib/*.py $(DESTDIR)$(PREFIX)$(LIBDIR)/luciole/lucioLib/ |
22 | @@ -127,8 +129,12 @@ |
23 | `echo $$f | sed "s|^po|$(DESTDIR)$(PREFIX)/share/luciole/po|"` ; \ |
24 | done |
25 | tarball: clean |
26 | - tar --exclude .bzr -czvf ../luciole.tar.gz ../luciole |
27 | + @echo "Creating debian $(BASEDIR).tar.gz archive in parent dir " |
28 | + @cd .. && tar --exclude .bzr --exclude .bzrignore -czf $(BASEDIR).tar.gz $(BASEDIR) |
29 | |
30 | +debian-orig: clean cleanbzr |
31 | + @echo "Creating debian $(BASEDIR).orig.tar.gz archive in parent dir" |
32 | + @cd .. && tar --exclude .bzr --exclude .bzrignore --exclude debian -czf $(BASEDIR).orig.tar.gz $(BASEDIR) |
33 | |
34 | uninstall: |
35 | rm -rf $(DESTDIR)$(PREFIX)/share/luciole |
36 | @@ -136,5 +142,16 @@ |
37 | rm -rf $(DESTDIR)$(PREFIX)/bin/luciole |
38 | rm -f $(DESTDIR)$(PREFIX)/share/applications/luciole.desktop |
39 | rm -f $(DESTDIR)$(PREFIX)/share/pixmaps/luciole.xpm |
40 | + |
41 | clean : |
42 | - find . -name "*.py[co]" -exec rm -f {} \; |
43 | + @echo "Removing temporary files" |
44 | + @find . -name "*.py[co]" -exec rm -f {} \; |
45 | + @find . -name "*~" -exec rm -f {} \; |
46 | + @find . -name "*.swp" -exec rm -f {} \; |
47 | + |
48 | +cleanbzr : |
49 | + rm -rf .bzr |
50 | + rm -f .bzrignore |
51 | + |
52 | + |
53 | + |
54 | |
55 | === modified file 'RELEASE' |
56 | --- RELEASE 2009-11-26 05:39:02 +0000 |
57 | +++ RELEASE 2009-12-07 07:25:24 +0000 |
58 | @@ -1,3 +1,22 @@ |
59 | +0.8.1_alpha1 Release : Thu, 03 Dec 2009 |
60 | +------------------------------------------------------------------------------- |
61 | +The Luciole team is proud to announce the release 0.8.1_alpha1 of luciole. |
62 | + |
63 | +This Release Version is a testing issue. It can not be considered as a final issue |
64 | +The goal of this version is to test the conversion from libglade to gtk builder and the export to cinelerra |
65 | + |
66 | +Warning the translations are not uptodate |
67 | + |
68 | +List of implemented blueprints : |
69 | +------------------------------ |
70 | +libglade-to-gtkbuilder : Replace Libglade by gtk.builder |
71 | +cinelerra-export : Add export to cinelerra file format |
72 | + |
73 | + |
74 | + |
75 | + |
76 | + |
77 | + |
78 | 0.7.4 Release : Thu, 26 Nov 2009 |
79 | ------------------------------------------------------------------------------- |
80 | The Luciole team is proud to announce the release 0.7.4 of luciole. |
81 | |
82 | === modified file '_version.py' |
83 | --- _version.py 2009-12-07 07:25:24 +0000 |
84 | +++ _version.py 2009-12-07 07:25:24 +0000 |
85 | @@ -4,17 +4,12 @@ |
86 | So don't edit it. :) |
87 | """ |
88 | |
89 | -<<<<<<< TREE |
90 | -version_info = {'branch_nick': u'luciole-0.7.4', |
91 | - 'build_date': '2009-11-26 09:27:13 +0400', |
92 | -======= |
93 | -version_info = {'branch_nick': u'bp-libglade-to-gtkbuilder', |
94 | - 'build_date': '2009-12-02 11:56:49 +0400', |
95 | ->>>>>>> MERGE-SOURCE |
96 | +version_info = {'branch_nick': u'bp_cinelerra_export', |
97 | + 'build_date': '2009-12-03 21:33:50 +0400', |
98 | 'clean': None, |
99 | - 'date': '2009-11-24 09:07:36 +0400', |
100 | - 'revision_id': 'nico@inattendu.org-20091124050736-eophoqby83atw8tq', |
101 | - 'revno': 34} |
102 | + 'date': '2009-12-03 12:11:32 +0400', |
103 | + 'revision_id': 'nico@inattendu.org-20091203081132-bifpk3e9t4fn23zp', |
104 | + 'revno': 37} |
105 | |
106 | revisions = {} |
107 | |
108 | |
109 | === modified file 'lucioLib/gui/gui_controller.py' |
110 | --- lucioLib/gui/gui_controller.py 2009-12-07 07:25:24 +0000 |
111 | +++ lucioLib/gui/gui_controller.py 2009-12-07 07:25:24 +0000 |
112 | @@ -36,7 +36,6 @@ |
113 | import time |
114 | import gc |
115 | |
116 | -from .. import luciole_exceptions as M_EXCEP |
117 | |
118 | import luciole_drawaera as GLD |
119 | import montage_tree as GMT |
120 | @@ -45,6 +44,8 @@ |
121 | import dialog as GDIALOG |
122 | import open_project as GOF |
123 | import luciole_export_window as GEXPORT |
124 | +import luciole_export_tool_window as GEXPORT_TOOL |
125 | + |
126 | import open_project_widget as GOPEN |
127 | import dialog_project_properties as GDIALOG_PROJ |
128 | import dialog_preferences as GPREF |
129 | @@ -245,6 +246,7 @@ |
130 | 'on_file_open_activate' : self.on_file_open_activate, |
131 | 'on_file_import_activate' : self.on_file_import_activate, |
132 | 'on_file_export_activate' : self.on_file_export_activate, |
133 | + 'on_file_export_tool_activate' :self.on_file_export_tool_activate, |
134 | 'on_file_quit_activate' : self.on_file_quit_activate, |
135 | 'on_file_close_activate' : self.on_file_close_activate, |
136 | 'on_view_project_activate' : self.on_view_project_activate, |
137 | @@ -539,6 +541,11 @@ |
138 | """ Display export window """ |
139 | self._exportObj.gui_export(project_data) |
140 | |
141 | + def export_tool_dialog(self,project_data) : |
142 | + """ Display export tool window """ |
143 | + X = GEXPORT_TOOL.dialog_export_file(project=project_data) |
144 | + X.run() |
145 | + |
146 | def update_play_button(self,is_active = False) : |
147 | """ |
148 | update pressed state and icon image for play pause |
149 | @@ -703,6 +710,10 @@ |
150 | """file export activate """ |
151 | self.ctrl_obj.export() |
152 | |
153 | + def on_file_export_tool_activate(self,widget): |
154 | + """file export activate """ |
155 | + self.ctrl_obj.export_tool() |
156 | + |
157 | def on_file_quit_activate(self,widget): |
158 | """ file quit actovated""" |
159 | self.ctrl_obj.quit() |
160 | |
161 | === added file 'lucioLib/gui/luciole_export_tool_window.py' |
162 | --- lucioLib/gui/luciole_export_tool_window.py 1970-01-01 00:00:00 +0000 |
163 | +++ lucioLib/gui/luciole_export_tool_window.py 2009-12-07 07:25:24 +0000 |
164 | @@ -0,0 +1,183 @@ |
165 | +#!/usr/bin/env python |
166 | +# -*- coding: utf-8 -*- |
167 | +# -*- Mode: Python -*- |
168 | +# vi:si:ai:et:sw=4:sts=4:ts=4 |
169 | +# |
170 | +# |
171 | +# Copyright Nicolas Bertrand (nico@inattendu.org), 2009 |
172 | +# |
173 | +# This file is part of Luciole. |
174 | +# |
175 | +# Luciole is free software: you can redistribute it and/or modify |
176 | +# it under the terms of the GNU General Public License as published by |
177 | +# the Free Software Foundation, either version 3 of the License, or |
178 | +# (at your option) any later version. |
179 | +# |
180 | +# Luciole is distributed in the hope that it will be useful, |
181 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
182 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
183 | +# GNU General Public License for more details. |
184 | +# |
185 | +# You should have received a copy of the GNU General Public License |
186 | +# along with Luciole. If not, see <http://www.gnu.org/licenses/>. |
187 | +# |
188 | +# |
189 | + |
190 | + |
191 | + |
192 | +# for i18n |
193 | +from gettext import gettext as _ |
194 | + |
195 | +import gtk |
196 | +import os.path |
197 | + |
198 | +from .. import lucioExport as LEF |
199 | +import dialog as G_DIALOG |
200 | + |
201 | +BASE_DIR = './' |
202 | + |
203 | +class SimpleBuilderApp(gtk.Builder): |
204 | + def __init__(self): |
205 | + self.GLADE_DIR = os.path.join(BASE_DIR,'ui') |
206 | + gtk.Builder.__init__(self) |
207 | + |
208 | + |
209 | + |
210 | + |
211 | +class dialog_export_file(SimpleBuilderApp): |
212 | + |
213 | + |
214 | + def __init__(self, path="export_file.glade", root="dialog_export_file", domain="", form=None, project=None, **kwargs): |
215 | + |
216 | + # set export template dir |
217 | + self.TEMPLATE_DIR = os.path.join(BASE_DIR,'templates') |
218 | + self.templates = dict() |
219 | + self.project=project |
220 | + self.templates = { |
221 | + "cinelerra" : os.path.join(self.TEMPLATE_DIR, "cinelerra_template.xml") , |
222 | + "pitivi" : os.path.join(self.TEMPLATE_DIR, "pitivi_template") , |
223 | + "kdenlive" : os.path.join(self.TEMPLATE_DIR, "kdenlive_template") , |
224 | + "openshot" : os.path.join(self.TEMPLATE_DIR, "openshot_template") } |
225 | + |
226 | + SimpleBuilderApp.__init__(self) |
227 | + self.add_from_file(os.path.join(self.GLADE_DIR,path)) |
228 | + self.connect_signals(self) |
229 | + |
230 | + self.window = self.get_object(root) |
231 | + # Default Export type |
232 | + self.export_type = "cinelerra" |
233 | + self.extension=".xml" |
234 | + print __file__ |
235 | + self.BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) |
236 | + print self.BASE_DIR |
237 | + # |
238 | + # widgets configuration |
239 | + # |
240 | + self._fn_widget = self.get_object("entry_fn") |
241 | + self._fn_widget.set_text("export.xml") |
242 | + |
243 | + initial_folder = os.path.expandvars('$HOME') |
244 | + self._filechooser = self.get_object("filechooserbutton1") |
245 | + self._filechooser.set_current_folder(initial_folder) |
246 | + |
247 | + self._status_bar_widget = self.get_object("statusbar1") |
248 | + #self._status_bar_widget_cid = self._status_bar_widget.get_context_id() |
249 | + self._status_bar_widget_cid = 1 |
250 | + msg = _("Select an application and a file name name for export") |
251 | + self._status_bar_widget.push(self._status_bar_widget_cid,msg) |
252 | + |
253 | + self.window.show() |
254 | + def on_dialog_export_file_destroy(self, widget, data=None): |
255 | + self.window.destroy() |
256 | + |
257 | + def on_dialog_export_file_close(self, widget, data=None): |
258 | + self.window.destroy() |
259 | + |
260 | + def on_dialog_export_file_response(self, widget, data=None): |
261 | + pass |
262 | + |
263 | + |
264 | + def on_filechooserbutton1_file_set(self, widget, data=None): |
265 | + self.export_folder = widget.get_filename() |
266 | + |
267 | + |
268 | + def on_radio_cine_toggled(self, widget, data=None): |
269 | + self.export_type ="cinelerra" |
270 | + self.extension=".xml" |
271 | + |
272 | + |
273 | + def on_radio_kdenlive_toggled(self, widget, data=None): |
274 | + self.export_type ="kdenlive" |
275 | + |
276 | + def on_radio_pitivi_toggled(self, widget, data=None): |
277 | + self.export_type ="pitivi" |
278 | + |
279 | + def on_radio_openshot_toggled(self, widget, data=None): |
280 | + self.export_type ="openshot" |
281 | + |
282 | + def on_entry_fn_activate(self, widget, data=None): |
283 | + print __file__,"DEBUG : on_entry_fn_activate",data |
284 | + self.filename = "filename" |
285 | + |
286 | + |
287 | + def make_export(self) : |
288 | + self._status_bar_widget.pop(self._status_bar_widget_cid) |
289 | + |
290 | + #get filename form entry object |
291 | + (self.filename, self.extension)=os.path.splitext(self._fn_widget.get_text()) |
292 | + |
293 | + # get folder |
294 | + self.export_folder = self._filechooser.get_filename() |
295 | + |
296 | + self.full_export_path = os.path.join(self.export_folder,self.filename+self.extension) |
297 | + print __file__," DEBUG :", self.full_export_path |
298 | + |
299 | + ForceExport = False # by default overide of export filename is not allowed |
300 | + |
301 | + if os.path.exists(self.full_export_path): |
302 | + # add message display |
303 | + msg =_("File %s already exists. Replace file ?") % self.full_export_path |
304 | + ForceExport = G_DIALOG.Dialog.QuestionMessage(self.window,msg) |
305 | + |
306 | + if ForceExport == True : |
307 | + if self.export_type == "cinelerra" : |
308 | + if self.extension == ".xml" : |
309 | + self.make_export_cinelerra() |
310 | + else : |
311 | + print "Not a valid extension" |
312 | + else : |
313 | + print "Nothing (yet !) to export" |
314 | + |
315 | + def make_export_cinelerra(self): |
316 | + |
317 | + X = LEF.luciole_export_tool_cinelerra( |
318 | + lcl_project = self.project, |
319 | + template= self.templates["cinelerra"], |
320 | + export_file = self.full_export_path) |
321 | + X.generate() |
322 | + |
323 | + msg = _("Export Done") |
324 | + self._status_bar_widget.push(self._status_bar_widget_cid,msg) |
325 | + |
326 | + |
327 | + def run(self) : |
328 | + exit_loop = False |
329 | + while (exit_loop == False) : |
330 | + response = self.window.run() #wait for a reponse |
331 | + if response == 2 : |
332 | + # export button |
333 | + self.make_export() |
334 | + else : |
335 | + # exit |
336 | + exit_loop = True |
337 | + |
338 | + self.window.destroy() |
339 | + |
340 | +def main(): |
341 | + |
342 | + frmExportVideo1 = dialog_export_file() |
343 | + |
344 | + frmExportVideo1.run() |
345 | + |
346 | +if __name__ == "__main__": |
347 | + main() |
348 | |
349 | === modified file 'lucioLib/lucioExport/__init__.py' |
350 | --- lucioLib/lucioExport/__init__.py 2009-03-08 18:06:41 +0000 |
351 | +++ lucioLib/lucioExport/__init__.py 2009-12-07 07:25:24 +0000 |
352 | @@ -23,3 +23,4 @@ |
353 | # |
354 | # |
355 | from luciole_export import * |
356 | +from luciole_export_tool import * |
357 | |
358 | === added file 'lucioLib/lucioExport/luciole_export_tool.py' |
359 | --- lucioLib/lucioExport/luciole_export_tool.py 1970-01-01 00:00:00 +0000 |
360 | +++ lucioLib/lucioExport/luciole_export_tool.py 2009-12-07 07:25:24 +0000 |
361 | @@ -0,0 +1,281 @@ |
362 | +#!/usr/bin/env python |
363 | +# -*- coding: utf-8 -*- |
364 | +# -*- Mode: Python -*- |
365 | +# vi:si:ai:et:sw=4:sts=4:ts=4 |
366 | +# |
367 | +# |
368 | +# Copyright Nicolas Bertrand (nico@inattendu.org), 2009 |
369 | +# |
370 | +# This file is part of Luciole. |
371 | +# |
372 | +# Luciole is free software: you can redistribute it and/or modify |
373 | +# it under the terms of the GNU General Public License as published by |
374 | +# the Free Software Foundation, either version 3 of the License, or |
375 | +# (at your option) any later version. |
376 | +# |
377 | +# Luciole is distributed in the hope that it will be useful, |
378 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
379 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
380 | +# GNU General Public License for more details. |
381 | +# |
382 | +# You should have received a copy of the GNU General Public License |
383 | +# along with Luciole. If not, see <http://www.gnu.org/licenses/>. |
384 | +# |
385 | +# |
386 | + |
387 | +# for i18n |
388 | +from gettext import gettext as _ |
389 | + |
390 | +import os.path |
391 | +from .. import luciole_et as LE |
392 | + |
393 | +from .. import luciole_exceptions as LEXCEP |
394 | +from .. import luciole_project as LPROJECT |
395 | +class luciole_export_tool(object) : |
396 | + """ |
397 | + :version: |
398 | + :author: |
399 | + """ |
400 | + |
401 | + |
402 | + """ |
403 | + ATTRIBUTES |
404 | + export_file : Path to file to export |
405 | + template : Path to template |
406 | + lcl_project : The luciole project a file or a dict |
407 | + _lcl_project_data : |
408 | + _export_template : File to update with export data |
409 | + _template_xml : |
410 | + """ |
411 | + |
412 | + |
413 | + |
414 | + def __init__(self, lcl_project = "./luciole_project.xml", template="./template.xml", export_file = "./export.xml"): |
415 | + """ |
416 | + @param lcl_project : Type de projet |
417 | + @param template : Path to template |
418 | + @param export_file : Path to export_file |
419 | + """ |
420 | + # |
421 | + # Atributes init |
422 | + # |
423 | + self.lcl_project = lcl_project |
424 | + self.template = template |
425 | + self.export_file = export_file |
426 | + self._lcl_project_data = {} |
427 | + self._lcl_project_data['resources_images'] = [] |
428 | + self._lcl_project_data['timelines_images'] = [] |
429 | + |
430 | + self._export_template = None |
431 | + self._template_xml = None |
432 | + |
433 | + if (type(lcl_project) == str) : |
434 | + # test file type |
435 | + if os.path.exists(lcl_project) : |
436 | + #filetype exits load it |
437 | + self.__load_lcl_file() |
438 | + else : |
439 | + #Raise Error |
440 | + excep_message = "%s is ot a file",lcl_project |
441 | + raise LEXCEP.LucioException,excep_message |
442 | + elif (type(lcl_project) == LPROJECT.project_dico) : |
443 | + # input is a dictionary |
444 | + self.__load_lcl_dict() |
445 | + else : |
446 | + # template does not exists : raise an exception |
447 | + excep_message = "Invalid projetc type nor file nor luciole_project" |
448 | + raise LEXCEP.LucioException,excep_message |
449 | + |
450 | + # |
451 | + # Test template |
452 | + # |
453 | + if os.path.exists(self.template) : |
454 | + self._load_template() |
455 | + else : |
456 | + # template does not exists : raise an exception |
457 | + excep_message = " Template file %s does not exist"%self.template |
458 | + raise LEXCEP.LucioException,excep_message |
459 | + |
460 | + |
461 | + |
462 | + |
463 | + def generate(self): |
464 | + """ |
465 | + |
466 | + |
467 | + @return : |
468 | + @author |
469 | + """ |
470 | + self._gen_ressources() |
471 | + self._gen_timeline() |
472 | + self.__write_export_file() |
473 | + |
474 | + def _load_template(self): |
475 | + """ |
476 | + |
477 | + |
478 | + @return : |
479 | + @author |
480 | + """ |
481 | + pass |
482 | + |
483 | + def _gen_ressources(self): |
484 | + """ |
485 | + generate date for resources |
486 | + |
487 | + @return : |
488 | + @author |
489 | + """ |
490 | + pass |
491 | + |
492 | + def _gen_timeline(self): |
493 | + """ |
494 | + Generate data for timeline |
495 | + |
496 | + @return : |
497 | + @author |
498 | + """ |
499 | + pass |
500 | + |
501 | + def __load_lcl_file(self): |
502 | + """ |
503 | + Load a Luciole project from a file dictionary |
504 | + |
505 | + @return : |
506 | + @author |
507 | + """ |
508 | + try : |
509 | + _lcl_project_xml = LE.lcl_et(self.lcl_project) |
510 | + except : |
511 | + pass |
512 | + else : |
513 | + self._lcl_project_data['image_path'] = os.path.join(_lcl_project_xml.findtext("metas/projectPath").strip() , |
514 | + _lcl_project_xml.findtext("metas/rush_dir").strip() ) |
515 | + self._lcl_project_data['fpi'] = int(_lcl_project_xml.findtext("metas/fpi").strip()) |
516 | + |
517 | + # get resources images from project capture data |
518 | + list_image = _lcl_project_xml.find("captureData").getiterator('image') |
519 | + [ self._lcl_project_data['resources_images'].append(image.text.strip()) for image in list_image] |
520 | + |
521 | + # get timelines images from project chrono data |
522 | + list_image = _lcl_project_xml.find("chronoData").getiterator('image') |
523 | + [self._lcl_project_data['timelines_images'].append(image.text.strip()) for image in list_image] |
524 | + |
525 | + |
526 | + def __load_lcl_dict(self): |
527 | + """ |
528 | + Load a Luciole project from a dictionary |
529 | + |
530 | + @return : |
531 | + @author |
532 | + """ |
533 | + |
534 | + self._lcl_project_data['image_path'] = os.path.join(self.lcl_project['project_dir'], self.lcl_project['rush_dir']) |
535 | + self._lcl_project_data['fpi'] = int(self.lcl_project['fpi']) |
536 | + self._lcl_project_data['resources_images'] = self.lcl_project['capture_images'] |
537 | + self._lcl_project_data['timelines_images'] = self.lcl_project['chrono_images'] |
538 | + |
539 | + |
540 | + def __write_export_file(self): |
541 | + """ |
542 | + |
543 | + |
544 | + @return : |
545 | + @author |
546 | + """ |
547 | + self._template_xml.write(self.export_file) |
548 | + |
549 | +class luciole_export_tool_cinelerra (luciole_export_tool): |
550 | + |
551 | + """ |
552 | + |
553 | + |
554 | + :version: |
555 | + :author: |
556 | + """ |
557 | + |
558 | + """ ATTRIBUTES |
559 | + |
560 | + |
561 | + |
562 | + _export_template (private) |
563 | + |
564 | + """ |
565 | + |
566 | + def __init__(self, lcl_project = "./luciole_project.xml", template="./template.xml", export_file = "./export.xml"): |
567 | + """ |
568 | + |
569 | + |
570 | + @param luciole_export_tool lcl_project_type : type of luciole project : "file" or "project" |
571 | + @param object lcl_project : Type de projet |
572 | + @param string template : Path to template |
573 | + @param string export_file : Path to export_file |
574 | + @return : |
575 | + @author |
576 | + """ |
577 | + super(luciole_export_tool_cinelerra, self).__init__(lcl_project,template,export_file ) |
578 | + |
579 | + def _load_template(self): |
580 | + """ |
581 | + """ |
582 | + self._template_xml = LE.lcl_et(self.template) |
583 | + |
584 | + |
585 | + def _gen_ressources(self): |
586 | + """ |
587 | + ressource is called asset in cinelerra template |
588 | + """ |
589 | + resources_tag = self._template_xml.find("//ASSETS") |
590 | + resource_elem_tpl = self._template_xml.find("//ASSET") |
591 | + |
592 | + for image in self._lcl_project_data['resources_images'] : |
593 | + # build image_path |
594 | + image_p = os.path.join(self._lcl_project_data['image_path'], image) |
595 | + # create a resouce element --> i.e an ASSET element |
596 | + new_element = self._template_xml.SubElement(resources_tag,"ASSET",{"SRC":image_p}) |
597 | + # copy subelement od ASSET template tag in new element |
598 | + for elem_tpl in resource_elem_tpl.getchildren() : |
599 | + new_element.append(elem_tpl) |
600 | + |
601 | + #remove template tag |
602 | + resources_tag.remove(resource_elem_tpl) |
603 | + |
604 | + |
605 | + def __get_timeline_tags(self) : |
606 | + """ |
607 | + in cinelerra timeline tags is TRACK with type video, and EDITS/EDIT tag |
608 | + """ |
609 | + video_track = None |
610 | + tracks = self._template_xml.findall("//TRACK") |
611 | + for track in tracks : |
612 | + if track.get("TYPE") == "VIDEO" : |
613 | + # video tak is found |
614 | + video_track = track |
615 | + break |
616 | + # get EDIT tag |
617 | + return ( video_track.find("EDITS"), video_track.find("EDITS/EDIT")) |
618 | + |
619 | + |
620 | + def _gen_timeline(self): |
621 | + """ |
622 | + generate timeline |
623 | + """ |
624 | + (timeline_tag, timeline_item_tpl) = self.__get_timeline_tags() |
625 | + for image in self._lcl_project_data['timelines_images'] : |
626 | + # build image_path |
627 | + image_p = os.path.join(self._lcl_project_data['image_path'], image) |
628 | + |
629 | + # create New EDIT element per image |
630 | + for frame in range(self._lcl_project_data['fpi']): |
631 | + framerate = str(self._lcl_project_data['fpi']) |
632 | + new_element = self._template_xml.SubElement(timeline_tag,"EDIT",{"STARTSOURCE":"0","CHANNEL":"0", "LENGTH":"1"}) |
633 | + # create FILE subElement of EDIT |
634 | + self._template_xml.SubElement(new_element,"FILE",{"SRC":image_p}) |
635 | + |
636 | + # remove EDIT template tag |
637 | + timeline_tag.remove(timeline_item_tpl) |
638 | + |
639 | +if __name__ == '__main__' : |
640 | + X = luciole_export_tool_cinelerra( lcl_project = "/home/nico/temp/testLuciole/luciole_project_isight/luciole_project_isight.xml",template="./cinelerra_template.xml",export_file = "./cine_export.xml" ) |
641 | + X.generate() |
642 | + |
643 | |
644 | === modified file 'lucioLib/luciole_controller.py' |
645 | --- lucioLib/luciole_controller.py 2009-12-07 07:25:24 +0000 |
646 | +++ lucioLib/luciole_controller.py 2009-12-07 07:25:24 +0000 |
647 | @@ -145,6 +145,7 @@ |
648 | # 3. load project in application |
649 | self.__load_project_in_app() |
650 | |
651 | + |
652 | def save_project(self): |
653 | """ save the current project """ |
654 | self.project_ctrller.save(self.project) |
655 | @@ -258,10 +259,17 @@ |
656 | if self.project != None : |
657 | self.gui.export_dialog(self.project) |
658 | else : |
659 | - # nbd@grape to transform as error message |
660 | - msg = _("Nothing to export. No project loaded") |
661 | - LTK.Dialog.ErrorMessage(self.gui.window, msg) |
662 | - |
663 | + msg = _("Nothing to export. No project loaded") |
664 | + LTK.Dialog.ErrorMessage(self.gui.window, msg) |
665 | + |
666 | + def export_tool(self) : |
667 | + """ Manage tool exports """ |
668 | + if self.project != None : |
669 | + self.gui.export_tool_dialog(self.project) |
670 | + else : |
671 | + msg = _("Nothing to export. No project loaded") |
672 | + LTK.Dialog.ErrorMessage(self.gui.window, msg) |
673 | + |
674 | def play(self,index_chrono) : |
675 | """ play video """ |
676 | # Test if project exists |
677 | |
678 | === added file 'lucioLib/luciole_et.py' |
679 | --- lucioLib/luciole_et.py 1970-01-01 00:00:00 +0000 |
680 | +++ lucioLib/luciole_et.py 2009-12-07 07:25:24 +0000 |
681 | @@ -0,0 +1,60 @@ |
682 | +#!/usr/bin/env python |
683 | +# -*- coding: utf-8 -*- |
684 | +# -*- Mode: Python -*- |
685 | +# vi:si:ai:et:sw=4:sts=4:ts=4 |
686 | +# |
687 | +# |
688 | +# Copyright Nicolas Bertrand (nico@inattendu.org), 2009 |
689 | +# |
690 | +# This file is part of Luciole. |
691 | +# |
692 | +# Luciole is free software: you can redistribute it and/or modify |
693 | +# it under the terms of the GNU General Public License as published by |
694 | +# the Free Software Foundation, either version 3 of the License, or |
695 | +# (at your option) any later version. |
696 | +# |
697 | +# Luciole is distributed in the hope that it will be useful, |
698 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
699 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
700 | +# GNU General Public License for more details. |
701 | +# |
702 | +# You should have received a copy of the GNU General Public License |
703 | +# along with Luciole. If not, see <http://www.gnu.org/licenses/>. |
704 | +# |
705 | +# |
706 | + |
707 | +# for i18n |
708 | +from gettext import gettext as _ |
709 | +import xml.etree.ElementTree as ET #python 2.5 |
710 | +from xml.parsers.expat import ParserCreate, ExpatError |
711 | + |
712 | + |
713 | +class lcl_et(object) : |
714 | + def __init__(self,xml_file) : |
715 | + self.xml_file = xml_file |
716 | + #parse XML tempalte file |
717 | + try : |
718 | + self.xml_obj = ET.parse(self.xml_file) |
719 | + except ExpatError , err_value : |
720 | + # Raise Error |
721 | + print "XML parse error in ",self.xml_file, "\nerror :",err_value |
722 | + self.xml_obj = None |
723 | + |
724 | + def findtext(self,condition) : |
725 | + return self.xml_obj.findtext(condition) |
726 | + |
727 | + def find(self,match) : |
728 | + return self.xml_obj.find(match) |
729 | + |
730 | + def findall(self,match) : |
731 | + return self.xml_obj.findall(match) |
732 | + |
733 | + def SubElement(self,parent,tag,attrib) : |
734 | + return ET.SubElement(parent,tag,attrib) |
735 | + |
736 | + def tostring(self,element) : |
737 | + return ET.tostring(element) |
738 | + |
739 | + def write(self,file) : |
740 | + return self.xml_obj.write(file,"UTF-8") |
741 | + |
742 | |
743 | === added file 'templates/cinelerra_template.xml' |
744 | --- templates/cinelerra_template.xml 1970-01-01 00:00:00 +0000 |
745 | +++ templates/cinelerra_template.xml 2009-12-07 07:25:24 +0000 |
746 | @@ -0,0 +1,104 @@ |
747 | +<?xml version="1.0"?> |
748 | +<EDL VERSION="2.1CV" PROJECT_PATH="/home/nico/temp/testLuciole/luciole_project_isight/cinelerra_export.xml"> |
749 | +<LOCALSESSION IN_POINT="-1" LOOP_PLAYBACK="0" LOOP_START="0" LOOP_END="0" OUT_POINT="-1" SELECTION_START="0" SELECTION_END="0" CLIP_TITLE="Program" CLIP_NOTES="Hello world" FOLDER="Clips" TRACK_START="0" VIEW_START="0" ZOOM_SAMPLE="128" ZOOMY="64" ZOOM_TRACK="64" PREVIEW_START="0" PREVIEW_END="1.6799999999999999e+00" RED="0" GREEN="0" BLUE="0" AUTOGROUPTYPE_AUDIO_FADE_MIN="-80" AUTOGROUPTYPE_AUDIO_FADE_MAX="6" AUTOGROUPTYPE_VIDEO_FADE_MIN="0" AUTOGROUPTYPE_VIDEO_FADE_MAX="100" AUTOGROUPTYPE_ZOOM_MIN="1.000000e-03" AUTOGROUPTYPE_ZOOM_MAX="4" AUTOGROUPTYPE_X_MIN="-100" AUTOGROUPTYPE_X_MAX="100" AUTOGROUPTYPE_Y_MIN="-100" AUTOGROUPTYPE_Y_MAX="100"></LOCALSESSION> |
750 | + |
751 | +<SESSION ASSETLIST_FORMAT="1" ASSET_COLUMN0="100" ASSET_COLUMN1="100" SHOW_MUTE="0" SHOW_CAMERA_X="0" SHOW_CAMERA_Y="0" SHOW_CAMERA_Z="0" SHOW_PROJECTOR_X="0" SHOW_PROJECTOR_Y="0" SHOW_PROJECTOR_Z="0" SHOW_FADE="1" SHOW_PAN="0" SHOW_MODE="0" SHOW_MASK="0" SHOW_TRANSITIONS="1" SHOW_PLUGINS="1" AUTO_KEYFRAMES="0" AUTOS_FOLLOW_EDITS="1" BRENDER_START="0" CROP_X1="0" CROP_Y1="0" CROP_X2="320" CROP_Y2="240" CURRENT_FOLDER="Media" CURSOR_ON_FRAMES="1" CWINDOW_DEST="0" CWINDOW_MASK="0" CWINDOW_METER="1" CWINDOW_OPERATION="0" CWINDOW_SCROLLBARS="1" CWINDOW_XSCROLL="0" CWINDOW_YSCROLL="0" CWINDOW_ZOOM="1" DEFAULT_ATRANSITION="Crossfade" DEFAULT_VTRANSITION="Dissolve" DEFAULT_TRANSITION_LENGTH="1" EDITING_MODE="1" FOLDERLIST_FORMAT="1" HIGHLIGHTED_TRACK="0" LABELS_FOLLOW_EDITS="1" MPEG4_DEBLOCK="1" PLUGINS_FOLLOW_EDITS="1" PLAYBACK_PRELOAD="0" SAFE_REGIONS="1" SHOW_ASSETS="1" SHOW_TITLES="1" TEST_PLAYBACK_EDITS="1" TIME_FORMAT="0" TIMECODE_OFFSET_0="0" TIMECODE_OFFSET_1="0" TIMECODE_OFFSET_2="0" TIMECODE_OFFSET_3="0" NUDGE_SECONDS="1" TOOL_WINDOW="0" VWINDOW_METER="1" VWINDOW_FOLDER="" VWINDOW_SOURCE="4294967295" VWINDOW_ZOOM="1" DECODE_SUBTITLES="0" subtitle_number="0"></SESSION> |
752 | + |
753 | +<VIDEO INTERPOLATION_TYPE="2" INTERPOLATE_RAW="1" WHITE_BALANCE_RAW="1" COLORMODEL="RGBA-8 Bit" INTERLACE_MODE="BOTTOM_FIELD_FIRST" CHANNELS="1" VCHANNEL_X_0="0" VCHANNEL_Y_0="0" FRAMERATE="25" FRAMES_PER_FOOT="16" OUTPUTW="720" OUTPUTH="576" ASPECTW="4" ASPECTH="3"></VIDEO> |
754 | + |
755 | +<AUDIO SAMPLERATE="48000" CHANNELS="2" ACHANNEL_ANGLE_0="180" ACHANNEL_ANGLE_1="0"></AUDIO> |
756 | + |
757 | +<FOLDER>Clips</FOLDER> |
758 | +<FOLDER>Media</FOLDER> |
759 | +<ASSETS> |
760 | +<ASSET SRC="/home/nico/temp/testLuciole/luciole_project_isight/rush/rush_00000.jpeg"> |
761 | +<FOLDER>Media</FOLDER> |
762 | +<FORMAT TYPE="JPEG" USE_HEADER="1"></FORMAT> |
763 | +<AUDIO_OMIT CHANNELS="0" RATE="0" BITS="0" BYTE_ORDER="0" SIGNED="0" HEADER="0" DITHER="0" ACODEC="twos" AUDIO_LENGTH="0"></AUDIO_OMIT> |
764 | +<VIDEO HEIGHT="576" WIDTH="720" LAYERS="1" FRAMERATE="1" VCODEC="yuv2" VIDEO_LENGTH="-1" INTERLACE_AUTOFIX="1" INTERLACE_MODE="NOTINTERLACED" INTERLACE_FIXMETHOD="DO_NOTHING" REEL_NAME="cin0000" REEL_NUMBER="0" TCSTART="0" TCEND="0" TCFORMAT="0"></VIDEO> |
765 | +</ASSET> |
766 | +</ASSETS> |
767 | + |
768 | + |
769 | + |
770 | +<LABELS> |
771 | +</LABELS> |
772 | + |
773 | +<TRACK RECORD="1" NUDGE="0" PLAY="1" GANG="1" DRAW="1" EXPAND="0" TRACK_W="720" TRACK_H="576" TYPE="VIDEO"> |
774 | +<TITLE>Video 1</TITLE> |
775 | +<EDITS> |
776 | +<EDIT STARTSOURCE="0" CHANNEL="0" LENGTH="7"><FILE SRC="/home/nico/temp/testLuciole/luciole_project_isight/rush/rush_00000.jpeg"></FILE></EDIT> |
777 | +</EDITS> |
778 | +<MUTEAUTOS> |
779 | +<AUTO POSITION="0" VALUE="0"></AUTO> |
780 | +</MUTEAUTOS> |
781 | +<CAMERA_X> |
782 | +<AUTO POSITION="0" VALUE="0" CONTROL_IN_VALUE="0" CONTROL_OUT_VALUE="0" CONTROL_IN_POSITION="0" CONTROL_OUT_POSITION="0"></AUTO> |
783 | +</CAMERA_X> |
784 | +<CAMERA_Y> |
785 | +<AUTO POSITION="0" VALUE="0" CONTROL_IN_VALUE="0" CONTROL_OUT_VALUE="0" CONTROL_IN_POSITION="0" CONTROL_OUT_POSITION="0"></AUTO> |
786 | +</CAMERA_Y> |
787 | +<CAMERA_Z> |
788 | +<AUTO POSITION="0" VALUE="1" CONTROL_IN_VALUE="0" CONTROL_OUT_VALUE="0" CONTROL_IN_POSITION="0" CONTROL_OUT_POSITION="0"></AUTO> |
789 | +</CAMERA_Z> |
790 | +<PROJECTOR_X> |
791 | +<AUTO POSITION="0" VALUE="0" CONTROL_IN_VALUE="0" CONTROL_OUT_VALUE="0" CONTROL_IN_POSITION="0" CONTROL_OUT_POSITION="0"></AUTO> |
792 | +</PROJECTOR_X> |
793 | +<PROJECTOR_Y> |
794 | +<AUTO POSITION="0" VALUE="0" CONTROL_IN_VALUE="0" CONTROL_OUT_VALUE="0" CONTROL_IN_POSITION="0" CONTROL_OUT_POSITION="0"></AUTO> |
795 | +</PROJECTOR_Y> |
796 | +<PROJECTOR_Z> |
797 | +<AUTO POSITION="0" VALUE="1" CONTROL_IN_VALUE="0" CONTROL_OUT_VALUE="0" CONTROL_IN_POSITION="0" CONTROL_OUT_POSITION="0"></AUTO> |
798 | +</PROJECTOR_Z> |
799 | +<FADEAUTOS> |
800 | +<AUTO POSITION="0" VALUE="100" CONTROL_IN_VALUE="0" CONTROL_OUT_VALUE="0" CONTROL_IN_POSITION="0" CONTROL_OUT_POSITION="0"></AUTO> |
801 | +</FADEAUTOS> |
802 | +<MODEAUTOS> |
803 | +<AUTO POSITION="0" VALUE="0"></AUTO> |
804 | +</MODEAUTOS> |
805 | +<MASKAUTOS> |
806 | +<AUTO MODE="1" VALUE="100" FEATHER="0" APPLY_BEFORE_PLUGINS="0" POSITION="0"> |
807 | + |
808 | +</AUTO> |
809 | +</MASKAUTOS> |
810 | +</TRACK> |
811 | + |
812 | + |
813 | + |
814 | +<TRACK RECORD="1" NUDGE="0" PLAY="1" GANG="1" DRAW="1" EXPAND="0" TRACK_W="720" TRACK_H="576" TYPE="AUDIO"> |
815 | + |
816 | +<TITLE>Audio 1</TITLE> |
817 | +<EDITS> |
818 | +<EDIT STARTSOURCE="0" CHANNEL="0" LENGTH="80640"></EDIT> |
819 | +</EDITS> |
820 | +<MUTEAUTOS> |
821 | +<AUTO POSITION="0" VALUE="0"></AUTO> |
822 | +</MUTEAUTOS> |
823 | +<FADEAUTOS> |
824 | +<AUTO POSITION="0" VALUE="0" CONTROL_IN_VALUE="0" CONTROL_OUT_VALUE="0" CONTROL_IN_POSITION="0" CONTROL_OUT_POSITION="0"></AUTO> |
825 | +</FADEAUTOS> |
826 | +<PANAUTOS> |
827 | +<AUTO POSITION="0" HANDLE_X="1" HANDLE_Y="50" VALUE0="1" VALUE1="0"></AUTO></PANAUTOS> |
828 | +</TRACK> |
829 | + |
830 | + |
831 | + |
832 | +<TRACK RECORD="1" NUDGE="0" PLAY="1" GANG="1" DRAW="1" EXPAND="0" TRACK_W="720" TRACK_H="576" TYPE="AUDIO"> |
833 | + |
834 | +<TITLE>Audio 2</TITLE> |
835 | +<EDITS> |
836 | +<EDIT STARTSOURCE="0" CHANNEL="0" LENGTH="80640"></EDIT> |
837 | +</EDITS> |
838 | +<MUTEAUTOS> |
839 | +<AUTO POSITION="0" VALUE="0"></AUTO> |
840 | +</MUTEAUTOS> |
841 | +<FADEAUTOS> |
842 | +<AUTO POSITION="0" VALUE="0" CONTROL_IN_VALUE="0" CONTROL_OUT_VALUE="0" CONTROL_IN_POSITION="0" CONTROL_OUT_POSITION="0"></AUTO> |
843 | +</FADEAUTOS> |
844 | +<PANAUTOS> |
845 | +<AUTO POSITION="0" HANDLE_X="100" HANDLE_Y="50" VALUE0="0" VALUE1="1"></AUTO></PANAUTOS> |
846 | +</TRACK> |
847 | + |
848 | + |
849 | + |
850 | +</EDL> |
851 | |
852 | === added file 'ui/export_file.glade' |
853 | --- ui/export_file.glade 1970-01-01 00:00:00 +0000 |
854 | +++ ui/export_file.glade 2009-12-07 07:25:24 +0000 |
855 | @@ -0,0 +1,254 @@ |
856 | +<?xml version="1.0"?> |
857 | +<interface> |
858 | + <requires lib="gtk+" version="2.16"/> |
859 | + <!-- interface-naming-policy project-wide --> |
860 | + <object class="GtkDialog" id="dialog_export_file"> |
861 | + <property name="border_width">5</property> |
862 | + <property name="type_hint">normal</property> |
863 | + <property name="has_separator">False</property> |
864 | + <signal name="destroy" handler="on_dialog_export_file_destroy"/> |
865 | + <signal name="close" handler="on_dialog_export_file_close"/> |
866 | + <signal name="response" handler="on_dialog_export_file_response"/> |
867 | + <child internal-child="vbox"> |
868 | + <object class="GtkVBox" id="dialog-vbox1"> |
869 | + <property name="visible">True</property> |
870 | + <property name="orientation">vertical</property> |
871 | + <property name="spacing">2</property> |
872 | + <child> |
873 | + <object class="GtkLabel" id="label1"> |
874 | + <property name="visible">True</property> |
875 | + <property name="yalign">0.25</property> |
876 | + <property name="ypad">8</property> |
877 | + <property name="label" translatable="yes">Export to another application</property> |
878 | + <attributes> |
879 | + <attribute name="style" value="normal"/> |
880 | + <attribute name="weight" value="semibold"/> |
881 | + <attribute name="underline" value="True"/> |
882 | + </attributes> |
883 | + </object> |
884 | + <packing> |
885 | + <property name="expand">False</property> |
886 | + <property name="fill">False</property> |
887 | + <property name="padding">5</property> |
888 | + <property name="position">1</property> |
889 | + </packing> |
890 | + </child> |
891 | + <child> |
892 | + <object class="GtkVBox" id="vbox1"> |
893 | + <property name="visible">True</property> |
894 | + <property name="orientation">vertical</property> |
895 | + <child> |
896 | + <object class="GtkTable" id="table1"> |
897 | + <property name="visible">True</property> |
898 | + <property name="n_rows">2</property> |
899 | + <property name="n_columns">2</property> |
900 | + <child> |
901 | + <object class="GtkRadioButton" id="radio_cine"> |
902 | + <property name="label" translatable="yes">Cinelerra</property> |
903 | + <property name="visible">True</property> |
904 | + <property name="can_focus">True</property> |
905 | + <property name="receives_default">False</property> |
906 | + <property name="active">True</property> |
907 | + <property name="draw_indicator">True</property> |
908 | + <signal name="toggled" handler="on_radio_cine_toggled"/> |
909 | + </object> |
910 | + </child> |
911 | + <child> |
912 | + <object class="GtkRadioButton" id="radio_kdenlive"> |
913 | + <property name="label" translatable="yes">Kdenlive</property> |
914 | + <property name="visible">True</property> |
915 | + <property name="can_focus">True</property> |
916 | + <property name="receives_default">False</property> |
917 | + <property name="draw_indicator">True</property> |
918 | + <property name="group">radio_cine</property> |
919 | + <signal name="toggled" handler="on_radio_kdenlive_toggled"/> |
920 | + </object> |
921 | + <packing> |
922 | + <property name="top_attach">1</property> |
923 | + <property name="bottom_attach">2</property> |
924 | + </packing> |
925 | + </child> |
926 | + <child> |
927 | + <object class="GtkRadioButton" id="radio_pitivi"> |
928 | + <property name="label" translatable="yes">Pitivi</property> |
929 | + <property name="visible">True</property> |
930 | + <property name="can_focus">True</property> |
931 | + <property name="receives_default">False</property> |
932 | + <property name="draw_indicator">True</property> |
933 | + <property name="group">radio_cine</property> |
934 | + <signal name="toggled" handler="on_radio_pitivi_toggled"/> |
935 | + </object> |
936 | + <packing> |
937 | + <property name="left_attach">1</property> |
938 | + <property name="right_attach">2</property> |
939 | + </packing> |
940 | + </child> |
941 | + <child> |
942 | + <object class="GtkRadioButton" id="radio_openshot"> |
943 | + <property name="label" translatable="yes">Openshot</property> |
944 | + <property name="visible">True</property> |
945 | + <property name="can_focus">True</property> |
946 | + <property name="receives_default">False</property> |
947 | + <property name="draw_indicator">True</property> |
948 | + <property name="group">radio_cine</property> |
949 | + <signal name="toggled" handler="on_radio_openshot_toggled"/> |
950 | + </object> |
951 | + <packing> |
952 | + <property name="left_attach">1</property> |
953 | + <property name="right_attach">2</property> |
954 | + <property name="top_attach">1</property> |
955 | + <property name="bottom_attach">2</property> |
956 | + </packing> |
957 | + </child> |
958 | + </object> |
959 | + <packing> |
960 | + <property name="padding">10</property> |
961 | + <property name="position">0</property> |
962 | + </packing> |
963 | + </child> |
964 | + <child> |
965 | + <object class="GtkHBox" id="hbox1"> |
966 | + <property name="visible">True</property> |
967 | + <child> |
968 | + <object class="GtkLabel" id="label2"> |
969 | + <property name="width_request">250</property> |
970 | + <property name="visible">True</property> |
971 | + <property name="label" translatable="yes">Select an export directory</property> |
972 | + </object> |
973 | + <packing> |
974 | + <property name="expand">False</property> |
975 | + <property name="fill">False</property> |
976 | + <property name="position">0</property> |
977 | + </packing> |
978 | + </child> |
979 | + <child> |
980 | + <object class="GtkFileChooserButton" id="filechooserbutton1"> |
981 | + <property name="visible">True</property> |
982 | + <property name="action">select-folder</property> |
983 | + <property name="title" translatable="yes">Select a folder</property> |
984 | + <signal name="file_set" handler="on_filechooserbutton1_file_set"/> |
985 | + </object> |
986 | + <packing> |
987 | + <property name="expand">False</property> |
988 | + <property name="fill">False</property> |
989 | + <property name="padding">1</property> |
990 | + <property name="position">1</property> |
991 | + </packing> |
992 | + </child> |
993 | + </object> |
994 | + <packing> |
995 | + <property name="padding">10</property> |
996 | + <property name="position">1</property> |
997 | + </packing> |
998 | + </child> |
999 | + <child> |
1000 | + <object class="GtkHBox" id="hbox2"> |
1001 | + <property name="visible">True</property> |
1002 | + <child> |
1003 | + <object class="GtkLabel" id="label3"> |
1004 | + <property name="width_request">250</property> |
1005 | + <property name="visible">True</property> |
1006 | + <property name="label" translatable="yes">Select a filename</property> |
1007 | + </object> |
1008 | + <packing> |
1009 | + <property name="expand">False</property> |
1010 | + <property name="fill">False</property> |
1011 | + <property name="position">0</property> |
1012 | + </packing> |
1013 | + </child> |
1014 | + <child> |
1015 | + <object class="GtkEntry" id="entry_fn"> |
1016 | + <property name="visible">True</property> |
1017 | + <property name="can_focus">True</property> |
1018 | + <property name="invisible_char">●</property> |
1019 | + </object> |
1020 | + <packing> |
1021 | + <property name="position">1</property> |
1022 | + </packing> |
1023 | + </child> |
1024 | + </object> |
1025 | + <packing> |
1026 | + <property name="padding">10</property> |
1027 | + <property name="position">2</property> |
1028 | + </packing> |
1029 | + </child> |
1030 | + <child> |
1031 | + <object class="GtkStatusbar" id="statusbar1"> |
1032 | + <property name="visible">True</property> |
1033 | + <property name="spacing">2</property> |
1034 | + <property name="has_resize_grip">False</property> |
1035 | + </object> |
1036 | + <packing> |
1037 | + <property name="expand">False</property> |
1038 | + <property name="padding">3</property> |
1039 | + <property name="position">3</property> |
1040 | + </packing> |
1041 | + </child> |
1042 | + </object> |
1043 | + <packing> |
1044 | + <property name="position">2</property> |
1045 | + </packing> |
1046 | + </child> |
1047 | + <child internal-child="action_area"> |
1048 | + <object class="GtkHButtonBox" id="dialog-action_area1"> |
1049 | + <property name="visible">True</property> |
1050 | + <property name="layout_style">end</property> |
1051 | + <child> |
1052 | + <object class="GtkButton" id="button1"> |
1053 | + <property name="label">gtk-cancel</property> |
1054 | + <property name="visible">True</property> |
1055 | + <property name="can_focus">True</property> |
1056 | + <property name="receives_default">True</property> |
1057 | + <property name="use_stock">True</property> |
1058 | + </object> |
1059 | + <packing> |
1060 | + <property name="expand">False</property> |
1061 | + <property name="fill">False</property> |
1062 | + <property name="position">0</property> |
1063 | + </packing> |
1064 | + </child> |
1065 | + <child> |
1066 | + <object class="GtkButton" id="button2"> |
1067 | + <property name="label">gtk-convert</property> |
1068 | + <property name="visible">True</property> |
1069 | + <property name="can_focus">True</property> |
1070 | + <property name="receives_default">True</property> |
1071 | + <property name="use_stock">True</property> |
1072 | + </object> |
1073 | + <packing> |
1074 | + <property name="expand">False</property> |
1075 | + <property name="fill">False</property> |
1076 | + <property name="position">1</property> |
1077 | + </packing> |
1078 | + </child> |
1079 | + <child> |
1080 | + <object class="GtkButton" id="button3"> |
1081 | + <property name="label">gtk-close</property> |
1082 | + <property name="visible">True</property> |
1083 | + <property name="can_focus">True</property> |
1084 | + <property name="receives_default">True</property> |
1085 | + <property name="use_stock">True</property> |
1086 | + <signal name="activate" handler="on_dialog_export_file_close"/> |
1087 | + </object> |
1088 | + <packing> |
1089 | + <property name="expand">False</property> |
1090 | + <property name="fill">False</property> |
1091 | + <property name="position">2</property> |
1092 | + </packing> |
1093 | + </child> |
1094 | + </object> |
1095 | + <packing> |
1096 | + <property name="expand">False</property> |
1097 | + <property name="pack_type">end</property> |
1098 | + <property name="position">0</property> |
1099 | + </packing> |
1100 | + </child> |
1101 | + </object> |
1102 | + </child> |
1103 | + <action-widgets> |
1104 | + <action-widget response="1">button1</action-widget> |
1105 | + <action-widget response="2">button2</action-widget> |
1106 | + <action-widget response="3">button3</action-widget> |
1107 | + </action-widgets> |
1108 | + </object> |
1109 | +</interface> |
1110 | |
1111 | === modified file 'ui/luciole.glade' |
1112 | --- ui/luciole.glade 2009-12-07 07:25:24 +0000 |
1113 | +++ ui/luciole.glade 2009-12-07 07:25:24 +0000 |
1114 | @@ -172,6 +172,15 @@ |
1115 | </object> |
1116 | </child> |
1117 | <child> |
1118 | + <object class="GtkImageMenuItem" id="file_export_tool"> |
1119 | + <property name="label" translatable="yes">Tool Export</property> |
1120 | + <property name="visible">True</property> |
1121 | + <property name="image">image5</property> |
1122 | + <property name="use_stock">False</property> |
1123 | + <signal name="activate" handler="on_file_export_tool_activate"/> |
1124 | + </object> |
1125 | + </child> |
1126 | + <child> |
1127 | <object class="GtkSeparatorMenuItem" id="separatormenuitem2"> |
1128 | <property name="visible">True</property> |
1129 | </object> |
1130 | @@ -368,7 +377,7 @@ |
1131 | <accelerator key="c" signal="clicked"/> |
1132 | <signal name="clicked" handler="on_button_capture_clicked"/> |
1133 | <child> |
1134 | - <object class="GtkImage" id="image5"> |
1135 | + <object class="GtkImage" id="image_snapshot_button"> |
1136 | <property name="visible">True</property> |
1137 | <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property> |
1138 | <property name="tooltip_text" translatable="yes">make a snapshot</property> |
1139 | @@ -1386,9 +1395,9 @@ |
1140 | <object class="GtkFileChooserButton" id="filechooserbutton1"> |
1141 | <property name="visible">True</property> |
1142 | <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property> |
1143 | + <property name="do_overwrite_confirmation">True</property> |
1144 | + <property name="action">select-folder</property> |
1145 | <property name="use_preview_label">False</property> |
1146 | - <property name="action">select-folder</property> |
1147 | - <property name="do_overwrite_confirmation">True</property> |
1148 | <property name="title" translatable="yes">Select a folder</property> |
1149 | </object> |
1150 | <packing> |
1151 | @@ -1772,4 +1781,8 @@ |
1152 | <property name="visible">True</property> |
1153 | <property name="stock">gtk-preferences</property> |
1154 | </object> |
1155 | + <object class="GtkImage" id="image5"> |
1156 | + <property name="visible">True</property> |
1157 | + <property name="stock">gtk-connect</property> |
1158 | + </object> |
1159 | </interface> |
Approved .
Specification wiki shall be updated.
Translation needed