Modify

Opened 11 months ago

Closed 5 weeks ago

Last modified 4 weeks ago

#18235 closed enhancement (fixed)

Add new language Serbian with Latin script (sr@latin)

Reported by: Klumbumbus Owned by: stoecker
Priority: normal Milestone: 20.08
Component: Trac Version:
Keywords: Cc: Don-vip

Description

see wiki:/Translations/Statistics#Problempages
I'm not sure where the language code needs to be added.

Attachments (2)

for_translation_josm_josm-plugin_matsim_sr@latin.po (16.9 KB) - added by BrackoNe 6 weeks ago.
MATSim - Serbian (Latin) Translation
for_translation_josm_josm-plugin_Mapillary_sr@latin.po (63.2 KB) - added by BrackoNe 6 weeks ago.
Mapillary - Serbian (Latin) Translation

Download all attachments as: .zip

Change History (34)

comment:1 Changed 11 months ago by BrackoNe

Me neither. I'm adding Serbian language with "rs" official abbreviation. Please feel free to change to "sr-latn-rs" if you want to have more specific description.

comment:2 Changed 11 months ago by stoecker

Cc: Don-vip added

You have to change TracLanguages.

But like always this is more complex. There is no code Rs. And a code with script specification is neither supported by the wiki nor by JOSM. I have to think about how this needs to be handled first.

Aaargh. Why is I18N always so complicated? Each language brings a new bunch of trouble.

I think if we follow our existing schema the correct prefix should be "Sr-Latn_RS" and in josm "sr-latn_RS". But that needs code adaptions I fear.

My proposal for now would be to use "Sr_RS". That's not wrong, but does not use the script spec. We can postpone the work to support script codes to the time when we get the situation that Sr-Cyrl_RS also appears. For Chinese we also Use CN_Zh and CN_TW and not the script variants of these languages which would be more correct.

Any other ideas?

@BrackoNe:

You know that without software translation in JOSM the translated wiki pages like StartupPage aren't accessible from JOSM?

comment:3 Changed 11 months ago by BrackoNe

No, but I'm planning to translate JOSM server messages, as well JOSM interface. I will need help to find lang file because I have found one ~200+ kB, but I have a problem with formating, so I believe it is a wrong file.

Also, can you please change sr_RS as you proposed or to sr-Latn_RS?

Thanks in advance,
Nemanja

comment:4 Changed 11 months ago by stoecker

JOSM core is translated at Launchapd (see Translations). Launchpad and Transifex use "sr@latin" as language code. That is already supported by the software as ca@valencia uses the same method (Ca-Valencia for the wiki). That would mean the wiki code is "Sr-Latin".

So new proposal: Use Sr-Latin: for wiki pages (we can rename them, don't recreate!) and sr@latin as software-code. This does not need any new code and follows rules established by the translation platforms.

I don't think the _RS is needed, as we probably never will have a second Sr variant (and if, then the second one simply will get the underscore with correct specs).

P.S. Launchpad also has sr@Latn. Don't use this, as it is not compatible.

comment:5 Changed 11 months ago by BrackoNe

I'm already translating at Launchpad. I can see there is 31 → 40 of 11575 results, I hope I'm on the right one.

Thanks,
Nemanja

comment:6 Changed 11 months ago by stoecker

Yes. It's the right one. I renamed wiki pages and added sr@latin to trac languages. That works already now (thought not yet from within JOSM).

Note that the mimimum for JOSM inclusion of a new language is 2000 core texts. It will probably take you some time to reach that goal.

Though as far as I remember the initial Japanese translation reach 100% (about 8 to 10000 texts a that time) after about 3 or 4 days. :-)

comment:7 Changed 11 months ago by BrackoNe

Nice, thanks for help and confirmation that I'm in the right file.

Haha 3-4 days? As you said: Japanese... :)

comment:8 Changed 11 months ago by stoecker

NOTE: "A translation still in progress" note may be added with outdated=.... message in TranslatedPages macro. This is also shown in the status tables. I changed the download page accordingly.

Also note the revision in translation macro indicates the original english page. That's very important for later updates.

Last edited 11 months ago by stoecker (previous) (diff)

comment:9 Changed 11 months ago by BrackoNe

Okay.

comment:10 Changed 11 months ago by Klumbumbus

Resolution: fixed
Status: newclosed

comment:11 Changed 7 weeks ago by BrackoNe

Hello,

I can see that Serbian Latin wasn't included in latest official build, even I have translated 2455 strings (20%).
I have downloaded nightly build as well, but there is no Serbian Latin also. Can anyone tell me why?

Thanks,
Nemanja

comment:12 Changed 7 weeks ago by Klumbumbus

That doesn't work automatically. Each language needs to be added manually.

