Hi,

This morning, my girlfriend ask me how she could print her A1 PDF file which 
was a project plan from MS Project on our A4 printer. I first tried KDE's 
poster printing functions, but Ghostscript was so slow with this PDF that I 
did not want to wait for it to finish.

So I tried podofoimpose with the plan file below (I took it straight out from 
your documentation!):
<snip>
597.6 842.4
1 1 0 16.56 172.4
1 2 0 -547.92 172.4
1 3 0 -1112.4 172.4
1 4 0 -1676.88 172.4
1 5 0 16.56 -497.6
1 6 0 -547.92 -497.6
1 7 0 -1112.4 -497.6
1 8 0 -1676.88 -497.6
</snap>

But it did not work either and quite with a bad plan file error message. I 
uncommented a few lines in the source and it worked. Patch below:

[EMAIL PROTECTED]:~/Desktop/Programming/podofo/podofo/tools/podofoimpose (4)>
_svn diff
Index: pdftranslator.cpp
===================================================================
--- pdftranslator.cpp   (Revision 824)
+++ pdftranslator.cpp   (Arbeitskopie)
@@ -344,8 +344,8 @@

         PageRecord p;
         in >> p;
-//         if (in.eof())
-//             break;
+         if (in.eof())
+             break;
         if (!p.isValid())
             throw runtime_error("Bad plan file record");

[EMAIL PROTECTED]:~/Desktop/Programming/podofo/podofo/tools/podofoimpose (5)>

Pierre, do you know what caused this error or why I need those to lines that 
where commented? I think that testing for EOF should never hurt and we should 
commit this patch. But I am sure you had a reason to do so.

After changing this for me, it worked super-fine. Creating the poster took 
about 2 seconds compared to Ghostscript which I canceled after 30 minutes. 

I had also another idea, what do you think of shipping some predefined plan 
files for this poster conversion? a1 -> a4 (portrait and landscape), a2 -> 
a4, a3 -> a4, etc. . I think it is quite  easy to create this plan files 
using any scripting language.

best regards,
        Dom

-- 
**********************************************************************
Dominik Seichter - [EMAIL PROTECTED]
KRename  - http://www.krename.net  - Powerful batch renamer for KDE
KBarcode - http://www.kbarcode.net - Barcode and label printing
PoDoFo - http://podofo.sf.net - PDF generation and parsing library
SchafKopf - http://schafkopf.berlios.de - Schafkopf, a card game,  for KDE
Alan - http://alan.sf.net - A Turing Machine in Java
**********************************************************************

Attachment: signature.asc
Description: This is a digitally signed message part.

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Podofo-users mailing list
Podofo-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/podofo-users

Reply via email to