From: keescook Date: Sat, 27 May 2006 16:28:49 +0000 (+0000) Subject: Fixes bug #1495310, allowing parameters for output extensions. X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=0a690bd266d4c9a4bb5c5e58296fe5b75eb4ee08;p=inkscape.git Fixes bug #1495310, allowing parameters for output extensions. --- diff --git a/ChangeLog b/ChangeLog index 42b1325b9..e98febc31 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2006-05-27 Kees Cook + + * src/extension/implementation/script.cpp: allow output extension + parameters to be prompted and used, closes bug #1495310. + 2006-05-26 MenTaLguY * src/dialogs/layers-panel.h, src/dialogs/layers-panel.cpp: diff --git a/src/extension/implementation/script.cpp b/src/extension/implementation/script.cpp index bd9b085e2..e316822fc 100644 --- a/src/extension/implementation/script.cpp +++ b/src/extension/implementation/script.cpp @@ -31,6 +31,7 @@ #include "prefs-utils.h" #include "../system.h" #include "extension/effect.h" +#include "extension/output.h" #include "extension/db.h" #include "script.h" @@ -366,8 +367,7 @@ Script::prefs_input(Inkscape::Extension::Input *module, gchar const *filename) Gtk::Widget * Script::prefs_output(Inkscape::Extension::Output *module) { - /*return module->autogui();*/ - return NULL; + return module->autogui(NULL, NULL); } /** @@ -524,7 +524,12 @@ Script::save(Inkscape::Extension::Output *module, SPDocument *doc, gchar const * gchar *local_filename = g_filename_from_utf8( filename, -1, &bytesRead, &bytesWritten, &error); - execute(command, tempfilename_in, local_filename); + Glib::ustring local_command(command); + Glib::ustring * paramString = module->paramString(); + local_command += *paramString; + delete paramString; + + execute(local_command.c_str(), tempfilename_in, local_filename); g_free(local_filename);