#1 Re: PDF Engine » PDFEngine Clipping Implementation + Output stream optimizations » 2022-06-09 17:38:15

Hi,
great Work. Please can you manage to merge it into the synopse main branch?

best regards!

#2 Re: mORMot 1 » SynCommon-Synopse.inc: CPUINTEL not defined » 2016-12-03 17:28:24

Still Win64 PurePascal problems, win32 is okay (todays trunk):

PDF\Synopse.inc(574)
PDF\Synopse.inc(574)
PDF\SynLZ.pas(1252)
PDF\SynopseCommit.inc(2)
PDF\SynCommons.pas(36842) Error: E2003 Undeclared identifier: 'CpuFeatures'
PDF\SynCommons.pas(36842) Error: E2015 Operator not applicable to this operand t
ype
PDF\SynCommons.pas(39857) Error: E2003 Undeclared identifier: 'RedirectCode'
PDF\SynCommons.pas(61259)

#3 Re: mORMot 1 » SynCommon-Synopse.inc: CPUINTEL not defined » 2016-12-02 19:27:14

ab wrote:

No problem to compile to Win64 on my side, with Delphi XE6 and 10.1.
Regression tests do pass.

With Win64 and switch PUREPASCAL too?

#5 mORMot 1 » SynCommon-Synopse.inc: CPUINTEL not defined » 2016-12-01 20:16:39

RalfS
Replies: 6

SynCommon.pas is not compilable with switch PUREPASCAL on Delphi 7, because CPUINTEL is not set correctly at all. Trunk from today.

#6 Re: mORMot 1 » SynCommon trunk does not compile under Delphi 64bit » 2016-08-06 17:26:28

I forgot to mention: I am using the PurePascal switch. It was something with the CPUId stuff

#10 Re: mORMot 1 » Trunk compilation fails » 2015-09-30 08:25:15

It is fixed. Thanks!


ab wrote:

Should be fixed by http://synopse.info/fossil/info/0796c1e9a2

Thanks for the feedback.

#11 mORMot 1 » Trunk compilation fails » 2015-09-27 15:15:14

RalfS
Replies: 2

Trunk compilation with define PurePascal and D6 fails.

#12 mORMot 1 » Compiler error D6 & SynCommon.pas » 2015-05-02 16:20:17

RalfS
Replies: 1

D6 does not compile SynCommon.pas (purepascal mode). AtomicIncrement/Decrement is unknown.

#13 Re: mORMot 1 » Automatic TSQLRecord memory handling » 2014-11-14 16:56:34

I do this in similar form since years, but be careful: It does not work under FPC. FPCs IUnknown is working differently from Delphi' one. For details, please look at FPC bug tracker.
http://bugs.freepascal.org/view.php?id=26602

#14 Re: PDF Engine » Use SynPdf to set metafile canvas size » 2014-11-01 17:04:39

Be careful: Metafiles have a limitation of 96 dpi (the screen dpi) per default.

#16 PDF Engine » Creating a PDF file with 2400 dpi » 2014-10-18 01:45:56

RalfS
Replies: 1

Is it possible to create a PDF file with 2400 dpi and higher with SynPDF?

#18 Re: PDF Engine » SynPDF is working internally with wrong scale » 2014-10-08 08:33:02

You mean pdf has 72 dpi and metafile 100dpmm=2540dpi?

#19 PDF Engine » SynPDF is working internally with wrong scale » 2014-10-07 20:08:54

RalfS
Replies: 4

The code below should produce a PDF file in A4 size with an ellipse inside touching the borders of A4 sheet.But it does not. A scale of 1.333 is needed instead of 1.0 to reach that.


procedure SaveAsPdf;
var
  MetaFile: TMetafile;
  MetaFileCanvas: TMetafileCanvas;
  Pdf: TPdfDocument; //TPdfDocumentGDI ???
