Re: Is there a way to help gtkmm for website translation?

On Sat, 2010-05-01 at 23:23 +1000, Tao Wang wrote:
> On Sat, May 1, 2010 at 5:53 AM, Murray Cumming <murrayc murrayc com> wrote:
> > On Sat, 2010-05-01 at 02:54 +1000, Tao Wang wrote:
> >> There are 3 documents in gtkmm. Based on priority:
> >> 1) the first one is the gtkmm website. This is beginning of
> >> everything. So, it's more important than others. So, it should be
> >> treated as a document.
> >
> > The website is very simple HTML, using Server Side Includes to avoid
> > some repetive HTML. I'd welcome suggestions for making it translatable,
> > though it would have to still be simple. I have no interest in
> > maintaining a CMS.
> >
> [ POT generation ]
> It's better using pot than copy and modify pages for each language.
> Because it is much easier for keeping consistent of different
> language. If translator didn't update in time, the original English
> string will be shown, other than shown the old information.
> I don't know whether the website is using the same way of DocBook xml
> to generate the html and ssi.

It is not. It's just HTML.

(git) patches are welcome, if you'd like to try:

>  If it is, it would easier to generate
> .pot file by xml2po, and using translated po file to generated a set
> of html. If not, you can use gettext function in php to do the same
> thing. Just simply wrap each readable strings to <?php echo _("Welcome
> to gtkmm")?>, and then gettext can extract the strings to form .pot
> file.
> [ Available for Translators ]
> And then you can post the .pot file to or
> as "gtkmm-site", so translators will aware
> that, and can translate it.
> [ URL ]
> Visit, the site will automatically recognize
> user's locale, and if the language is available, then redirect to the
> language's page. Otherwise, the default language will be used.
> Visit{lang}, such as,
> will display the specified language pages.
> If you are using php+gettext solution, the implementation is very
> simple.

I would like to avoid using PHP, so I don't have to worry about security
or any programming in the website at all. People will say it's simple,
but it's never simple enough.

>  Just add a parameter to the link, such as
>, and then in the php, set
> the locale to "zh_CN" as the link specified, and then gettext will
> automatically fetch corresponding string from file. So, it's
> actually not necessary create a set of pages for each locale.
> [ Interface ]
> For the interface. Based on gtkmm website, right top corner is empty,
> so you can put a dropdown list, or a list of flags, or a list of
> languages names, to let user select the language. And the left bottom
> corner is empty too, you can put a languages list above "Other
> Resources". I don't like the interface for choosing language in
> "";, because there are too many
> languages, so the list is too long for choose. In such case, a matrix
> of language flags will be much helpful for language choosing. So, at
> the beginning, a list of language is ok, since their is not so many
> languages available.

There are no language flags. There are only country flags. That's why we
don't use them. It's particularly problematic when there are territorial

murrayc murrayc com

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