Re: i18n done with gettext

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Lucian Muresan wrote:
>> How does this translate into gettext? Does each plugin use its own
>> textdomain(), and if, how does the domain switching happen?
> 
> I think so, every plugin should have it's own domain (therefore, po ->
> mo file). The switching would be done in the tr() macro (it's underlying
> function) when invoked with the plugin name argument

Just realized: There's a dgettext() that can be used instead of
temporarily switching the domain.

> If the translations are to be cached in memory, they would be read once
> at startup of VDR and each plugin, and a dynamically allocated Phrases[]
> array would be filled with their contents

Probably worth to investigate whether that is really better. If gettext
has been implemented in a smart way, its probably much faster than the
current VDR i18n implementation. And pre-loading all strings may also
add to the VDR startup time.

Cheers,

Udo



[Index of Archives]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Util Linux NG]     [Xfree86]     [Big List of Linux Books]     [Fedora Users]     [Fedora Women]     [ALSA Devel]     [Linux USB]

  Powered by Linux