[Lazarus] Translations / Localizations for controls at design time
Reinier Olislagers
reinierolislagers at gmail.com
Tue Jul 31 19:32:27 CEST 2012
On 31-7-2012 18:39, Jürgen Hestermann wrote:
> Am 2012-07-31 18:15, schrieb Graeme Geldenhuys:
>> * When new languages are added, you must rebuild the whole application
>> (executable).
> Yes. But why is this a drawback? It speeds up application start because
> all is in one exe file without having the need to load a separate
> language file on startup.
Normally, IIRC .po files will be included as resource strings. No speed
issues.
>> * You can't use any of the existing PO translating tools which have
>> some brilliant
>> features like built-in dictionaries, suggested translations, spell
>> checking etc.
> Well, I mostly find all these "brilliant" features more disturbing than
> helpful. And you also have a learning curve to investigate in these
> tools that eats up time.
Could be, but .po files are still the standard. There are web
sites/programs that suggest translations based on the source language
string and a database of already translated open source strings.
I've used them and they work fine.
I think you could even translate .po files with notepad or vi if you
wanted to (and want to avoid that learning curve).
Otherwise, have a look at e.g. virtaal for translating po files.
Furthermore, using po files is documented quite well on the wiki... at
least it got me up and running quickly.
See also Lazarus the complete guide, p. 125.
Also: have pity with your translators - unless you intend to do all
translations yourself ;)
>> rsDate = 'Some Date';
>> rsTitle = 'Some dialog title';
>> vs
>> rsAccountingTransactionDate = 'Some Date';
>> rsCentreMaintenanceDialogTitle = 'Some dialog title';
>
> Well, this reduces the probability of miss-translation but if you have
> the code nearby and maybe even comments then you have much more
> information of what is meant in this case.
That is true, if the translator is tech-savvy.
> Also, sometimes the length of the text is important too (so that a
> button caption can still be displayed and does not exceed the borders).
> If you only see a variable name then you don't know about these
> constraints.
Neither can somebody who just looks at the code unless he fires up the form.
> Nevertheless, if lots of people are working on a large project an
> external file may be of use because the translator may neither be a
> programmer nor a program user (although in such cases translations are
> not very good IMO). But for smaller projects this is very convenient and
> saves cluttering information in too many files and has the mentioned
> advantages.
We can agree to disagree ;)
I have translated LazPaint to Dutch without having run the program but
with the help of suggested translations (especially for graphical
programs) and, yes, I must admit, the source code (in extreme cases -
when it was unclear when a string was used exactly)... no complaints yet ;)
More information about the Lazarus
mailing list