+ WideSameStr

This commit is contained in:
florian 2005-02-26 15:00:14 +00:00
parent 7fef413b69
commit 7fa1ae2ea8
4 changed files with 29 additions and 15 deletions

View File

@ -62,7 +62,6 @@ Type
CompUCS4 : function(p1,p2:PUC42Char) : shortint; CompUCS4 : function(p1,p2:PUC42Char) : shortint;
} }
CompareWideStringProc : function(const s1, s2 : WideString) : PtrInt; CompareWideStringProc : function(const s1, s2 : WideString) : PtrInt;
SameWideStringProc : function(const s1, s2 : WideString) : Boolean;
CompareTextWideStringProc : function(const s1, s2 : WideString): PtrInt; CompareTextWideStringProc : function(const s1, s2 : WideString): PtrInt;
CharLengthPCharProc : function(const Str: PChar): PtrInt; CharLengthPCharProc : function(const Str: PChar): PtrInt;
end; end;
@ -86,7 +85,10 @@ Procedure SetWideStringManager (Const New : TWideStringManager; Var Old: TWideSt
{ {
$Log$ $Log$
Revision 1.4 2005-02-26 10:21:17 florian Revision 1.5 2005-02-26 15:00:14 florian
+ WideSameStr
Revision 1.4 2005/02/26 10:21:17 florian
+ implemented WideFormat + implemented WideFormat
+ some Widestring stuff implemented + some Widestring stuff implemented
* some Widestring stuff fixed * some Widestring stuff fixed

View File

@ -1418,19 +1418,14 @@ function CompareWideString(const s1, s2 : WideString) : PtrInt;
begin begin
unimplementedwidestring; unimplementedwidestring;
end; end;
function SameWideString(const s1, s2 : WideString) : Boolean;
begin
unimplementedwidestring;
end;
function CompareTextWideString(const s1, s2 : WideString): PtrInt; function CompareTextWideString(const s1, s2 : WideString): PtrInt;
begin begin
unimplementedwidestring; unimplementedwidestring;
end; end;
function CharLengthPChar(const Str: PChar): PtrInt; function CharLengthPChar(const Str: PChar): PtrInt;
begin begin
unimplementedwidestring; unimplementedwidestring;
@ -1443,8 +1438,7 @@ procedure initwidestringmanager;
widestringmanager.Ansi2WideMoveProc:=@Ansi2WideMove; widestringmanager.Ansi2WideMoveProc:=@Ansi2WideMove;
widestringmanager.UpperWideStringProc:=@GenericWideCase; widestringmanager.UpperWideStringProc:=@GenericWideCase;
widestringmanager.LowerWideStringProc:=@GenericWideCase; widestringmanager.LowerWideStringProc:=@GenericWideCase;
widestringmanager.CompareWideStringProc:=@CompareWideString; widestringmanager.CompareWideStringProc:=@CompareWideString;
widestringmanager.SameWideStringProc:=@SameWideString;
widestringmanager.CompareTextWideStringProc:=@CompareTextWideString; widestringmanager.CompareTextWideStringProc:=@CompareTextWideString;
widestringmanager.CharLengthPCharProc:=@CharLengthPChar; widestringmanager.CharLengthPCharProc:=@CharLengthPChar;
end; end;
@ -1452,7 +1446,10 @@ procedure initwidestringmanager;
{ {
$Log$ $Log$
Revision 1.52 2005-02-26 10:21:17 florian Revision 1.53 2005-02-26 15:00:14 florian
+ WideSameStr
Revision 1.52 2005/02/26 10:21:17 florian
+ implemented WideFormat + implemented WideFormat
+ some Widestring stuff implemented + some Widestring stuff implemented
* some Widestring stuff fixed * some Widestring stuff fixed

View File

@ -40,7 +40,7 @@ function WideCompareStr(const s1, s2 : WideString) : PtrInt;
function WideSameStr(const s1, s2 : WideString) : Boolean; function WideSameStr(const s1, s2 : WideString) : Boolean;
begin begin
result:=widestringmanager.SameWideStringProc(s1,s2); result:=widestringmanager.CompareWideStringProc(s1,s2)=0;
end; end;
@ -48,6 +48,13 @@ function WideCompareText(const s1, s2 : WideString) : PtrInt;
begin begin
result:=widestringmanager.CompareTextWideStringProc(s1,s2); result:=widestringmanager.CompareTextWideStringProc(s1,s2);
end; end;
function WideSameText(const s1, s2 : WideString) : Boolean;
begin
result:=widestringmanager.CompareTextWideStringProc(s1,s2)=0;
end;
{ we've no templates, but with includes we can simulate this :) } { we've no templates, but with includes we can simulate this :) }
{$macro on} {$macro on}
@ -65,7 +72,10 @@ Function WideFormat (Const Fmt : WideString; const Args : Array of const) : Wide
{ {
$Log$ $Log$
Revision 1.4 2005-02-26 10:21:17 florian Revision 1.5 2005-02-26 15:00:14 florian
+ WideSameStr
Revision 1.4 2005/02/26 10:21:17 florian
+ implemented WideFormat + implemented WideFormat
+ some Widestring stuff implemented + some Widestring stuff implemented
* some Widestring stuff fixed * some Widestring stuff fixed

View File

@ -24,11 +24,16 @@ function WideLowerCase(const s : WideString) : WideString;
function WideCompareStr(const s1, s2 : WideString) : PtrInt; function WideCompareStr(const s1, s2 : WideString) : PtrInt;
function WideSameStr(const s1, s2 : WideString) : Boolean; function WideSameStr(const s1, s2 : WideString) : Boolean;
function WideCompareText(const s1, s2 : WideString) : PtrInt; function WideCompareText(const s1, s2 : WideString) : PtrInt;
function WideSameText(const s1, s2 : WideString) : Boolean;
Function WideFormat (Const Fmt : WideString; const Args : Array of const) : WideString; Function WideFormat (Const Fmt : WideString; const Args : Array of const) : WideString;
{ {
$Log$ $Log$
Revision 1.3 2005-02-26 10:21:17 florian Revision 1.4 2005-02-26 15:00:14 florian
+ WideSameStr
Revision 1.3 2005/02/26 10:21:17 florian
+ implemented WideFormat + implemented WideFormat
+ some Widestring stuff implemented + some Widestring stuff implemented
* some Widestring stuff fixed * some Widestring stuff fixed