comment:13 in reply to:  12 Changed 7 weeks ago by BrackoNe

Replying to Klumbumbus:

That doesn't work automatically. Each language needs to be added manually.

I didn't know that. Who can I ask to add it?

comment:14 Changed 7 weeks ago by stoecker

Milestone: 20.08
Resolution: fixed
Status: closedreopened

comment:15 Changed 7 weeks ago by stoecker

Summary: Rs: Translated page language code unknownAdd new language Serbian with Latin script (sr@latin)

comment:16 Changed 7 weeks ago by stoecker

2000 core strings verified.

     [exec] Created file ../core/resources/data/sr-latin.lang   : Added  2169 strings out of  9418 ( 23.0%).

I'll do the necessary changes tomorrow (testing writing to new SVN copy in the process :-)

comment:17 Changed 7 weeks ago by BrackoNe

Thanks! I have uploaded a new .po file and it is waiting for validation. Will updated translations automatically be taken, or I have to raise the flag each time?

comment:18 Changed 7 weeks ago by stoecker

No further action from your side necessary except reaching the 100%...

Updates are manual as well (maybe we should automate them, it's anyway a single command only), but are done for all supported languages at least once before each tested version, sometimes more often.

comment:19 Changed 7 weeks ago by BrackoNe

Thanks for clarification!

Can you help me to understand how I can manually add the translation file (.po or .mo) and test it, if it is updated just once a month (on tested version release)?
I thought it would automatically pull new translations files for each night build.

comment:20 Changed 7 weeks ago by stoecker

In 35518/osm:

see #18235 - add sr@latin to i18n

comment:21 Changed 7 weeks ago by stoecker

In 16873/josm:

add sr@latin language, see #18235

comment:22 Changed 7 weeks ago by stoecker

Please check if everything is fine (access to OSM wiki, to JOSM wiki, ...).

One thing I noted, but wasn't able to fix: In the language preferences the other languages are shown in cyrillic and not latin. Either a java bug or we need to find a fix. But the script is correctly set as far as I can see.

Can you help me to understand how I can manually add the translation file (.po or .mo) and test it, if it is updated just once a month (on tested version release)?

Easiest way would be to checkout JOSM as stated here: Source code (full checkout, not only josm) and call ant updatecore in the i18n directory. Then build JOSM (with ant in core) and start it. Needs a proper build environment.

I thought it would automatically pull new translations files for each night build.

No, not yet. Sorry for that.

Last edited 6 weeks ago by stoecker (previous) (diff)

Changed 6 weeks ago by BrackoNe

MATSim - Serbian (Latin) Translation

Changed 6 weeks ago by BrackoNe

Mapillary - Serbian (Latin) Translation

comment:23 Changed 6 weeks ago by BrackoNe

Hello once again.

I have translated Mapillary and MATSim plugins offline.
Since there is no sr@latin @ https://www.transifex.com/josm/josm/language/sr/ where should I upload it?
Can you, please, place it to correct location?

Also, how can I filter out all JOSM Server translation to complete that translation firstly?

PS. I'm using paid version of Poedit to translate JOSM and its modules.

Thank you in advance,
Nemanja

comment:24 Changed 6 weeks ago by stoecker

For translation aside from JOSM infrastructure you need to contact the relevant developers directly (usually via GitHub). They've choosen not to use the established JOSM standard.

comment:25 Changed 5 weeks ago by simon04

Type: defectenhancement

comment:26 Changed 5 weeks ago by Klumbumbus

Can this ticket be closed?

comment:27 Changed 5 weeks ago by BrackoNe

Yes if you ask me. :)
Please just tell me how can I filter out in PO file all server messages to translate these first.

Thanks,
Nemanja

comment:28 Changed 5 weeks ago by Klumbumbus

I fear thats not possible, Dirk?

comment:29 in reply to:  27 Changed 5 weeks ago by stoecker

Replying to BrackoNe:

Yes if you ask me. :)
Please just tell me how can I filter out in PO file all server messages to translate these first.

What do you mean with "server" messages?

comment:30 Changed 5 weeks ago by stoecker

Resolution: fixed
Status: reopenedclosed

comment:31 Changed 4 weeks ago by BrackoNe

I ment on this:
Server
JOSM server data
English (113 normal strings)

Which is available here:
https://josm.openstreetmap.de/wiki/Translations/Statistics

comment:32 Changed 4 weeks ago by stoecker

In the i18n directory you can show the strings: ./langinfo.pl ../core/nodist/trans/en.lang
These currently are the plugins descriptions, see wiki:Plugins, they are marked with "build/trans_plugins.java" as source in the po files.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain stoecker.
as The resolution will be set.
The resolution will be deleted.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.