1
0
mirror of https://github.com/moparisthebest/Simba synced 2024-12-23 15:58:51 -05:00

Merge ssh://villavu.com:54367/simba

This commit is contained in:
Niels 2010-05-19 13:35:52 +02:00
commit 9b2683d61b
5 changed files with 28 additions and 16 deletions

View File

@ -1,7 +1,7 @@
object SimbaForm: TSimbaForm
Left = 143
Left = 483
Height = 623
Top = 115
Top = 95
Width = 660
AllowDropFiles = True
Caption = 'THA FUKING Simba'
@ -3098,10 +3098,11 @@ object SimbaForm: TSimbaForm
NumberAttri.Foreground = clNavy
StringAttri.Foreground = clBlue
SymbolAttri.Foreground = clRed
CaseLabelAttri.Style = [fsItalic]
DirectiveAttri.Foreground = clRed
DirectiveAttri.Style = [fsBold]
CompilerMode = pcmObjFPC
NestedComments = True
NestedComments = False
left = 528
top = 200
end
@ -3112,7 +3113,7 @@ object SimbaForm: TSimbaForm
NumberAttri.Foreground = clHotLight
StringAttri.Foreground = clFuchsia
CompilerMode = pcmObjFPC
NestedComments = True
NestedComments = False
left = 568
top = 200
end

View File

@ -46,7 +46,7 @@ uses
CastaliaSimplePasPar, v_AutoCompleteForm, PSDump;
const
SimbaVersion = 675;
SimbaVersion = 676;
type

View File

@ -24,13 +24,13 @@
function ps_FindDTM(DTM: Integer; var x, y: Integer; xs, ys, xe, ye: Integer): Boolean; extdecl;
begin
with CurrThread.Client do
result := MFinder.FindDTM(MDTM.GetDTM(DTM),x,y,xs,ys,xe,ye);
result := MFinder.FindDTM(MDTM.GetDTM(DTM)^,x,y,xs,ys,xe,ye);
end;
function ps_FindDTMs(DTM: Integer; var p: TPointArray; xs, ys, xe, ye: Integer): Boolean; extdecl;
begin
with CurrThread.Client do
result := MFinder.FindDTMs(MDTM.GetDTM(DTM), p, xs, ys, xe, ye);
result := MFinder.FindDTMs(MDTM.GetDTM(DTM)^, p, xs, ys, xe, ye);
end;
function ps_FindDTMRotatedAlternating(DTM: Integer; var x, y: Integer; xs, ys, xe, ye:
@ -38,7 +38,7 @@ function ps_FindDTMRotatedAlternating(DTM: Integer; var x, y: Integer; xs, ys, x
var aFound: Extended): Boolean; extdecl;
begin
with CurrThread.Client do
result := MFinder.FindDTMRotated(MDTM.GetDTM(DTM), x,y, xs, ys, xe, ye, sAngle, eAngle, aStep, aFound,true);
result := MFinder.FindDTMRotated(MDTM.GetDTM(DTM)^, x,y, xs, ys, xe, ye, sAngle, eAngle, aStep, aFound,true);
end;
function ps_FindDTMRotatedSE(DTM: Integer; var x, y: Integer; xs, ys, xe, ye:
@ -46,20 +46,20 @@ function ps_FindDTMRotatedSE(DTM: Integer; var x, y: Integer; xs, ys, xe, ye:
var aFound: Extended): Boolean; extdecl;
begin
with CurrThread.Client do
result := MFinder.FindDTMRotated(MDTM.GetDTM(DTM), x, y, xs, ys, xe, ye, sAngle, eAngle, aStep, aFound,false);
result := MFinder.FindDTMRotated(MDTM.GetDTM(DTM)^, x, y, xs, ys, xe, ye, sAngle, eAngle, aStep, aFound,false);
end;
function ps_FindDTMsRotatedAlternating(DTM: Integer; var Points: TPointArray; xs, ys, xe, ye: Integer; sAngle, eAngle, aStep: Extended; var aFound: T2DExtendedArray): Boolean; extdecl;
begin
with CurrThread.Client do
result := MFinder.FindDTMsRotated(MDTM.GetDTM(DTM), Points, xs, ys, xe, ye,
result := MFinder.FindDTMsRotated(MDTM.GetDTM(DTM)^, Points, xs, ys, xe, ye,
sAngle, eAngle, aStep, aFound, true);
end;
function ps_FindDTMsRotatedSE(DTM: Integer; var Points: TPointArray; xs, ys, xe, ye: Integer; sAngle, eAngle, aStep: Extended; var aFound: T2DExtendedArray): Boolean; extdecl;
begin
with CurrThread.Client do
result := MFinder.FindDTMsRotated(MDTM.GetDTM(DTM), Points, xs, ys, xe, ye,
result := MFinder.FindDTMsRotated(MDTM.GetDTM(DTM)^, Points, xs, ys, xe, ye,
sAngle, eAngle, aStep, aFound, false);
end;
@ -81,7 +81,7 @@ end;
function ps_GetDTM(index: Integer) : pDTM; extdecl;
begin
result := CurrThread.Client.MDTM.GetDTM(index);
result := CurrThread.Client.MDTM.GetDTM(index)^;
end;
function ps_AddDTM(const d: TDTM): Integer; extdecl;

View File

@ -587,7 +587,8 @@ procedure TPSThread.OnProcessDirective(Sender: TPSPreProcessor;
Parser: TPSPascalPreProcessorParser; const Active: Boolean;
const DirectiveName, DirectiveParam: string; var Continue: Boolean);
begin
Continue := ProcessDirective(DirectiveName, DirectiveParam);
if CompareText(DirectiveName, 'LOADLIB') = 0 then
Continue := not ProcessDirective(DirectiveName,DirectiveParam);
end;
function TPSThread.PSScriptFindUnknownFile(Sender: TObject;

View File

@ -43,9 +43,10 @@ type
public
function AddDTM(const d: TDTM): Integer;
function AddpDTM(const d: pDTM): Integer;
function GetDTM(index: Integer) :pDTM;
function GetDTM(index: Integer) :ppDTM;
procedure FreeDTM(DTM: Integer);
function StringToDTM(const S: String): pDTM;
function DTMToString(const DTM : PDTM) : string;
procedure SetDTMName(DTM: Integer;const S: String);
constructor Create(Owner: TObject);
destructor Destroy; override;
@ -169,6 +170,15 @@ begin
result.l := length(result.p);
end;
function TMDTM.DTMToString(const DTM: PDTM): string;
var
i : integer;
begin
if DTM.l = 0 then
exit;
end;
procedure TMDTM.CheckIndex(index: integer);
begin
if (index < 0) or (index >= Length(DTMList)) or (DTMList[Index] = nil) then
@ -210,10 +220,10 @@ end;
Returns true is succesfull, false if the dtm does not exist.
/\}
function TMDTM.GetDTM(index: Integer) :pDTM;
function TMDTM.GetDTM(index: Integer) :ppDTM;
begin
CheckIndex(index);
result := DTMList[index]^;
result := DTMList[index];
end;
procedure TMDTM.SetDTMName(DTM: Integer;const s: string);