#1 2015-09-04 09:37:15

uian2000
Member
Registered: 2014-05-06
Posts: 69

Maybe mis-config of selftest at TTestSynopsePDF._TPdfDocument?

hi,ab

My TestSQL3.exe always fail on TPdfCoument, no matter which compiler I've used, D7/TurboDelphi(D2006)/DXE.
When I tried launch this TestSQL3.exe using NTLEA at local East-Euro, test passed successfully.
I made the tester saving the perducted pdf-document using both way, and compared them.
Difference appears.

Here is my local, cp936

<</Type/Font/Subtype/Type1/Encoding/WinAnsiEncoding/FirstChar 32/LastChar 255/BaseFont/Helvetica/Name/F0>>


endobj
xref
0 7
0000000000 65535 f
0000000009 00000 n
0000000076 00000 n
0000000182 00000 n
0000000233 00000 n
0000000383 00000 n
0000000749 00000 n

trailer
<</Size 7/Root 1 0 R/Info 2 0 R>>
startxref
871
%%EOF

And this is cp1252

<</Type/Font/BaseFont/Arial/Subtype/TrueType/Encoding/WinAnsiEncoding/FontDescriptor 7 0 R/Name/F0/FirstChar 32/LastChar 233/Widths [500 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 500 500 500 500 500 500 500 500 500 500 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 500 0 0 0 0 0 0 0 0 0 0 0 0 500 0 500 0 500 0 0 0 0 0 0 0 0 500 0 0 0 0 0 500 500 0 0 500 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 500 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 500 ]>>
endobj
7 0 obj
<</Type/FontDescriptor/FontName/Arial/Ascent 859/CapHeight 666/Descent -141/ItalicAngle 0/StemV 87/Flags 32/FontBBox[-8 -145 1000 859]>>

endobj
xref
0 8
0000000000 65535 f
0000000009 00000 n
0000000076 00000 n
0000000182 00000 n
0000000233 00000 n
0000000383 00000 n
0000000749 00000 n
0000001347 00000 n
trailer
<</Size 8/Root 1 0 R/Info 2 0 R>>
startxref
1499
%%EOF

Maybe we should make TPdfDocument writing contents with more exact params?
I've tried

begin
  MS := THeapMemoryStream.Create;
  with TPdfDocument.Create(False, 1252) do
  try
    for embed := false to true do begin
      Info.CreationDate := FIXED_DATE; // no FIXED_DATE nor creator variation in hashed value
      Info.Data.PdfTextByName('Producer').Value := 'Synopse PDF engine';
      StandardFontsReplace := embed;
      AddPage;

, but it dosen't make sense.

Anything help?

Offline

Board footer

Powered by FluxBB