summaryrefslogtreecommitdiff
path: root/fpcsrc/tests/test/units/sysutils/tlocale.pp
blob: c5304191b78ffcdb7e366b8a9327b107c8e3bf5e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
{ %interactive }

uses
{$ifdef unix}
  cwstring,
  clocale,
{$endif}
  SysUtils;

procedure PrintSettings;
var
 i: integer;
begin
  Writeln('Month names:');
  for i := 1 to 12 do
    Writeln('month ',i:5,' ',shortmonthnames[i]:25,' - ',longmonthnames[i]);
  Writeln;
  Writeln('Day names  :');
  for i := 1 to 7 do
     writeln('short day ',i:5,' ',shortdaynames[i]:25,' - ',longdaynames[i]);

  writeln('Dateseparator : ', dateseparator);
  {$ifdef localedebug}
  writeln('orgshortdate  : ', orgformatsettings.shortdateformat);
  {$endif}
  writeln('short date    : ', shortdateformat);
  {$ifdef localedebug}
  writeln('orglongdate   : ', orgformatsettings.longdateformat);
  {$endif}
  writeln('long  date    : ', longdateformat);
 { Time stuff }
  writeln('TimeSeparator : ', timeseparator);
  writeln('TimeAMstring  : ', timeamstring);
  writeln('TimePMstring  : ', timepmstring);  
  {$ifdef localedebug}
  writeln('orgshorttime  : ', orgformatsettings.shorttimeformat);
  {$endif}

 // No support for 12 hour stuff at the moment...
  writeln('short time    : ', shorttimeformat);
  {$ifdef localedebug}
  writeln('orglongtime   : ', orgformatsettings.longtimeformat);
  {$endif}
  writeln('long  time    : ', longtimeformat);

 { Currency stuff }

  {$ifdef localedebug}
  writeln('currency1     : ', orgformatsettings.currencystring1);
  writeln('currency2     : ', orgformatsettings.currencystring2);
  {$endif}

  writeln('currencystring  : ', currencystring);

  writeln('currencyformat  : ', currencyformat);
  writeln('negcurrformat   : ', negcurrformat);

  writeln('decimalseparator : ', decimalseparator);
  writeln('thousandseparator: ', thousandseparator);
  writeln('currencydecimals : ', currencydecimals);
end;

begin
  printsettings;
end.