Geertjan's Blog

  • July 15, 2014

Lightweight Process for Translating NetBeans IDE

Geertjan Wielenga
Product Manager

To me, the problem with translating NetBeans IDE over the years has been that the process has always been very complicated with all kinds of tools that need to be set up.

Wouldn't it be cool if there was a simple, lightweight process. One that anyone can follow, in between doing other work, i.e., quickly dedicate half an hour every day to translating NetBeans IDE, whilst doing other work? No new tools to set up, no new and complex processes to learn? Everything done from within NetBeans IDE itself?

Here's how that can be achieved. Some steps have small YouTube clips to illustrate points made. These YouTube clips are silent, the idea is to watch and learn from the process.

  1. Get Set Up. Download and unzip the last community translation distribution, i.e., the one that contains more than the official translations, e.g., Russian, but the community translations, e.g., German and French. They're found here and I started with the netbeans-7.3-201302261559-javase.zip.

    Then get hold of the "Localized NetBeans" project. This is a project I have created on java.net and isn't public yet. That will happen soon. If you want to participate, let me know (leave a comment at the end of this blog entry with your java.net username included), I will add you as a member to the project, which will give you access to the project sources. The location is https://java.net/projects/localized-netbeans though, again, without being a member you will not be able to get to the project site.

  2. Set Up the Translation Module. As described in a recent blog entry, here, a NetBeans Platform application can provide modules with translated texts for UI elements in the application, which can be enabled via the --locale switch. Therefore, if it doesn't already exist, create a new module for your language in the "LocalizedNetBeans" project and move the JARs from step 1 that already provide translations into the module.

    Small overview for adding Korean:

    If you're doing a language for which no JARs already exist, just skip this step and go straight to the next one, i.e., for Serbian you'll start by writing down some texts that you want to translate, then look for them in the Branding dialog after selecting the Serbian locale, and have NetBeans IDE create properties files automatically for you. See the next step for the details.

  3. Start Translating. Any missing translations? Look around, identify what's missing, look for the texts in the Branding tool in NetBeans IDE, and add them.

    Small overview for translating to Korean:

    Remember, when searching for texts in the Branding tool, that if a text has an underline, e.g., "Options" with the "O" underlined (to create an accelerator key), you need to look for "&Options".

  4. Move to the Next Level. Once the "LocalizedNetBeans" has been translated, i.e., the lowest level of NetBeans IDE, which is the NetBeans Platform, move to the next level, which is already available, i.e., "LocalizedIDE". The focus here is on the "ide" cluster, e.g., the project system, and other tools that related to an IDE created on top of the NetBeans Platform.

    Small overview for moving from "platform" to "ide":

    "LocalizedIDE" depends on the cluster of "LocalizedNetBeans", so that those translations are automatically included.

    After the above is done, the next level would be "LocalizedJavaSENetBeans", where the focus is to provide the missing translations for your language in the community distribution for the Java SE distribution of NetBeans IDE, i.e., the Java Editor and related tools.
    "LocalizedJavaSENetBeans" will depend on the cluster of "LocalizedIDE".

  5. Check In. At the end of the previous steps, you'll possibly have one or more new modules, if your language wasn't supported yet, and you'll definitely at least have new properties files in the 'branding' folder of "LocalizedNetBeans", "LocalizedIDE", etc. Check those in. When there are enough of them, or when you say you're done, or at some stage when at least all the visible texts have been translated, I will put those properties files together into one or more new NetBeans modules. There'd be one module for the 'platform' translation of Korean, one for the 'ide' translation, etc, because not everyone will want all the translations, e.g., if you're creating an application on the NetBeans Platform, you don't want the Java Editor translations, so best to keep them separated per 'level'. Those various modules will be uploaded together to the NetBeans Plugin Portal. Anyone can download and install them and use the --locale switch to activate them. So we'll end up with language packs for each language, available on the Plugin Portal.

On the 'platform' level, i.e., the level of "LocalizedNetBeans", most things are already translated for most supported community languages. I.e., if you're using the NetBeans Platform, German and French and Spanish and Italian translations are mostly complete already, a few gaps here and there which won't take much work to add by a native speaker. And the above approach can also be used to add new modules, for Serbian, for example.

The process is simple and completely integrated into NetBeans IDE so that anyone can, in between programming, do a little bit of translation work.

Want to participate? Leave a comment that includes your java.net username so that you can be added to the project and so that you can start following the steps described above.

Join the discussion

