I want to print a 300 dpi pdf file using wpdf 2.0.
so I tried this code:
Code
with WPRichText1.Header do
begin
// the page width and height are only internaly skipped when
// printing in landscape
if Landscape then
begin
end
else
begin
PDFPrinter.StartPage(MulDiv(PageWidth, 300, 1440),
MulDiv(PageHeight, 300, 1440),
300, 300, 0);
OutRect := Rect(0, 0, MulDiv(PageWidth, 300, 1440), MulDiv(PageHeight, 300, 1440));
end;
WPRichText1.PrintPageOnCanvas(PDFPrinter.Canvas, outRect, counter, [ppmUseBorders], 100);// MulDiv(100, 600, 96)); //MulDiv(100, 1440, 300));
PDFPrinter.EndPage;
end;
Alles anzeigen
The page size is correct (DinA4) but the printed page is somewhat shrinked (when referencing a 600 dpi Printer (used in Reference DC))
Also the Canvas to print does not have 300 dpi as promised in the description of StartPage, it has 600 or 96 dpi (depending on the referenced
printer property).
Do I miss something or is there something wrong with wpdf?
kind regards
Michael Rabatscher