Hi all,
I am trying to make OutKafe gettext translateable, using whatever code
I can find for samples this is what my code now looks like:

-------
uses
 Classes, SysUtils, LResources, Forms, Controls, Graphics, Dialogs,
ExtCtrls,Util,
  StdCtrls, Buttons , gtkproc, TrayIcon, popupnotifier,
Menus,liboutkafe,popupunit,
  fileUtil,baseunix,unix, IpHtml, Ipfilebroker,gettext;

resourcestring
    rsLoginDetails = 'Enter your login details to continue';
    rsLoginName = 'Login Name';
    rsPassword = 'Password';
    rsLogin = 'Login';
<snip>
procedure OklinMainForm.Create;
<snip>
//LangPath is a const, it is set to /usr/share/outkafe/lang

   TranslateUnitResourceStrings('oklinmainunit',
LANGPATH+PathDelim+'oklin.%s.po');
     Label1.Caption := Utf8ToAnsi(rsLoginDetails);
     Label2.Caption := Utf8ToAnsi(rsLoginName);
     Label3.Caption := Utf8ToAnsi(rsPassword);
     LoginBtn.Caption :=  Utf8ToAnsi(rsLogin)
-------

So I compile it, which generates an oklinmainunit.rst file, I run
rstconv -i oklinmainunit.rst -o oklin.po
cp oklin.po oklin.af.po

I edit oklin.af.po and copy it to /usr/share/outkafe/lang
I ALSO run msgfmt oklin.af.po -o oklin.af.mo
And put that in there as WELL,

Then I run:
LANG="af" ./oklin

But the program remains obstinately in English (no output in the
console gives me any
indication of why).

Can anybody give me an idea what I am doing wrong ?
Why does the TranslateUnitResourceStrings function appear to have FOUR
parameters in some calls (but not in the gettext unit) - is that
alternative a better choice ? Where do I get it?

TIA
A.J.
--
A.J. Venter
CEO - OutKast Solutions C.C.
http://www.outkastsolutions.co.za
Cell: +27 83 455 9978
Fax: +27 21 413 2800
Office: +27 21 591 6766

_________________________________________________________________
    To unsubscribe: mail [EMAIL PROTECTED] with
               "unsubscribe" as the Subject
  archives at http://www.lazarus.freepascal.org/mailarchives

Reply via email to