gimpusers.com logo
German version English version

Not logged in

Sign up! | Lost password?

Latest discussion

  1. gimp-user | today 03:10 AM
    Quick compiling question
  2. gimp-user | yesterday 08:23 PM
    Installing gegl for gimp-2.7
  3. gimp-developer | yesterday 06:57 PM
    GIMP distributing sRGB profiles: license issues?
  4. gimp-user | yesterday 04:41 PM
    Enlarge Canvas: Is there a way to do it by dragging? Could/Should there be?
  5. gimp-developer | yesterday 12:23 PM
    [PATCH] OpenRaster: optimize PNG saving

External news

Poll

Would you like to be able to use your Google/Yahoo/MSN (OpenID) login on gimpusers, too?

Definately! I would enjoy the possibility to use my OpenID on different websites!

I don't have a special need for OpenID but I think it could be useful

Doesn't matter to me

Never, OpenID is a pain regarding privacy and personal data protection!

No. (please post a comment)

See results

Stats

gimpusers.com RSS feed

GIMP Forums » GIMP documentation

First experience with po's

Jump to message:

  1. First experience with... — julien, 27 Dec 2008 06:34 PM
    1. First experience with... — Ulf-D. Ehlert, 28 Dec 2008 01:33 PM
      1. First experience with... — julien, 28 Dec 2008 06:11 PM

As a registered user, you can subscribe forum threads in order to get notified when replies are posted. Just log in at the right top of the page if you already have an account, otherwise you can register for free.

Permalink:4956670A.4060609@wanadoo.fr
Date:27 Dec 2008 06:34 PM
From:julien
Subject:First experience with po's
Hi all,

Here is my first experience using po's (po/fr/../doc.po, pot/../doc.pot,
src/../doc.xml). I consider two cases:

A - Translating only:
No change in the help structure; no add, no deletion. Only translation
of the strings.
1- Using the po file is the simplest way.
a/ First update this po to get strings that have changed by using the
following command:
msgmerge -U po/fr/../doc.po
This will add changed strings that are marked with a "Fuzzy" comment.
Edit this updated po files, searching for "Fuzzy".
b/ When your file is OK, validate it with this command (being in the
folder containing doc.po):
msgfmt -c --stat doc.po
This displays possible errors and some stats and generate a doc.mo file
that is of no use here.
c/ make the "svn diff"

2- You may want to work on a xml file rather than on a po:
a/ update the po files you want to use as above
b/ Create the xml files for your language (being in "trunk"):
make -f Makefile.GNU xml-fr for example.
This creates a xml folder in "trunk".
c/ Edit the wanted xml file.
d/ We can't validate xml for the moment. But you can open the file in
a web browser (Firefox) that will detect some errors.
Or copy the file in an old sandbox (before xml2po migration) and run
make validate...:-(
e/ Transform your xml file to po (being in trunk):
xml2po -e -o <path to doc.po> -r <path to your doc.xml> src/../doc.xml
(the english doc.xml).
f/ cut-paste the doc.po file into the po directory.
g/ Goto 1b

B - Updating gimp-help-2

1- Edit the src/../doc.xml file (english). Or edit a xml file in your
language and translate it after.
2- Validate it
3- Transform the updated doc.xml file to doc.pot:
xml2po -e -o doc.pot doc.xml
4- Edit the doc.xml file in your language, validate it
5- goto 1e

You may want to view your xml file in html. Waiting for Ulf's make
html-fr, I use
$yelp file:///home/<user-id>/.../trunk/xml/<LANG>/doc.xml
Unfortunately, images are not displayed by yelp. How to do?

I would be very pleased if you can provide a more simple way to work.

Julien


_______________________________________________
Gimp-docs mailing list
Gimp-docs@lists.XCF.Berkeley.EDU
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-docs

↑Back to thread overview
Permalink:200812281334.08685.ude88@web.de
Date:28 Dec 2008 01:33 PM
From:Ulf-D. Ehlert
Subject:First experience with po's
Hi Julien,

julien (Samstag, 27. Dezember 2008, 18:34):
> Here is my first experience using po's (po/fr/../doc.po,
> pot/../doc.pot, src/../doc.xml). I consider two cases:

> A - Translating only:
> No change in the help structure; no add, no deletion. Only
> translation of the strings.
> 1- Using the po file is the simplest way.
> a/ First update this po to get strings that have changed by using
> the following command:
> msgmerge -U po/fr/../doc.po

Use "make po-fr" or "make po/fr/../doc.po".

