[GRASS-translations] Add a setence in *.po file

António Rocha antonio.rocha at deimos.com.pt
Fri Jan 22 05:08:26 EST 2010


Hello Neteler.
No worries regarding update. I'm testing this in a machine disconnected 
from the "WORLD" :)

> So (not that complicated but easier than using the "make pot"
> approach):
> Take one of the grassXXX_pt.po files in a text editor and delete all except
> the header, and the number of messages you want to have. 
Uhm.. here we have our firtst ptoblem. my grasswxpy_pt.po header only has:
*# translation of grasswxpy_pt.po to Português
#
# This file is distributed under the same license as the GRASS package.
# Copyright (C) 2009, GRASS Development Team
#
# Antonio Rocha, 2009.
msgid ""
msgstr ""
"Project-Id-Version: grasswxpy_pt\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2009-01-09 23:29+0100\n"
"PO-Revision-Date: 2009-11-23 14:10-0000\n"
"Last-Translator: \n"
"Language-Team: Português <grass-translations at lists.osgeo.org>\n"
"Language: pt\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Virtaal 0.4.1\n"
"X-Poedit-Language: Portuguese\n"
"X-Poedit-Country: PORTUGAL\n"*

There is no reference to the number of images.


> Call the
> file for example grass_deimos_pt.po. Update the header accordingly.
> Then substitute the existing English text with your english messages
> (that why we selected the same number before, for easy recycling).
>   
I'm not deleting other translations, since I added a few functions I 
need new translations.
And I added the following to the po file (in NOTEPAD ++)- in the bottom 
of the file:
msgid "Build of NDVI"
msgstr

msgid "raster output NDVI map:"
msgstr

msgid "raster input map (Near Infrared):"
msgstr

But nothing was appearing in the po file. So I decided to add this 
instead of the previous:
*msgid "Build of NDVI"
msgstr ""

msgid "raster output NDVI map:"
msgstr ""

msgid "raster input map (Near Infrared):"
msgstr ""*

And Now it was appearing at the poEditor menu.

> Close the text editor and reopen the file with poedit. Now you can
> add the Portuguese translation as well. Save the file.
>   
Ok Done. And it saves not only po but also mo file.

> Note the line numbers are only comments and not relevant.
>   
uhm?? Didn't saw that.

> Now you also need to add a rule in the Makefile or generate manually
> the .mo file and copy it into the LC_MESSAGES directory.
>   

Since po editor generates an mo file, I just copied to the LC_MESSAGES > 
pt and substitute the file (no worries I made a backup).
Everything else is translated, but, those 3 sentences were not 
translated....Those 3 sentences are used in a script file (test_script2).

Or am I doing the translation in the wrong file? (grasswxpy)

Best regards,
Antonio

> Mhh, perhaps we need to develop some support for this?
>   
Don't want to make any pressure on that but... Yes :)


__________ Information from ESET NOD32 Antivirus, version of virus signature database 4796 (20100122) __________

The message was checked by ESET NOD32 Antivirus.

http://www.eset.com




More information about the grass-translations mailing list