Comments ( 17 )
  • Slawek Mikula Tuesday, July 15, 2014

    Great to see this happening. When someone want to use netbeans rcp not in official supported language, there is much steep steps to overcome. My java.net name is slawekmikula.

    Anyway I've read some documentation on NB l10n. It would be great, to clarify this process. I know that oracle suspended community localization, but:

    - there is hg repo for l10n: http://hg.netbeans.org/releases/l10n/ without any information how to contribute, but there are new commits to this repo

    - on nb page http://wiki.netbeans.org/TranslateNetbeansModule there is some information for module translation

    - there is nblocalization project: https://netbeans.org/projects/nblocalization with some activity, but none current

    - there is some documentation of translating NB with OmegaT https://nblocalization.netbeans.org/docs/HOWTOs/How-to-translate-NetBeans-using-OmegaT.html

    - but link to translatedfiles is dead: http://translatedfiles.netbeans.org/docs/HOWTOs/How-to-translate-NetBeans.html

    - there is no (AFAIK) way to get translation source messages (*.properties) from current netbeans hg main repository (or am I wrong?)

    - I've created sample repository (https://bitbucket.org/slawekmikula/nblocalization) and combine omegaT to translate netbeans using omegaT. It's great to see, that I can finally stop digging with it.

    It would be great to somehow clear information on multiple websites about NB l10n. Nonetheless, great to see activity in this area. I'm all in.

  • Geertjan Tuesday, July 15, 2014

    Just follow the steps in this blog entry, Slawek, and you'll be fine. Which language would you like to translate? Can you give me your java.net username so I can let you join the project and you can start immediately?

  • Geertjan Tuesday, July 15, 2014

    Ah, I see, slawekmikula. Will add you. Can you try out the process described here and tell me what you think of it?

  • Slawek Mikula Tuesday, July 15, 2014

    Polish language. Of course, I'll check it and provide feedback :)

  • Geertjan Tuesday, July 15, 2014

    Excellent. You're a member of the project now. This process is as simple as it gets. In the end, we'll create a module for each 'level' for each language and then put them on the Plugin Portal so anyone can download and install them, just like any other plugin.

  • Slawek Mikula Tuesday, July 15, 2014

    Thanks, i've commited *visible* translations for platform in polish language. I'll look into ide cluster next.

    Frankly speaking Your translation is good for this moment, but it's not the way it should be done. Many translation strings may be not visible (or not shown) during this kind of translation. Search&Find&Replace is not so easy way to do translation thing.

    I know oracle is not interested in investing into netbeans translation for not-so-popular languages. Nonetheless i would love to see:

    - provide ant(?) task in netbeans main repository for extracting translation files with the proper paths and another task for bundling translated files into correct jar packages (and better in clusters)

    - (or) keeping original (english) translation files in l10n repository in sync with main repo (right now there is no original source data)

    With this data we can create OmegaT projects for each language and translate *all* strings that should be translated and not only this visible ones. Result of this work can be then back-integrated into l10n repositories (or keep separated in community translations repo). But it's only my POV.

  • Geertjan Wednesday, July 16, 2014

    Well, I'm part of Oracle and I'm extremely interested in investing into NetBeans translation for not-so-popular languages. Oracle as a whole, too, but right now the priorities are different. At some point, there'll be a new focus again on translations of these languages. In the meantime, the more we translate, the better. Also, it is great to be able to provide translated modules to anyone creating NetBeans Platform applications. We're getting hold of the original English translation files and they'll become part of this project too and then you can use them with OmegaT or whatever tool you like.

    Which invisible strings do you need to be translated, can you give me some examples of that?

    PS: I checked in your pl module, I think you missed that in your checkin but it was simple to create. Simplicity is the key of this approach to translation.

  • slawek mikula Wednesday, July 16, 2014

    Yep Geertjan, I'm aware of all what You have said and I understand it. The direction of development in Netbeans is clear and there is much to be done in other areas, thus I do not comply excessively :) Great that you'll try to provide actual upstream original translation files !

    Invisible strings == strings, that does occur in e.g. dialog boxes, error messages etc. which during translation by clicking and searching could be omitted (error does not occur, user does not dive deep enough to get to new message dialog etc.). Right now i cannot think of any. I was referring only to the overall process, not real example.

    PS1. Thanks for commit correction. Module is on my local repo, but hasn't been commited yesterday. My mistake.

    PS2. Does email notification of new comments works ? I haven't received any, but checked appropriate checkbox.

  • Geertjan Sunday, July 20, 2014

    Thanks for the thoughts and no I don't think the notification thing works. I think, so far, until I see other evidence, that invisible strings, whatever they are, are not important because no one can see them. The good thing about the approach we're taking is that we're focusing on the most visible strings, i.e., those that are most relevant to the user, whereas any other approach treats all strings as being equal. I don't think all strings are equal. Some are a lot more equal than others.

  • Danijel Monday, September 15, 2014

    First of all thanks Geertjan for all the up to date information on how to start translating Netbeans platform. It took me quite some time until I found this blog and I must say there is big mess regarding the information how to properly start translating. I am still a bit confused what is the "right" and "clean" way to do it but at least it is a start.

    Just like slawek mentioned in his first post there are some deprecated sites, broken links and closed projects that should be cleaned up as to not confuse potential translators.

    I am also writing as I would like to join the project and maybe help with setting up the fallowing translations (username on java.net is MrMiso):

    - Slovenian (Prio) - My native language

    - Croatian

    - Turkish

    - German

    For Turkish and German I would probably just set the jars as most of this languages are already mostly translated at least the important parts.

    PS: Before I found this blog I managed to find your videos on youtube. It would be awesome if you could add this blog link into info tab of your videos as finding it wasn't as easy as someone would think.

  • guest Saturday, October 4, 2014

    Hi How are you? I want to contribute with translation

  • Geertjan Sunday, October 5, 2014

    Hi -- we've been mailing each other about that already, haven't we? Please use my e-mail and not my blog. Just start translating, you're part of the project already.

  • Sergii Lapin Sunday, October 12, 2014

    Dear Geertjan, I wanna translate Netbeans into Ukrainian. Please add me to project on java.net

    My username - seha16


  • guest Tuesday, October 28, 2014

    Dear Geertjan,

    I would like to complete some missing lables in German. My Username is shuetter.


  • guest Monday, January 25, 2016

    Dear Geertjan,

    I would like to translate netbeans in my native language (italian). Could you please add me to the project? My java.net username is nickdick

    Thank you.


  • Geertjan Tuesday, February 2, 2016

    Explain you the steps? They're explained already above, please follow the steps. Thanks and looking forward.

  • Dino Tuesday, February 2, 2016

    Hi Geertjan,i am new here and i wan't to translate net bean's platform to Croatian language (my native).

    my user name is : dino.halar19@gmail.com

    best reagrds,Dino. :)

Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.