On Thu, 29 Apr 2004, Ted Gould wrote:
On Wed, 2004-04-28 at 16:21, vellum wrote:
The problem seems to occur when there is text in the file.
Ah, yes. Carl, this is probably related to the text function that was added. I don't think that it was added into the other print drivers besides the Postscript one. Is it possible that we could make the default /src/extension/implementation/implementation.cpp one do the same rendering of the text that was done before? This way older print drivers won't need to reimplement this functionality.
Hi Ted,
The problem is that sp_text_print() has to decide whether to print text by printing curves, or whether to call sp_print_text() (which in turn calls Extension::text()).
It decides this by doing sp_print_get_param for the "textToPath" parameter. If an extension does not know the parameter, it throws an exception. This is currently not caught, causing the silent exit.
The quick fix for this is:
Index: extension/internal/win32.cpp =================================================================== RCS file: /cvsroot/inkscape/inkscape/src/extension/internal/win32.cpp,v retrieving revision 1.7 diff -u -r1.7 win32.cpp --- extension/internal/win32.cpp 15 Apr 2004 18:23:46 -0000 1.7 +++ extension/internal/win32.cpp 29 Apr 2004 14:06:35 -0000 @@ -483,6 +483,7 @@ "<spmodule>\n" "<name>Windows 32-bit Print</name>\n" "<id>" SP_MODULE_KEY_PRINT_WIN32 "</id>\n" + "<param name="textToPath" type="boolean">TRUE</param>\n" "<print/>\n" "</spmodule>", new PrintWin32());
I think you always want to do text-to-path for this extension, so this fix should be ok.
Do you think it's right that an exception is thrown if a particular extension doesn't understand some parameter? I'm not really very well up on the extension code.
Thanks
Carl