+ StrNextChar implemented

git-svn-id: trunk@7803 -
This commit is contained in:
florian 2007-06-24 20:30:55 +00:00
parent 792f84a710
commit e1125c3f7f
2 changed files with 18 additions and 11 deletions

View File

@ -938,7 +938,7 @@ begin
Result:=StrFmt(Buffer,Fmt,Args,DefaultFormatSettings);
end;
Function StrFmt(Buffer,Fmt : PChar; Const Args: Array of const; Const FormatSettings: TFormatSettings): PChar;
Function StrFmt(Buffer,Fmt : PChar; Const Args: Array of const; Const FormatSettings: TFormatSettings): PChar;
begin
Buffer[FormatBuf(Buffer^,Maxint,Fmt^,strlen(fmt),args,FormatSettings)]:=#0;
@ -1104,7 +1104,7 @@ Var
P: Integer;
Negative, TooSmall, TooLarge: Boolean;
DS: Char;
Begin
DS:=FormatSettings.DecimalSeparator;
Case format Of
@ -1608,7 +1608,7 @@ begin
Result:=FloatToStrF(Value,ffGeneral,-1,0);
end;
function AnsiDequotedStr(const S: string; AQuote: Char): string;
function AnsiDequotedStr(const S: string; AQuote: Char): string;
var p : pchar;
@ -1666,7 +1666,7 @@ begin
begin
CheckStrs;
if B then
Result:=TrueBoolStrs[0]
Result:=TrueBoolStrs[0]
else
Result:=FalseBoolStrs[0];
end
@ -1682,7 +1682,7 @@ begin
if not(TryStrToBool(S,Result)) then
Result:=Default;
end;
function TryStrToBool(const S: string; out Value: Boolean): Boolean;
Var
Temp : String;
@ -1902,7 +1902,7 @@ Var
End; { Case }
End { Begin }
Else
Inc(Fmt);
Inc(Fmt);
End; { Case }
End; { While .. Begin }
End;
@ -2205,7 +2205,7 @@ begin
fvComp:
Str(Currency(Value):23, Buffer);
end;
N := 1;
L := Byte(Buffer[0]);
while Buffer[N]=' ' do
@ -2460,8 +2460,8 @@ begin
Result:=mbSingleByte;
end;
Function StrByteType(Str: PChar; Index: Cardinal): TMbcsByteType;
Function StrByteType(Str: PChar; Index: Cardinal): TMbcsByteType;
begin
Result:=mbSingleByte;
end;
@ -2473,6 +2473,12 @@ begin
end;
function StrNextChar(const Str: PChar): PChar;
begin
result:=Str+StrCharLength(Str);
end;
Function FindCmdLineSwitch(const Switch: string; const Chars: TSysCharSet;IgnoreCase: Boolean): Boolean;
Var

View File

@ -69,7 +69,7 @@ procedure AppendStr(var Dest: String; const S: string);
function UpperCase(const s: string): string;
function LowerCase(const s: string): string; overload;
{ the compiler can't decide else if it should use the char or the ansistring
version for a variant }
version for a variant }
function LowerCase(const V: variant): string; overload;{$ifdef SYSUTILSINLINE}inline;{$endif}
function CompareStr(const S1, S2: string): Integer;
function CompareMemRange(P1, P2: Pointer; Length: cardinal): integer;
@ -97,7 +97,7 @@ function TrimLeft(const S: string): string;
function TrimRight(const S: string): string;
function QuotedStr(const S: string): string;
function AnsiQuotedStr(const S: string; Quote: char): string;
function AnsiDequotedStr(const S: string; AQuote: Char): string;
function AnsiDequotedStr(const S: string; AQuote: Char): string;
function AnsiExtractQuotedStr(var Src: PChar; Quote: Char): string;
function AdjustLineBreaks(const S: string): string;
function AdjustLineBreaks(const S: string; Style: TTextLineBreakStyle): string;
@ -123,7 +123,7 @@ Function Format (Const Fmt: string; const Args: array of const; const FormatSett
Function FormatBuf (Var Buffer; BufLen : Cardinal; Const Fmt; fmtLen : Cardinal; Const Args : Array of const) : Cardinal;
Function FormatBuf (Var Buffer; BufLen : Cardinal; Const Fmt; fmtLen : Cardinal; Const Args : Array of const; Const FormatSettings: TFormatSettings) : Cardinal;
Function StrFmt(Buffer,Fmt : PChar; Const args: Array of const) : Pchar;
Function StrFmt(Buffer,Fmt : PChar; Const Args: Array of const; Const FormatSettings: TFormatSettings): PChar;
Function StrFmt(Buffer,Fmt : PChar; Const Args: Array of const; Const FormatSettings: TFormatSettings): PChar;
Function StrLFmt(Buffer : PCHar; Maxlen : Cardinal;Fmt : PChar; Const args: Array of const) : Pchar;
Function StrLFmt(Buffer : PCHar; Maxlen : Cardinal;Fmt : PChar; Const args: Array of const; Const FormatSettings: TFormatSettings) : Pchar;
Procedure FmtStr(Var Res: String; Const Fmt : String; Const args: Array of const);
@ -218,6 +218,7 @@ Function ByteToCharLen(const S: string; MaxLen: Integer): Integer;
Function CharToByteLen(const S: string; MaxLen: Integer): Integer;
Function ByteToCharIndex(const S: string; Index: Integer): Integer;
Function StrCharLength(const Str: PChar): Integer;
function StrNextChar(const Str: PChar): PChar;
const