begin
  Pdf := TPdfDocument.Create;
  try
    //psA4, psA5, psA3, psLetter, psLegal, psUserDefined
    Pdf.DefaultPaperSize := psA4;

    Log('DefaultPageWidth: %d', [Pdf.DefaultPageWidth]);     
    Log('DefaultPageHeight: %d', [Pdf.DefaultPageHeight]);
    // 595 =  210 mm * 72 dpi
    // 842 =  297 mm * 72 dpi

    Metafile := TMetafile.Create;
    MetaFileCanvas := TMetaFileCanvas.Create(Metafile, 0);
    try
      MetaFileCanvas.Ellipse(Rect(0, 0, 594, 841));
    finally
      MetaFileCanvas.Free;
    end;

    Pdf.NewDoc;
    Pdf.AddPage;
    Pdf.Canvas.RenderMetaFile(Metafile, 1.3333333, 0, 0);
    Pdf.SaveToFile('c:\test1.pdf');
  finally
    Pdf.Free;
  end;
end;

#20 Re: PDF Engine » SynPDF bug » 2014-10-03 23:03:25

I noticed that. :-) But it won't compile without it.

#21 Re: mORMot 1 » SynCommon.pas » 2014-10-03 15:50:40

RedirtectCode is being called in SynRegisterCustomVariantType when  DoPatchRTL is off.

#22 PDF Engine » SynPDF bug » 2014-10-03 15:43:35

RalfS
Replies: 3

InitCrc32Tab not found, when undefing use_synzip. Does it belong to SynPDF at all?

#24 Re: mORMot 1 » SynCommon.pas » 2014-09-30 14:44:30

You should apply bugfix1 first. Second question: What is PurePascal for when its not a solution?

#25 Re: mORMot 1 » SynCommon.pas » 2014-09-28 21:00:00

I had several crashes of program and debugger in D6. Undefing DOPATCHTRTL and using PurePascal solve 2 of them. See post above. I prefer not having manipulations on my RTL/VCL. This is the cause for most problems I had so far.

#26 Re: mORMot 1 » SynCommon.pas » 2014-09-27 21:02:53

bugfix3:


Following procedures don't respect the PurePascal define:

function SystemFillCharAddress: Pointer;
procedure CopyArray(dest, source, typeInfo: Pointer; cnt: PtrUInt);
procedure _Finalize(Data: Pointer; TypeInfo: Pointer);
procedure RecordCopy(var Dest; const Source; TypeInfo: pointer);
procedure RecordClear(var Dest; TypeInfo: pointer);
function VariantsDispInvokeAddress: pointer;
procedure _DynArrayClear(var a: Pointer; typeInfo: Pointer);
procedure _FinalizeArray(p: Pointer; typeInfo: Pointer; elemCount: PtrUInt);
procedure SynRtlUnwind(TargetFrame, TargetIp: pointer; ExceptionRecord: PExceptionRecord; ReturnValue: Pointer); stdcall;
function TSynLog._Release: Integer;
class function TSynLog.Enter(aInstance: TObject; aMethodName: PUTF8Char; aMethodNameLocal: boolean): ISynLog;
procedure TSynLog.Log(Level: TSynLogInfo);
procedure AddStackManual(Stack: PPtrUInt);

64bit:
function StrInt32(P: PAnsiChar; val: PtrInt): PAnsiChar;
function StrUInt32(P: PAnsiChar; val: PtrUInt): PAnsiChar;
function bswap32(a: cardinal): cardinal; {$ifdef FPC}nostackframe; assembler;{$endif}
function StrLen(S: pointer): PtrInt;

#27 Re: mORMot 1 » SynCommon.pas » 2014-09-27 20:29:08

bugfix1:

  {$ifdef DOPATCHTRTL}
  if DebugHook=0 then // patch VCL/RTL only outside debugging
    InitRedirectCode;
  {$endif}

bugfix2:

{$define PUREPASCAL}

#28 Re: mORMot 1 » SynCommon.pas » 2014-09-27 14:20:06

This unit does not work with D6 very well.

I get not reproducible Debugger crash (Delphi 6) here:

InitSynCommonConversionTables;
or
RetrieveSystemInfo;

#29 Re: mORMot 1 » SynCommon.pas » 2014-09-26 23:07:02

This unit does not work with D6 very well.

I get not reproducible Debugger crash (Delphi 6) here:

InitSynCommonConversionTables;
or
RetrieveSystemInfo;

#30 mORMot 1 » SynCommon.pas » 2014-09-26 17:53:03

