Spire.Doc is a professional Word .NET library specifically designed for developers to create, read, write, convert and print Word document files. Get free and professional technical support for Spire.Doc for .NET, Java, Android, C++, Python.

Mon Nov 24, 2014 9:11 pm

Hello.
I am using Spire.doc object from Powershell to printout a word-document using a local printer "KONICA MINOLTA C364SeriesPS" supporting postscript. The file prints Okay, but the resulting file includes all font used as embedded font - even though the fonts already is supported by the printerdriver and it makes the .ps much bigger and less portable than needed.

If I use the same printer and prints the same Word-document in OpenOffice - then no fonts are embedded in the output-file.

How can I work around this - avoid the fonts to be included in the output-file when I use the spire.doc component?

#Load doc file
$doc = New-Object Spire.Doc.Document
$doc.LoadFromFile($sourceFile)

$dialog = New-Object System.Windows.Forms.PrintDialog
$dialog.PrintToFile = $true;
$dialog.PrinterSettings.PrinterName = $printerName
$dialog.PrinterSettings.PrintFileName = $destinationFile
$dialog.PrinterSettings.PrintToFile = $true

$doc.PrintDialog = $dialog;
$dialog.Document = $doc.PrintDocument;
$dialog.Document.Print();

janjalka
 
Posts: 2
Joined: Thu Nov 06, 2014 9:03 pm

Tue Nov 25, 2014 8:18 am

Hello,

Thanks for your feedback.
I have discussed with Dev team whether fonts are embedded in the output-file depends on the printer, our Spire.Doc product is not able to control it.
Thanks,
Gary
E-iceblue support team
User avatar

Gary.zhang
 
Posts: 1380
Joined: Thu Apr 04, 2013 1:30 am

Tue Nov 25, 2014 12:09 pm

Thank you for your reply.

I do however not understand why this not under your control. When I print the same document on the same Machine using the same printer using OpenOffice, then the builtin-fonts of the printer is not embedded in the printfile. Using spire.doc all fonts are embedded.

Could you please revise this issue?

Regards, Jan

janjalka
 
Posts: 2
Joined: Thu Nov 06, 2014 9:03 pm

Wed Nov 26, 2014 8:08 am

Hello,

Thanks for your response. Sorry that it is impossible for us to revise this issue, the reason is that our product is only intermediate medium, which draws the document to emf file and Microsoft GDI+ prints the emf, so at last how to print the document depends on the microsoft, so it is not under our control.
Sincerely,
Gary
E-iceblue support team
User avatar

Gary.zhang
 
Posts: 1380
Joined: Thu Apr 04, 2013 1:30 am

Return to Spire.Doc