Explorar el Código

+ CurrToStrF
+ ListSeparator

git-svn-id: trunk@1100 -

florian hace 20 años
padre
commit
6bce91adc0

+ 2 - 0
rtl/objpas/sysutils/sysinth.inc

@@ -127,6 +127,8 @@ Const
   { Currency notation. Default is $ for dollars. }
   CurrencyString : String[7] = '$';
 
+  ListSeparator: Char = ',';
+
 type
   TSysLocale = record
     { Delphi compat fields}

+ 5 - 0
rtl/objpas/sysutils/sysstr.inc

@@ -1144,6 +1144,11 @@ Begin
   End;
 End;
 
+Function CurrToStrF(Value: Currency; Format: TFloatFormat; Digits: Integer): string;
+  begin
+    result:=FloatToStrF(Value,Format,19,Digits);
+  end;
+
 Function FloatToDateTime (Const Value : Extended) : TDateTime;
 begin
   If (Value<MinDateTime) or (Value>MaxDateTime) then

+ 1 - 0
rtl/objpas/sysutils/sysstrh.inc

@@ -114,6 +114,7 @@ Function StrFmt(Buffer,Fmt : PChar; Const args: Array of const) : Pchar;
 Function StrLFmt(Buffer : PCHar; Maxlen : Cardinal;Fmt : PChar; Const args: Array of const) : Pchar;
 Procedure FmtStr(Var Res: String; Const Fmt : String; Const args: Array of const);
 Function FloatToStrF(Value: Extended; format: TFloatFormat; Precision, Digits: Integer): String;
+Function CurrToStrF(Value: Currency; Format: TFloatFormat; Digits: Integer): string;
 Function FloatToStr(Value: Extended): String;
 Function StrToFloat(Const S : String) : Extended;
 Function StrToFloatDef(Const S: String; Const Default: Extended): Extended;