RalfS
Replies: 15

Please would you split up SynCommon.pas into at least 10 units? 1.5MB is very hard to handle. Half an hour for scrolling bothers...
Thank you!

#31 Re: mORMot 1 » Wrong assembler code in SynCommon » 2014-08-08 14:50:05

I still saw the error several times in the Nightly Build zip from today.

#33 mORMot 1 » Freepascal compilation issue with trunk » 2014-05-29 15:03:58

RalfS
Replies: 6

.
Compiling PDF\SynCommons.pas
SynCommons.pas(8475,14) Error: There is no method in an ancestor class to be ove
rridden: "FixupIdent(const AnsiString):AnsiString;"
SynCommons.pas(10995,1) Fatal: There were 1 errors compiling module, stopping
Fatal: Compilation aborted
Error: d:\lazarus\fpc\2.7.1\bin\i386-win32\ppc386.exe returned an error exitcode

#34 Re: PDF Engine » PDF fails on Delphi 6 » 2014-05-29 15:02:49

One more Delphi 6 compilation issue:

function TJSONCustomParserCustomRecord.CustomReader(P: PUTF8Char;
  var aValue; out EndOfObject: AnsiChar): PUTF8Char;
var valid: boolean;
begin
  result := GetJSONCustomParserRegistration.Reader(P,aValue,valid); //<---------------------------D6: Internal error: C3890
  if not valid then
    result := nil;
  if result=nil then
    exit;
  EndOfObject := result^;
  if result^ in [',','}',']'] then
    inc(result);
end;

[Fatal Error] SynCommons.pas(25431): Internal error: C3890

#36 Re: PDF Engine » PDF fails on Delphi 6 » 2014-04-20 15:02:27

TsysAnsiConvert.Engine causes an floating point error in TSynAnsiFixedWidth.Create(1252) -> Move procedure.

#37 Re: PDF Engine » PDF fails on Delphi 6 » 2014-04-19 16:50:33

Still having problem with SysCommon and D6. Runtime errors. ? Don't know whats wrong.

#38 PDF Engine » PDF fails on Delphi 6 » 2014-04-18 11:28:29

RalfS
Replies: 9

PDF Engine does not work under D6. SysCommon causes a run time error during initialisation. Moreover ifdef Variants make problems.

#39 Re: PDF Engine » SynPdf library 1.18 » 2012-12-21 12:01:57

All compilation hints are gone now in D6..XE3. Thanks.

#40 Re: PDF Engine » SynPdf library 1.18 » 2012-12-03 23:53:12

Some XE3 compiler issues:

PDF\SynPdf.pas(2686) Hint: H2443 Inline function 'Point' has not been expanded because unit 'System.Types' is not specified in USES list
PDF\SynPdf.pas(3058) Hint: H2443 Inline function 'TList.Remove' has not been expanded because unit 'System.Types' is not specified in USES list
PDF\SynPdf.pas(3267) Hint: H2443 Inline function 'TList.Remove' has not been expanded because unit 'System.Types' is not specified in USES list
PDF\SynPdf.pas(6162) Warning: W1057 Implicit string cast from 'AnsiString' to 'string'
PDF\SynPdf.pas(6239) Warning: W1000 Symbol 'ByteType' is deprecated: 'Moved to the AnsiStrings unit'
PDF\SynPdf.pas(6245) Warning: W1000 Symbol 'ByteType' is deprecated: 'Moved to the AnsiStrings unit'
PDF\SynPdf.pas(7485) Warning: W1057 Implicit string cast from 'AnsiString' to 'string'
PDF\SynPdf.pas(7567) Warning: W1057 Implicit string cast from 'AnsiString' to 'string'
PDF\SynPdf.pas(8164) Hint: H2443 Inline function 'Point' has not been expanded because unit 'System.Types' is not specified in USES list
PDF\SynPdf.pas(8403) Hint: H2443 Inline function 'Point' has not been expanded because unit 'System.Types' is not specified in USES list
PDF\SynPdf.pas(8420) Hint: H2443 Inline function 'Point' has not been expanded because unit 'System.Types' is not specified in USES list

#41 Re: PDF Engine » Rendering meta file does not work » 2012-10-24 21:36:44

