mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-11-22 03:19:46 +01:00
* booltostr overload
git-svn-id: trunk@11600 -
This commit is contained in:
parent
5feba9b3d7
commit
03fd61b68d
@ -1740,6 +1740,12 @@ begin
|
||||
Result:='0';
|
||||
end;
|
||||
|
||||
// from textmode IDE util funcs.
|
||||
function BoolToStr(B: boolean; const TrueS, FalseS: string): string;
|
||||
begin
|
||||
if B then Result:=TrueS else BoolToStr:=FalseS;
|
||||
end;
|
||||
|
||||
function StrToBoolDef(const S: string; Default: Boolean): Boolean;
|
||||
begin
|
||||
if not(TryStrToBool(S,Result)) then
|
||||
|
||||
@ -210,7 +210,8 @@ Function FormatCurr(const Format: string; Value: Currency; Const FormatSettings:
|
||||
{$endif}
|
||||
|
||||
function StrToBool(const S: string): Boolean;
|
||||
function BoolToStr(B: Boolean;UseBoolStrs:Boolean=False): string;
|
||||
function BoolToStr(B: Boolean;UseBoolStrs:Boolean=False): string;
|
||||
function BoolToStr(B: Boolean;const TrueS,FalseS:string): string; inline;
|
||||
function StrToBoolDef(const S: string; Default: Boolean): Boolean;
|
||||
function TryStrToBool(const S: string; out Value: Boolean): Boolean;
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user