NMIMT85
November 28th, 2007, 10:38 AM
I'm using your demo download to evaluate the Foxit Reader DLL SDK. I'm seeing a difference in print outs between printing from Adobe Reader and the Foxit DLL. The Foxit DLL places blocks of text either lower or higher (some blocks are too low, some blocks are too high) than Adobe and also positions blocks in different horizontal locations than Adobe (some blocks are slightly to the left, some are slightly to the right). Finally, the DLL "squishes" lines of text. Even accomodating for the horizontal shift, lines of text printed by the DLL are slightly shorter than lines of text printed by Adobe. It looks like the characters are the right size, but the DLL has a different idea of the kerning between the letters. The intraword spacing seems to be OK.
We'd really like to use Foxit as an alternative to Adobe Reader. We've got several hundred mobile devices (which fall somewhere between a handheld PC and a laptop) in the field that are used to print window stickers for automotive dealerships, and the lightweight footprint of the Foxit DLL is very attractive. But text placement is very critical on these window stickers and we need true fidelity between the PDF and the printout.
Is this erroneous text placement a function of the demo version of the DLL, or am I calling it incorrectly? I've printed from both the VB demo download (ReaderVB) and from a C# app I threw together, with different results from both. The Renderpage call in your VB Demo program is
FPDF_RenderPage Printer.hDC, PrintPage, 0, 0, Printer.ScaleWidth, Printer.ScaleHeight, 0, 0
and the Renderpage call I'm using in my C# app is
int size_x = (int)(ev.PageSettings.PaperSize.Width/100 * ev.Graphics.DpiX);
int size_y = (int)(ev.PageSettings.PaperSize.Height/100 * ev.Graphics.DpiY);
Foxit.FPDFView.FPDF_RenderPage(ev.Graphics.GetHdc( ), pdf_page, 0, 0, size_x, size_y, 0, 0);
where ev is a PrintPageEventArgs variable supplied by C# when the Print event is fired from a System.Drawing.Printing.PrintDocument object.
Mary McClure
Software Engineer
Kelley Blue Book
The Trusted Resource
www.kbb.com
We'd really like to use Foxit as an alternative to Adobe Reader. We've got several hundred mobile devices (which fall somewhere between a handheld PC and a laptop) in the field that are used to print window stickers for automotive dealerships, and the lightweight footprint of the Foxit DLL is very attractive. But text placement is very critical on these window stickers and we need true fidelity between the PDF and the printout.
Is this erroneous text placement a function of the demo version of the DLL, or am I calling it incorrectly? I've printed from both the VB demo download (ReaderVB) and from a C# app I threw together, with different results from both. The Renderpage call in your VB Demo program is
FPDF_RenderPage Printer.hDC, PrintPage, 0, 0, Printer.ScaleWidth, Printer.ScaleHeight, 0, 0
and the Renderpage call I'm using in my C# app is
int size_x = (int)(ev.PageSettings.PaperSize.Width/100 * ev.Graphics.DpiX);
int size_y = (int)(ev.PageSettings.PaperSize.Height/100 * ev.Graphics.DpiY);
Foxit.FPDFView.FPDF_RenderPage(ev.Graphics.GetHdc( ), pdf_page, 0, 0, size_x, size_y, 0, 0);
where ev is a PrintPageEventArgs variable supplied by C# when the Print event is fired from a System.Drawing.Printing.PrintDocument object.
Mary McClure
Software Engineer
Kelley Blue Book
The Trusted Resource
www.kbb.com