I have the same problems with Metafiles rendering.

#43 mORMot 1 » SynCommon trunk does not compile » 2012-09-12 14:41:32

RalfS
Replies: 2

with Delphi XE2 64 bit and FPC 32 bit. Some kind of ifdef mismatch I guess.

#44 PDF Engine » Trunk compilation error with D2009 and Delphi XE2 (64bit only) » 2012-08-12 16:59:43

RalfS
Replies: 0

D2009:

CodeGear Delphi for Win32 compiler version 20.0
Copyright (c) 1983,2008 CodeGear
PDF\SynLZ.pas(1151)
PDF\SynCommons.pas(24283) Error: E2250 There is no overloaded version of 'Map'
hat can be called with these arguments
PDF\SynCommons.pas(24553) Error: E2003 Undeclared identifier: 'fFileLocal'
PDF\SynCommons.pas(24589) Error: E2003 Undeclared identifier: 'fFileLocal'
PDF\SynCommons.pas(24592) Error: E2037 Declaration of 'Map' differs from previ
s declaration
PDF\SynCommons.pas(24599) Error: E2003 Undeclared identifier: 'Map'
PDF\SynCommons.pas(24602) Error: E2003 Undeclared identifier: 'fFileLocal'
PDF\SynCommons.pas(24611) Error: E2003 Undeclared identifier: 'fFileLocal'
PDF\SynCommons.pas(29855) Error: E2250 There is no overloaded version of 'Map'
hat can be called with these arguments
PDF\SynCommons.pas(30612)



XE2 64 bit:

Embarcadero Delphi for Win64 compiler version 23.0
Copyright (c) 1983,2011 Embarcadero Technologies, Inc.

PDF\SynLZ.pas(1151)
PDF\SynCommons.pas(29094) Error: E2003 Undeclared identifier: 'SynLogFile'
PDF\SynCommons.pas(29094) Error: E2015 Operator not applicable to this operand
ype
PDF\SynCommons.pas(29099) Error: E2066 Missing operator or semicolon
PDF\SynCommons.pas(29101) Error: E2003 Undeclared identifier: 'SynLogFileIndex'
PDF\SynCommons.pas(29116) Error: E2003 Undeclared identifier: 'SynLogFile'
PDF\SynCommons.pas(29116) Error: E2015 Operator not applicable to this operand
ype
PDF\SynCommons.pas(29119) Error: E2029 'DO' expected but identifier 'Count' fou
d
PDF\SynCommons.pas(29120) Error: E2029 ')' expected but identifier 'List' found
PDF\SynCommons.pas(29208) Error: E2003 Undeclared identifier: 'SynLogFileIndex'
PDF\SynCommons.pas(29210) Error: E2003 Undeclared identifier: 'SynLogFile'
PDF\SynCommons.pas(29210) Error: E2066 Missing operator or semicolon



All other compiler compile smooth.

#45 Re: PDF Engine » App HALTING with SynPDF 1.16 (trunk) » 2012-03-31 13:55:40

Please try this

replace
{.$define PUREPASCAL}
with
{$define PUREPASCAL}

in synopse.inc

#46 PDF Engine » Any news on the PDF Engine for 64 bit? » 2011-11-24 23:35:29

RalfS
Replies: 1

Any news on the PDF Engine for 64 bit?

#47 Re: Fast JPEG decoder » error compiling jpegdec.pas under Delphi 5 » 2011-10-01 14:31:43

You have to find the op-codes of the asm commands. Then replace the asm by the op-codes.

#48 Re: PDF Engine » Synopse PDF Engine 1.15 » 2011-09-25 16:42:58

Yep. I think the main problem are the two zlib obj files which are needed in 64 bit style too.

#49 Re: PDF Engine » Synopse PDF Engine 1.15 » 2011-09-25 10:07:18

But without 64 bit compilation!?

#50 Re: mORMot 1 » Delphi 64 bit is out » 2011-09-03 10:25:55

ab wrote:

And in order to embed the SQLite3 engine as a static library, it will need some work about the C RTL.

There is a System.Win.Crtl.pas now that provides MS C RTL functions!

Board footer

Powered by FluxBB