Bug 57136

Summary: no obvious way to update translation
Product: [Applications] lokalize Reporter: A T Somers <andre>
Component: editorAssignee: Stanislav Visnovsky <visnovsky>
Status: RESOLVED FIXED    
Severity: wishlist CC: dglent, jlp, shafff
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: openSUSE   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description A T Somers 2003-04-11 19:22:17 UTC
Version:           1.0 (using KDE 3.1.0)
Installed from:    SuSE
Compiler:          gcc version 2.95.3 20010315 (SuSE)
OS:          Linux (i686) release 2.4.18-4GB

OK, it may be just me, but I see no obvious way to keep an existing translation up to date with a program that is a work in progress. I think this is a serious flaw in the software. Here's the scenario I'd like to see: I check out the program (including the .pot and the .po files) from CVS, open the right .po file, select some menu-option to get all the untranslated strings from the changed .pot file into the .po file, and get to work on translating them. Currently, I don't see how to do that easily.
Comment 1 Stephan Kulow 2003-04-12 12:29:53 UTC
because this highly depends on the program? If you know the right pot file, 
use msgmerge to update the po file. kbabel can't do that for you as it can't 
hardly guess the correct POT file. 
Comment 2 A T Somers 2003-04-22 20:56:08 UTC
It could let me select the correct (up to date) .pot file though... 
I have found a workaround that involves the following steps: 
-rename the old translation, and start a new one. 
-configure the PO-auxiliary dictionary to point to the old translation 
-use Tools | Rough translation and add the PO-auxiliary to the list of resources to 
be used in order to get your old translations back 
 
I find this route a bit cumbersome to be honest. I would like to use a route like this: 
-open the .po file I'd like to work on 
-initiate some update-action, that allows me to select the updated .pot file 
-sit back and relax while KBabel updates the strings.  
-translate the missing stuff and be done with it. 
 
Does that really sound illogical? 
Comment 3 Stanislav Visnovsky 2003-04-23 17:41:16 UTC
OK, this is a usefull feature IMHO.
Comment 4 Nick Shaforostoff 2003-12-04 20:16:18 UTC
we need automatization of translation process as much as possible
Comment 5 Jure Repinc 2003-12-05 18:29:15 UTC
Would it be possible to update the translation from Catalog Manager in this way:
1. You have set base PO and POT folders
2. On load/refresh the manager checks the PO and corresponding POT file and it could also check if POT file is changed
3. If it is changed it runs the msgmerge or something similar
Comment 6 rgpublic 2005-08-05 22:35:41 UTC
Am I on the right bug here?
I'm missing a feature like poedit's "update catalog".
It searches certains paths for new or removed strings and merges
them with the currently open po-file.
Comment 7 Nick Shaforostoff 2009-05-09 21:12:55 UTC
(In reply to comment #5)
> Would it be possible to update the translation from Catalog Manager in this way:
> 1. You have set base PO and POT folders
> 2. On load/refresh the manager checks the PO and corresponding POT file and it could also check if POT file is changed
> 3. If it is changed it runs the msgmerge or something similar

In KDE 4.3 Lokalize will have such script, except that you have to call it explicitly (either from editor tab, or from project overview tab, in which case you can update multiple files at a time).

you can find it's source here (msgmerge.py and msgmerge.rc): 
http://websvn.kde.org/trunk/KDE/kdesdk/lokalize/src/scripts/

More about scripting in Lokalize: http://shaforostoff.blogspot.com/2009/05/scripting-lokalize.html

The script expects that layout of the project is like in KDE: http://websvn.kde.org/trunk/l10n-kde4/ 

It is very straightforward and may be easily adapted for your use case (e.g. other location of template file, or some additional steps to regenerate it). If you have problems adjusting it for your needs, tell me so.

Anyone objecting to me closing the bug?
Comment 8 Nick Shaforostoff 2009-05-25 02:07:08 UTC
*** Bug 187635 has been marked as a duplicate of this bug. ***
Comment 9 Nick Shaforostoff 2009-11-08 18:49:28 UTC
counting this as fixed. (well, perhaps the documentation should be more elaborate on this matter...)