Different print file sizes with different components
Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange
-
- User
- Posts: 91
- Joined: Fri Jun 15, 2007 9:57 am
Different print file sizes with different components
Hi,
I am trying to generate XPS files using your viewer and printing to the Microsoft XPS Printer. For the same pdf printed I obtain three different xps files changing in size and data, based on the printing method I use.
The best results are when the file size of xps file is light and the text is fully selectable and extractable; the worst result is when the file size is bigger and text is not selectable.
For my tests I used two pdf files (included): Test1.pdf is a four page file with partially embedded fonts, Test2.pdf is a four pages file extracted from PDF-XChange Viewer SDK manual with only an embedded font.
To print the pdf I have used the latest software from your PDF-XChange Viewer SDK v2.5.191: A) Bin\PDFXCview.exe, B) Bin\pxcview36_sample_vb.exe that uses the dll viewer pxcview.dll, b) Bin\AX_CExamples\PrintDocument.exe that uses the ActiveX viewer PDFXCviewAx.dll.
The results are the following:
For Test1.pdf
PDFXCview.exe: 510.289 byte, text correctly rendered but if copied in clipboard contains partially garbage.
pxcview.dll: 1.803.435 byte, text partially correctly rendered, text copied in clipboard contains partially garbage.
PDFXCviewAx.dll: 3.754.016 byte, text correctly rendered (appears as an image), text copied in clipboard contains only title text.
For Test2.pdf
PDFXCview.exe: 99.235 byte, text correctly rendered, text copied into clipboard is completely well extracted.
pxcview.dll: 183.800 byte, text correctly rendered, text copied into clipboard is completely well extracted.
PDFXCviewAx.dll: 169.863 byte, text correctly rendered, text copied into clipboard is completely well extracted.
To me, the best obtained results are with the PDFXCview.exe with pdf without embedded fonts.
Why I cannot obtain the same best results with the SDK samples than the full viewer? The bigger xps file size imply also a big time to generate it. The ActiveX version expecially, have produced the worst xps file sizes and the dll viewer produces garbage. How can I reach the same results of the PDFXCview.exe ?
Thanks.
Carlo
I am trying to generate XPS files using your viewer and printing to the Microsoft XPS Printer. For the same pdf printed I obtain three different xps files changing in size and data, based on the printing method I use.
The best results are when the file size of xps file is light and the text is fully selectable and extractable; the worst result is when the file size is bigger and text is not selectable.
For my tests I used two pdf files (included): Test1.pdf is a four page file with partially embedded fonts, Test2.pdf is a four pages file extracted from PDF-XChange Viewer SDK manual with only an embedded font.
To print the pdf I have used the latest software from your PDF-XChange Viewer SDK v2.5.191: A) Bin\PDFXCview.exe, B) Bin\pxcview36_sample_vb.exe that uses the dll viewer pxcview.dll, b) Bin\AX_CExamples\PrintDocument.exe that uses the ActiveX viewer PDFXCviewAx.dll.
The results are the following:
For Test1.pdf
PDFXCview.exe: 510.289 byte, text correctly rendered but if copied in clipboard contains partially garbage.
pxcview.dll: 1.803.435 byte, text partially correctly rendered, text copied in clipboard contains partially garbage.
PDFXCviewAx.dll: 3.754.016 byte, text correctly rendered (appears as an image), text copied in clipboard contains only title text.
For Test2.pdf
PDFXCview.exe: 99.235 byte, text correctly rendered, text copied into clipboard is completely well extracted.
pxcview.dll: 183.800 byte, text correctly rendered, text copied into clipboard is completely well extracted.
PDFXCviewAx.dll: 169.863 byte, text correctly rendered, text copied into clipboard is completely well extracted.
To me, the best obtained results are with the PDFXCview.exe with pdf without embedded fonts.
Why I cannot obtain the same best results with the SDK samples than the full viewer? The bigger xps file size imply also a big time to generate it. The ActiveX version expecially, have produced the worst xps file sizes and the dll viewer produces garbage. How can I reach the same results of the PDFXCview.exe ?
Thanks.
Carlo
You do not have the required permissions to view the files attached to this post.
-
- Site Admin
- Posts: 3586
- Joined: Thu Jul 08, 2004 10:36 pm
Re: Different print file sizes with different components
To obtain the same result you have to pass the same options for printing where it is possible (you can do that for viewer and AX, but not always with pxcview.dll).
Please let me know the parameters you have used in all cases.
Please let me know the parameters you have used in all cases.
PDF-XChange Co Ltd. (Project Director)
When attaching files to any message - please ensure they are archived and posted as a .ZIP, .RAR or .7z format - or they will not be posted - thanks.
When attaching files to any message - please ensure they are archived and posted as a .ZIP, .RAR or .7z format - or they will not be posted - thanks.
-
- User
- Posts: 91
- Joined: Fri Jun 15, 2007 9:57 am
Re: Different print file sizes with different components
For the tests I used the compiled samples from the SDK using the defaults except for Auto-rotate sheets, Auto-centre pages in sheets, Choose paper size by PDF page size where I enable all (this settings are showed in the same dialog for PDFXCview.exe and PrintDocument.exe).
I noted only a difference: in the Advanced Print Setup of print dialog of PrintDocument.exe, Print Text as Curves is set to 'For Embedded fonts', instead in PDFXCview.exe is set to 'Auto'. This have impact on the size of xps file produced with Test1.pdf only.
Looking to pxcview36_sample_vb.exe sources I see that the only flag used in parameters passed to PXCV_DrawPageToDC is the pxvrpf_UseVectorRenderer flag.
Carlo
I noted only a difference: in the Advanced Print Setup of print dialog of PrintDocument.exe, Print Text as Curves is set to 'For Embedded fonts', instead in PDFXCview.exe is set to 'Auto'. This have impact on the size of xps file produced with Test1.pdf only.
Looking to pxcview36_sample_vb.exe sources I see that the only flag used in parameters passed to PXCV_DrawPageToDC is the pxvrpf_UseVectorRenderer flag.
Carlo
-
- Site Admin
- Posts: 19885
- Joined: Mon Jan 12, 2009 8:07 am
Re: Different print file sizes with different components
Hello Carlo,
I will ask Ivan a bit later today when he comes to work if he has any more comments on the topic.
Best,
Stefan
I will ask Ivan a bit later today when he comes to work if he has any more comments on the topic.
Best,
Stefan
-
- Site Admin
- Posts: 19885
- Joined: Mon Jan 12, 2009 8:07 am
Re: Different print file sizes with different components
Hi Again Carlo,
Ivan says that using the very same settings in the end user Viewer and in the AX should result in the same file size, as the AX is the same as the end user Viewer.
The Simple SDK is possible to produce different results but it was never intended to have extended printing options in that SDK. It was designed to offer a simple and more basic set of features, so advanced printing was never considered there.
Best,
Stefan
Ivan says that using the very same settings in the end user Viewer and in the AX should result in the same file size, as the AX is the same as the end user Viewer.
The Simple SDK is possible to produce different results but it was never intended to have extended printing options in that SDK. It was designed to offer a simple and more basic set of features, so advanced printing was never considered there.
Best,
Stefan
-
- User
- Posts: 91
- Joined: Fri Jun 15, 2007 9:57 am
Re: Different print file sizes with different components
Hi Stefan,
yes, using the same settings of PDFXCview.exe with the ActiveX viewer I get rougly the same file sizes (file produced by ActiveX tend to be slightly more bigger), but printing Test1.pdf with the dll version of viewer (pxcview36_sample_vb.exe) I get more garbage in the rendered file. This happens if I print to Microsoft XPS printer or to the PDF-XChange 4.0 printer both. Please give a try also you.
A question: why printing pdf with embedded fonts only produces xps files (or pdf files if I print to the PDF-XChange 4.0 printer) that are big in size and not selectable with the tool? This happens also if I use PDFXCview.exe.
Thanks,
Carlo
yes, using the same settings of PDFXCview.exe with the ActiveX viewer I get rougly the same file sizes (file produced by ActiveX tend to be slightly more bigger), but printing Test1.pdf with the dll version of viewer (pxcview36_sample_vb.exe) I get more garbage in the rendered file. This happens if I print to Microsoft XPS printer or to the PDF-XChange 4.0 printer both. Please give a try also you.
A question: why printing pdf with embedded fonts only produces xps files (or pdf files if I print to the PDF-XChange 4.0 printer) that are big in size and not selectable with the tool? This happens also if I use PDFXCview.exe.
Thanks,
Carlo
-
- Site Admin
- Posts: 19885
- Joined: Mon Jan 12, 2009 8:07 am
Re: Different print file sizes with different components
Hello Carlo,
The sample is using the simple dll sdk - hence the size difference.
As for the question regarding embedded fonts - I will ask for some advise from the devs
Best,
Stefan
The sample is using the simple dll sdk - hence the size difference.
As for the question regarding embedded fonts - I will ask for some advise from the devs

