Hello,
I have a problem with font sizes in PDF output report.
For example in Designer I have text element with "Arial Bold 12pt" font.
But when I analize PDF output (by Python miner for example) I get "Arial Bold 11.46pt".
That is 11.46 instead of 12 pt.
Is it a bug or I do something wrong?
Wrong font size in PDF output
Re: Wrong font size in PDF output
I resolved this problem by one code string when I generate pdf file:
StiPdfExportService.CompatibleMode160 = true;
I do not know what exactly CompatibleMode160 means, I just found in the code that Stimulsoft multiplies real font size on 0.955 when this parameter is false.
StiPdfExportService.CompatibleMode160 has no documentation (https://admin.stimulsoft.com/documentat ... fce16e.htm).
If somebody knows what it means I will be happy to find out this information.
StiPdfExportService.CompatibleMode160 = true;
I do not know what exactly CompatibleMode160 means, I just found in the code that Stimulsoft multiplies real font size on 0.955 when this parameter is false.
StiPdfExportService.CompatibleMode160 has no documentation (https://admin.stimulsoft.com/documentat ... fce16e.htm).
If somebody knows what it means I will be happy to find out this information.
-
- Posts: 6263
- Joined: Tue Mar 20, 2018 5:34 am
Re: Wrong font size in PDF output
Hello,
Initially, there were some uncertainties in WinForms GDI+ with 96/100 dpi printing problem, from NET 1.0 and we took 100dpi by default in all calculations.
It later turned out that it would be more correct to use 96dpi but to maintain backward compatibility, we didn't fix it anymore.
And when printing and exporting, all sizes are scaled to match the preview. that's why the font is smaller in the pdf file.
But as a whole, the kind of report in a preview, after the print and in a pdf-file are same.
CompatibleMode160 is compatible with version 1.60, which was released 15 years ago, and after which this scaling was added.
Thank you.
Initially, there were some uncertainties in WinForms GDI+ with 96/100 dpi printing problem, from NET 1.0 and we took 100dpi by default in all calculations.
It later turned out that it would be more correct to use 96dpi but to maintain backward compatibility, we didn't fix it anymore.
And when printing and exporting, all sizes are scaled to match the preview. that's why the font is smaller in the pdf file.
But as a whole, the kind of report in a preview, after the print and in a pdf-file are same.
CompatibleMode160 is compatible with version 1.60, which was released 15 years ago, and after which this scaling was added.
Thank you.