From bc7c429195bbc7f43c76d64ff4f91637dd70167e Mon Sep 17 00:00:00 2001 From: Merlijn Wajer Date: Thu, 9 Sep 2010 16:40:57 +0200 Subject: [PATCH] Documentation changes. --- Doc/sphinx/referencescript.rst | 2 + Doc/sphinx/scriptref/dtm.rst | 152 +++++++++++++++++++++++++++++ Doc/sphinx/scriptref/files.rst | 170 ++++++++++++++++++++++++++++++++- 3 files changed, 323 insertions(+), 1 deletion(-) create mode 100644 Doc/sphinx/scriptref/dtm.rst diff --git a/Doc/sphinx/referencescript.rst b/Doc/sphinx/referencescript.rst index 4c053e5..3118f46 100644 --- a/Doc/sphinx/referencescript.rst +++ b/Doc/sphinx/referencescript.rst @@ -14,3 +14,5 @@ default (Pascal) engine. scriptref/colourfinding.rst scriptref/colourconverting.rst scriptref/files.rst + scriptref/ocr.rst + scriptref/dtm.rst diff --git a/Doc/sphinx/scriptref/dtm.rst b/Doc/sphinx/scriptref/dtm.rst new file mode 100644 index 0000000..b348f2e --- /dev/null +++ b/Doc/sphinx/scriptref/dtm.rst @@ -0,0 +1,152 @@ + +.. _scriptref_dtm: + +Deformable Template Models (DTM) +============================== + +DTMFromString +------------- + +.. code-block:: pascal + + function DTMFromString(const DTMString: String): Integer; + + +SetDTMName +---------- + +.. code-block:: pascal + + procedure SetDTMName(DTM : integer;const name : string); + + +FreeDTM +------- + +.. code-block:: pascal + + procedure FreeDTM(DTM: Integer); + + +FindDTM +------- + +.. code-block:: pascal + + function FindDTM(DTM: Integer; var x, y: Integer; + xs, ys, xe, ye: Integer): Boolean; + + +FindDTMs +-------- + +.. code-block:: pascal + + function FindDTMs(DTM: Integer; var p: TPointArray; + xs, ys, xe, ye: Integer): Boolean; + + +FindDTMRotatedSE +---------------- + +.. code-block:: pascal + + function FindDTMRotatedSE(DTM: Integer; var x, y: Integer; + xs, ys, xe, ye: Integer; sAngle, eAngle, aStep: Extended; + var aFound: Extended): Boolean; + + +FindDTMRotatedAlternating +------------------------- + +.. code-block:: pascal + + function FindDTMRotatedAlternating(DTM: Integer; var x, y: Integer; + xs, ys, xe, ye: Integer; + sAngle, eAngle, aStep: Extended; var aFound: Extended): Boolean; + + +FindDTMsRotatedSE +----------------- + +.. code-block:: pascal + + function FindDTMsRotatedSE(DTM: Integer; var Points: TPointArray; + xs, ys, xe, ye: Integer; sAngle, eAngle, aStep: Extended; + var aFound: T2DExtendedArray) : Boolean; + + +FindDTMsRotatedAlternating +-------------------------- + +.. code-block:: pascal + + function FindDTMsRotatedAlternating(DTM: Integer; + var Points: TPointArray; xs, ys, xe, ye: Integer; sAngle, eAngle, aStep: + Extended; var aFound: T2DExtendedArray) : Boolean; + + +AddMDTM +------- + +.. code-block:: pascal + + function AddMDTM(const d: TMDTM): Integer; + + +AddDTM +------ + +.. code-block:: pascal + + function AddDTM(const d: TMDTM): Integer; + + +AddSDTM +------- + +.. code-block:: pascal + + function AddSDTM(const d: TSDTM): Integer; + + +GetDTM +------ + +.. code-block:: pascal + + function GetDTM(index: Integer) : TMDTM + + +SDTMToMDTM +---------- + +.. code-block:: pascal + + function SDTMToMDTM(Const DTM: TSDTM): TMDTM; + + +PrintDTM +-------- + +.. code-block:: pascal + + procedure PrintDTM(const DTM : TMDTM); + + +MDTMToSDTM +---------- + +.. code-block:: pascal + + function MDTMToSDTM(Const DTM: TMDTM): TSDTM; + + +CreateDTMPoint +-------------- + +.. code-block:: pascal + + function CreateDTMPoint(x,y,c,t,asz : integer; bp : boolean) : TMDTMPoint; + + diff --git a/Doc/sphinx/scriptref/files.rst b/Doc/sphinx/scriptref/files.rst index 481cac2..403d551 100644 --- a/Doc/sphinx/scriptref/files.rst +++ b/Doc/sphinx/scriptref/files.rst @@ -1,4 +1,172 @@ Working with Files ================== -Well... +CreateFile +---------- + +.. code-block:: pascal + + function CreateFile(const Path: string): Integer; + + +OpenFile +-------- + +.. code-block:: pascal + + function OpenFile(const Path: string; Shared: Boolean): Integer; + + +RewriteFile +----------- + +.. code-block:: pascal + + function RewriteFile(const Path: string; Shared: Boolean): Integer; + + +AppendFile +---------- + +.. code-block:: pascal + + function AppendFile(const Path: string): Integer; + + +CloseFile +--------- + +.. code-block:: pascal + + procedure CloseFile(FileNum: Integer); + + +EndOfFile +--------- + +.. code-block:: pascal + + function EndOfFile(FileNum: Integer): Boolean; + + +FileSize +-------- + +.. code-block:: pascal + + function FileSize(FileNum: Integer): LongInt; + + +ReadFileString +-------------- + +.. code-block:: pascal + + function ReadFileString(FileNum: Integer; var s: string; x: Integer): + Boolean; + + +WriteFileString +--------------- + +.. code-block:: pascal + + function WriteFileString(FileNum: Integer; s: string): Boolean; + + +SetFileCharPointer +------------------ + +.. code-block:: pascal + + function SetFileCharPointer(FileNum, cChars, Origin: Integer): Integer; + + +FilePointerPos +-------------- + +.. code-block:: pascal + + function FilePointerPos(FileNum: Integer): Integer; + + +DirectoryExists +--------------- + +.. code-block:: pascal + + function DirectoryExists(const DirectoryName : string ) : Boolean; + + +CreateDirectory +--------------- + +.. code-block:: pascal + + function CreateDirectory(const DirectoryName : string) : boolean; + + +FileExists +----------- + +.. code-block:: pascal + + function FileExists (const FileName : string ) : Boolean; + + +ForceDirectories +---------------- + +.. code-block:: pascal + + function ForceDirectories(const dir : string) : boolean; + + +GetFiles +-------- + +.. code-block:: pascal + + function GetFiles(const Path, Ext : string) : TStringArray; + + +GetDirectories +-------------- + +.. code-block:: pascal + + function GetDirectories(const path : string) : TStringArray; + + +WriteINI +-------- + +.. code-block:: pascal + + procedure WriteINI(const Section, KeyName, NewString, FileName: string); + + +ReadINI +------- + +.. code-block:: pascal + + function ReadINI(const Section, KeyName, FileName: string): string; + + +DeleteINI +--------- + +.. code-block:: pascal + + procedure DeleteINI(const Section, KeyName, FileName: string); + + +ExtractFileExt +-------------- + +.. code-block:: pascal + + function ExtractFileExt(const FileName: string): string;'); + +