> This will add changed strings that are marked with a "Fuzzy" comment.
> Edit this updated po files, searching for "Fuzzy".
> b/ When your file is OK, validate it with this command (being in
> the folder containing doc.po):
> msgfmt -c --stat doc.po

Should we really add a make target for checking single po files?
Workaround: "make xml-fr" - it this succeeds, the po file should be ok.

> This displays possible errors and some stats and generate a doc.mo
> file that is of no use here.

msgfmt will find only simple errors like missing quote (") characters
etc., but it won't find DocBook errors, which are IMHO more likely.

> c/ make the "svn diff"
>
> 2- You may want to work on a xml file rather than on a po:
> a/ update the po files you want to use as above
> b/ Create the xml files for your language (being in "trunk"):
> make -f Makefile.GNU xml-fr for example.
> This creates a xml folder in "trunk".
> c/ Edit the wanted xml file.

No! Edit the English xml file src/.../doc.xml.
"make validate" should work now, checking the English xml files.
Then try "make po-fr" and edit po/fr/.../doc.po.
Try "make xml-fr" to create (and thus validate) the French xml file(s).
Or "make xml/fr/.../doc.xml" to create just a single xml file.
"make xml/fr/.../doc.draft" (extension '.draft' insted of '.xml') should
also work and should produce an HTML preview file.

> d/ We can't validate xml for the moment. But you can open the file
> in a web browser (Firefox) that will detect some errors.

"make xml/fr/.../doc.draft" should work, "make validate" too.

> Or copy the file in an old sandbox (before xml2po migration) and run
> make validate...:-(

No.

> e/ Transform your xml file to po (being in trunk):
> xml2po -e -o <path to doc.po> -r <path to your doc.xml>
> src/../doc.xml (the english doc.xml).

"make po-fr" or "make po/fr/../doc.po",
"make xml-fr".

> f/ cut-paste the doc.po file into the po directory.
> g/ Goto 1b

"Goto" considered harmful... ;-)

> B - Updating gimp-help-2
>
> 1- Edit the src/../doc.xml file (english).

Yes.

> Or edit a xml file in
> your language and translate it after.

No!

> 2- Validate it
> 3- Transform the updated doc.xml file to doc.pot:
> xml2po -e -o doc.pot doc.xml

"make pot" will create pot/../doc.pot.

> 4- Edit the doc.xml file in your language, validate it

No!

> 5- goto 1e
>
> You may want to view your xml file in html. Waiting for Ulf's make
> html-fr

Just try "make html-fr" and report what's going wrong.

> , I use
> $yelp file:///home/<user-id>/.../trunk/xml/<LANG>/doc.xml
> Unfortunately, images are not displayed by yelp. How to do?

I guess we can't use yelp. As far as I understand it, yelp will try to
create the HTML manual on-the-fly, so this tool is only useful for
small manuals.

For yelp we would have to create a new "mini" manual.

> I would be very pleased if you can provide a more simple way to work.

Translating only:
1. "make po-fr" to be up-to-date
2. edit po/fr/.../doc.po
3. "make xml-fr" or "make xml/fr/.../doc.xml" to check the result
4. "make xml/fr/.../doc.draft" to see an HTML preview
5. "make status-fr" to see which po files have to be edited
[not yet implemented, but I will add this feature today]

Adding/changing English documents:
1. edit src/.../doc.xml
2. "make validate"

Adding/changing French documents:
1. Don't! Just update the respective po files.

Of course there are still bugs and some of the command may fail...

Bye,
Ulf


_______________________________________________
Gimp-docs mailing list
Gimp-docs@lists.XCF.Berkeley.EDU
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-docs

↑Back to thread overview
Permalink:4957B341.3030905@wanadoo.fr
Date:28 Dec 2008 06:11 PM
From:julien
Subject:First experience with po's
Oh sorry,

I answered to your first message reading the second one.
I will have a try with all that. If I well understand, I can work on
several files and "make" will treat all of them at the same time.

My question about autogen and configure remains valid.

>> Here is my first experience using po's (po/fr/../doc.po,
>> pot/../doc.pot, src/../doc.xml). I consider two cases:
>
>> A - Translating only:
>> No change in the help structure; no add, no deletion. Only
>> translation of the strings.
>> 1- Using the po file is the simplest way.
>> a/ First update this po to get strings that have changed by using
>> the following command:
>> msgmerge -U po/fr/../doc.po
>
> Use "make po-fr" or "make po/fr/../doc.po".
>
>> This will add changed strings that are marked with a "Fuzzy" comment.
>> Edit this updated po files, searching for "Fuzzy".
>> b/ When your file is OK, validate it with this command (being in
>> the folder containing doc.po):
>> msgfmt -c --stat doc.po
>
> Should we really add a make target for checking single po files?
> Workaround: "make xml-fr" - it this succeeds, the po file should be ok.
>
>> This displays possible errors and some stats and generate a doc.mo
>> file that is of no use here.
>
> msgfmt will find only simple errors like missing quote (") characters
> etc., but it won't find DocBook errors, which are IMHO more likely.
>
>> c/ make the "svn diff"
>>
>> 2- You may want to work on a xml file rather than on a po:
>> a/ update the po files you want to use as above
>> b/ Create the xml files for your language (being in "trunk"):
>> make -f Makefile.GNU xml-fr for example.
>> This creates a xml folder in "trunk".
>> c/ Edit the wanted xml file.
>
> No! Edit the English xml file src/.../doc.xml.
> "make validate" should work now, checking the English xml files.
> Then try "make po-fr" and edit po/fr/.../doc.po.
> Try "make xml-fr" to create (and thus validate) the French xml file(s).
> Or "make xml/fr/.../doc.xml" to create just a single xml file.
> "make xml/fr/.../doc.draft" (extension '.draft' insted of '.xml') should
> also work and should produce an HTML preview file.
>
>> d/ We can't validate xml for the moment. But you can open the file
>> in a web browser (Firefox) that will detect some errors.
>
> "make xml/fr/.../doc.draft" should work, "make validate" too.
>
>> Or copy the file in an old sandbox (before xml2po migration) and run
>> make validate...:-(
>
> No.
>
>> e/ Transform your xml file to po (being in trunk):
>> xml2po -e -o <path to doc.po> -r <path to your doc.xml>
>> src/../doc.xml (the english doc.xml).
>
> "make po-fr" or "make po/fr/../doc.po",
> "make xml-fr".
>
>> f/ cut-paste the doc.po file into the po directory.
>> g/ Goto 1b
>
> "Goto" considered harmful... ;-)
>
>> B - Updating gimp-help-2
>>
>> 1- Edit the src/../doc.xml file (english).
>
> Yes.
>
>> Or edit a xml file in
>> your language and translate it after.
>
> No!
>
>> 2- Validate it
>> 3- Transform the updated doc.xml file to doc.pot:
>> xml2po -e -o doc.pot doc.xml
>
> "make pot" will create pot/../doc.pot.
>
>> 4- Edit the doc.xml file in your language, validate it
>
> No!
>
>> 5- goto 1e
>>
>> You may want to view your xml file in html. Waiting for Ulf's make
>> html-fr
>
> Just try "make html-fr" and report what's going wrong.
>
>> , I use
>> $yelp file:///home/<user-id>/.../trunk/xml/<LANG>/doc.xml
>> Unfortunately, images are not displayed by yelp. How to do?
>
> I guess we can't use yelp. As far as I understand it, yelp will try to
> create the HTML manual on-the-fly, so this tool is only useful for
> small manuals.
>
> For yelp we would have to create a new "mini" manual.
>
>> I would be very pleased if you can provide a more simple way to work.
>
> Translating only:
> 1. "make po-fr" to be up-to-date
> 2. edit po/fr/.../doc.po
> 3. "make xml-fr" or "make xml/fr/.../doc.xml" to check the result
> 4. "make xml/fr/.../doc.draft" to see an HTML preview
> 5. "make status-fr" to see which po files have to be edited
> [not yet implemented, but I will add this feature today]
>
> Adding/changing English documents:
> 1. edit src/.../doc.xml
> 2. "make validate"
>
> Adding/changing French documents:
> 1. Don't! Just update the respective po files.
>
> Of course there are still bugs and some of the command may fail...
>
> Bye,
> Ulf
>
>
>
> ------------------------------------------------------------------------
>
>
_______________________________________________
> Gimp-docs mailing list
> Gimp-docs@lists.XCF.Berkeley.EDU
> https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-docs


_______________________________________________
Gimp-docs mailing list
Gimp-docs@lists.XCF.Berkeley.EDU
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-docs

↑Back to thread overview

Adobe® Photoshop® is a registered trademark of Adobe Systems, Inc. Linux is a trademark of Linus Torvalds. Ubuntu and Canonical are registered trademarks of Canonical Ltd. | Clock times are shown as CET / CEST | Imprint / Privacy policy | powered by bitfire it services