1 { Example for use of GNU gettext. 2 Copyright (C) 2003 Free Software Foundation, Inc. 3 This file is in the public domain. 4 5 Source code of the Pascal program. } 6 7 program hello; 8 {$mode delphi} 9 10 uses gettext, { translateresourcestrings } 11 linux, { getpid } 12 sysutils; { format } 13 14 resourcestring 15 hello_world = 'Hello, world!'; 16 running_as = 'This program is running as process number %d.'; 17 18 begin 19 translateresourcestrings({$i %LOCALEDIR%}+'/%s/LC_MESSAGES/hello-pascal.mo'); 20 writeln(hello_world); 21 writeln(format(running_as,[getpid])); 22 end. 23