Difference between revisions of "Translating"

From Gestinux Wiki
Jump to navigation Jump to search
(→‎Initial Setup: Image Translating_1)
Line 23: Line 23:
 
Before starting a new translation, you must discover what code applies to the language you are translating.
 
Before starting a new translation, you must discover what code applies to the language you are translating.
  
Languages ​​are identified in accordance with standard Gestinux [http://www.gnu.org/software/gettext/manual/html_node/Locale-Names.html POSIX] codes, which all have the double xx_YY format.
+
Languages ​​are identified in accordance with standard [http://www.gnu.org/software/gettext/manual/html_node/Locale-Names.html POSIX] codes, which all have the double xx_YY format.
  
 
The lowercase xx part of the code identifies the primary language, according to the  [http://en.wikipedia.org/wiki/List_of_ISO_639-1_codes ISO-639-1] standard.
 
The lowercase xx part of the code identifies the primary language, according to the  [http://en.wikipedia.org/wiki/List_of_ISO_639-1_codes ISO-639-1] standard.

Revision as of 21:18, 4 March 2013

 Español

{{#CustomTitle:How to translate Gestinux}}

This page explains how to translate Gestinux without knowing much about Pascal or other programming languages or the Lazarus IDE.

We ask that you translate only into your native language. Ideally, you should understand French because Gestinux was originally written in French.

Where do you start translating, and what should you then move on to translate thereafter?

Ideally, you should start to translate the software itself, before starting to translate any documentation.

The translated software will be used to create a set of test data and make fresh screenshots showing the newly translated language.

Then you can gradually translate the documentation.

Translating the software

Only version 1.0 of Gestinux needs to be translated. The following paragraphs cover the various steps involved in completing your translation task.

If you understand English, you can consult the internal translation mechanism for more information.

The code for your language

Before starting a new translation, you must discover what code applies to the language you are translating.

Languages ​​are identified in accordance with standard POSIX codes, which all have the double xx_YY format.

The lowercase xx part of the code identifies the primary language, according to the ISO-639-1 standard. The uppercase YY part identifies any possible language variant (usually with a country code), according to the ISO-3166-1 standard.

You should use the referenced ISO codes. If you invent a new code, the risk is that they may be formalized differently later.

Language code examples:

  • Fr_FR: French "de France"
  • Fr_CA: Quebec
  • En_US: English (United States of America)
  • Sv_SE: Sweden "Sweden"

If you are in any doubt, ask for confirmation on the forum.

The source file to translate

Gestinux 1.0 supports translations in a "text" xx_YY.ini file.

In general, these files are in a folder named languages ​​at the same level as the executable Gestinux. However, to comply with Debian Linux rules (including Ubuntu), the files for these distributions are in / usr / share / gestinux / languages

These files are installed as write-only. Do not try to modify or unprotect them at this location. If you want to improve an existing (perhaps partial) translation, you should copy that file to a folder you choose, where you have write permissions.

You can also create a file within your personal documents. The first three lines must read:

[General]

LanguageCode =xx_YY

LanguageName =name of language (in English)


Once you have created this file, you should put it in the Gestinux directory sources (managed by SVN) and lock it to prevent anyone else editing the same file simultaneously. This must be done before you complete the translation, and the earlier the better.

If you know how to use SVN, ask to be given a "developer" profile, otherwise explain what you are doing on the forum and attach the file to your message translation. Other developers will use SVN directly. In either case, use the forum to communicate with the other developers.

Initial Setup

From the Gestinux menu choose Settings Languages tab and Add a translation:

Translating 1.png

  • The language reference is necessarily one of the languages ​​installed with gestinux. It will be your source. If possible, choose French, since the English pages are currently not complete.
  • Find your translation file (created as described in the previous section) by clicking the selection button.
  • Check the box "Use translation" for translations of this file to be used. Otherwise the reference language will be used.

Entering a new translation

You can translate globally by clicking the Translate button. In this case, you will have a list (to the left) of the various application windows, as well as some sections unrelated to a window. Global translation is required for sections that do not correspond to a window, and to check you have not overlooked any section. You can use the Next Missing button to find the first missing translation.

It is also possible to press CTRL+F4 from any application window to view and translate the section corresponding to that window. In this case, you will see only that window listed at the left. This method has the advantage that once the translation you can use the F4 key to toggle between viewing the base language and your language translation (and vice versa).

GTranslator.png

Anyway, for the selected section, a list of key translation is displayed. The reference translation (which cannot be changed) is displayed below, and you can enter or edit the translation in your language. Registration is automatic when you change key.

The symbol <CR> skips a line, and should be used for messages.

Installing new translations

If possible, get another native speaker to read and check your work. Once the translation is complete, unlock the file in SVN if you know how, or ask via the forum for another developer to do this for you.

If you contribute a commonly used language, your translation will be added to the next version of Gestinux.

If you contribute a rare language translation, or you don't want to wait for the next Gestinux version, it is possible to make a package that includes an additional language for various target systems (Windows, Debian, ...). You can figure out how to do this yourself or ask a developer.

When you run it for the first time on a workstation, Gestinux tries to activate the correct translation automatically, depending on the computer's language. Unfortunately, Windows does not know the POSIX language codes, and there are cases where this is not automatic. A slight software modification is required that can be obtained from the developers. This problem does not exist on Linux systems.

Providing translation data

A country list has to be created for each language available in Gestinux. This is contained in the xx_YY_countries.txt file that Gestinux loads automatically when its database is created (or audited) provided that you have earlier selected the appropriate language.

It is also helpful if you can create test cases in the language translated for the country (or countries) that use that language. You can export the database so that it can be hosted on gestinux.net and so become accessible to anyone worldwide.

If your country has state-specific tax(es), these can also be integrated into the software. If you do not make a about editing, ask a developer on the forum, sending examples.


Translating the documentation

Having translated the program software (or possibly before) it will also be helpful if you can translate the documentation (which is in the form of a wiki).

Currently there are about 100 pages to translate, but some are more important than others.

See how to create or edit pages of this wiki.

There is a way to list the remaining untranslated pages (or those whose original has been modified after translation). For now, this method is not available online, so if you would value this facility, ask on the forum.