Best,
Stefan
-
- User
- Posts: 91
- Joined: Fri Jun 15, 2007 9:57 am
Re: Different print file sizes with different components
OK for the size, but there is a problem with the resulting output files.
Take a look at the included files produced with the dll version of the viewer printing Test1.pdf: the body text is garbage.
Best,
Carlo
Take a look at the included files produced with the dll version of the viewer printing Test1.pdf: the body text is garbage.
Best,
Carlo
You do not have the required permissions to view the files attached to this post.
-
- Site Admin
- Posts: 3586
- Joined: Thu Jul 08, 2004 10:36 pm
Re: Different print file sizes with different components
I guess the flag pxvrpf_EmbeddedFontAsCurves should be used.
PDF-XChange Co Ltd. (Project Director)
When attaching files to any message - please ensure they are archived and posted as a .ZIP, .RAR or .7z format - or they will not be posted - thanks.
When attaching files to any message - please ensure they are archived and posted as a .ZIP, .RAR or .7z format - or they will not be posted - thanks.
-
- User
- Posts: 91
- Joined: Fri Jun 15, 2007 9:57 am
Re: Different print file sizes with different components
Correct, using pxvrpf_EmbeddedFontAsCurves flag the resulting file is now rendered correctly but sadly, the file size has grown to four times the previous size.
Printing pdfs with embedded fonts is ever a pain
.
Many thanks, however.
Carlo
Printing pdfs with embedded fonts is ever a pain

Many thanks, however.
Carlo
-
- Site Admin
- Posts: 19885
- Joined: Mon Jan 12, 2009 8:07 am
Re: Different print file sizes with different components
Hi Carlo,
As stated before the dll SDK was intended for simple rendering of existing PDF documents, and most of the improvements are happening in the AX one, so please consider it as you have seen yourself it produces the better results.
Best,
Stefan
As stated before the dll SDK was intended for simple rendering of existing PDF documents, and most of the improvements are happening in the AX one, so please consider it as you have seen yourself it produces the better results.
Best,
Stefan