Localization tips for OpenOffice.org 2.0

 

 

Javier SOLA - www.khmeros.info - Last edited 06/02/2006 - Top

 

This file contains work in progress.

The contents of this pages might (and probably will) change often without warning

 

This page constains information received in the mailing list or directly from the developers.

 


 

Wizard localization

 

Warnings:

  • You have to be very careful editing wizard template documents, because if you do something wrong the wizards may crash or do not work properly.

  • Never open template documents directly by File->Open. You have to use File->Templates->Edit and navigate to the files and open them, otherwise you will lose important template document information (e.g. the description of the template)

  • Do not change the names of template files for the wizards, because the wizards need some elements of the filenames to work.

Some general important tips on editing the template files for the letter and the fax wizard (most of this is also true for all other template files):

  • Never translate the strings <First Name> <Company> and so on in the address field. The wizards looks for those strings and the user will not see them. In most cases strings in <> should not be translated.

  • Never change the name of any of the sections or styles in the template, the wizard needs the correct english section and style names.

  • You have to translate the elements of the templates second page also. For this you have to somehow force the document to have a second page (e.g. by a manual page break), translate the strings and then delete that second page. The document still contains those texts because they are in the headers.

  • Do only change/translate and not delete any of the placeholders or user fields in the templates

  • Change the page format and all templates language settings (e.g. in the styles) to the usual ones of the language you translate for

Unfortunately, there is no possibility to change the font used for the yellow help windows/boxes. Those windows always use the standard UI font of your system. On StarOffice this is the installed soui.tff font. I do not know which font is taken on your system for this if you use OpenOffice, because OOo is not shipped with a special UI font. The UI font usage is then handled by the font fallback mechanism in OOo. If this font does not contain the characters you need you get those little empty squares - an empty square means that the correct symbol is not in the font. This may also help you to find out which font is used: The font used for the yellow boxes is the same as for the menus and dialogs and so on.

 

There is no need to translate the dialog window, that appear when you open a file like bus-elegant_l. If you use File->Templates->Edit you will not get this dialog and the users will also never see them because the letter wizard template files are opened by the letter wizard itself.

 


 

Database Module - Should the field names in the Database creation wizards be localized

 

I asked the developer and he says, because we support so many different databases, please only use a-z characters, no umlauts or hyphens, etc.

 

Plus some extra info on these strings:

 

PRJ            officecfg

 

Filename registry\data\org\openoffice\Office\TableWizard.xcu

 

These strings appear in the Table Wizard in list boxes.

 

No spaces are allowed because they are field names.

 

*important*

Every 2nd string is a "short name" or short form of the full length string before it.

 

The short names _cannot exceed 10 characters_ (due to database restrictions).

 

Therefore the translation cannot exceed 10 characters either.

(For CJK: You can use 10 double byte Asian characters.)

 

 

 


 

Math Module - Some Strings have localization restrictions

 

Rules regarding the l10n of some of the strings that have caused bugs in some languages in the past, and may still be causing problems.

 

In the math module 66 strings need to comply to some rules, otherwise some functionality in math is broken.

 

The 66 strings have some common "Resource information":

 

PRJ            starmath

Filename       source\symbol.src

GID            RID_UI_SYMBOL_NAMES

Type           itemlist

 

The strings are names for the greek characters and some extra symbol names.

 

The rules for this group of 66 strings are:

  • The first character has to be an alphabetic character  (any character set allowed).

  • All following characters must be alphanumerical characters (any character set allowed) or the ASCII decimal dot (a dot from a different character set or with a different character code is not allowed).

  • The above rule especially does not allow for spaces or underscore of any kind to be used.

  • An ASCII dot should not be followed by another one.

  • Case does matter and may be used (That is "alpha" may be used to denote the lowercase greek character and "ALPHA" for the capitalized one).

  • No double entries allowed

 

A recommendation for Asian languages is to use the same string as the english one, since there is no uppercase or lowercase.

 

Another recommendation is on the use of word separation. In eqch language only one method should be used. Methods are:

  • Use no method at all: strictlygreater

  • Use one decimal dot: strictly.greater

  • Use capitalized letters: strictlyGreater

Examples:

 

Good:

-----

alpha

ALPHA

strictly.greater

strictlyGreater

 

Not allowed:

------------

strictly..greater

9trictly

strictly_greater

strictly greater

strictly-greater

 


 

There are lots of strings that look very much like field names in sc/source/ui/src

Q. Besides the wizards in In POTs made from contents of sc/source/ui/src, there are lots of strings that look very much like field names (or function names). The whole block of strings around ~800-~1500 (financial calculations and  other functions) seems to run like this: .1 = function   description, .even_number = function (or parameter) name, .odd_number =  function (or parameter) description.

So, I'd like to make sure, what of these is translatable, and what isn't?

A. All of sc/source/ui/src/scfuncs.src is translatable, with the exception of the ExtraData structs of course, which isn't exported to POTs anyway.

You identified the strings of RID_SC_FUNCTION_DESCRIPTIONS* correctly, first string of a function is it's description, then alternating follow a parameter's name and it's description. However, the parameter names should be consistent and identical for identical functionality, e.g  "Database field" for all parameters that are used as a database field,  or "Number" for any number. Usage could have been defined in the glossary of your language.  What looks like function names in sc/source/ui/src/globstr.src, for example RID_GLOBSTR.STR_* names SUM, COUNT and so on, should be identical to the real function names used in sc/source/core/src/compiler.src for consistency, but isn't necessary for functionality. These names are offered to the user to choose from in some dialogs and are mapped to the real functions then.

The function names used in formulas and in the function pilot are defined in sc/source/core/src/compiler.src and have the constraints that they can't contain spaces or symbols or other punctuation characters than dot ('.') or underscore ('_'); letters and digits are fine (must start with a letter), the definition of letter here includes accented characters, CJK characters, and so on.


 

Should list with semicolons such as Left;Center;Right be translated

Q. I'm having doubts over the translation of lists of terms separated with semicolons, like Left;Center;Right etc. Should they be translated at all? In source code, as far as I could understand, they seem to be used as keys, not as displayed strings. Am I right? Perhaps, it'd better to revert the translated counterparts of these to English originals?

A. I f you take a look at the original .src files and the corresponding localize.sdf files you'll see that the entries are translated.Especially the .src files indicate so, as that is what the developers maintain.


You should submit localised versions of some items:

a) A number of help images in ./default_images/res/helpimg/ab_CD (ab_CD being you locale ISO code).  Look at the ones for other languages. Once you include the new files, the /helpcontent2/util/helpimg.ilst should also me modified.

To view where int he program these files are used, you can consult this document. (OOo 2.0 format).

b) Similarly, other images that might be used and you should give a look at are in ./default_images/res/commandimagelist

c) The folder ./helpcontent2/source/auxiliary/ab-CD/ needs to be created and populated.

You can just copy the /helpcontent2/source/auxiliary/en-US/ folder to a folder that has your ISO-code as folder name. Inside you will find two types of files: config files (*.cfg) and style sheets (.css). In the .cfg files you only have to change the ISO code to your own in the line:

Language=en-US 

In the .css files you have to make sure that the defined fonts work for your language (script), as, for example, in:

body, p, h1, h2, h3, h4, h5, h6, .listitem, .listitemintable, .tablecontent, .tablecontentintable
{ font-family: "Bitstream Vera Sans",Arial,Helvetica,Lucida,Geneva,Helmet,sans-serif,"Andale Sans UI","Arial Unicode MS","Lucida Sans Unicode",Tahoma; }

.code, .codeintable, .example, .exampleintable, .literal, .literalintable, .path, .pathintable
{ font-family: "Bitstream Vera Sans Mono",Cumberland,"Courier New",Courier,"Lucida Sans Typewriter","Lucida Typewriter",Monaco,Monospaced; margin-top: 1pt; margin-bottom: 1pt;}

 

d) ./extras/source/palettes/lang/ab-CD/ also needs to be created and populated, as well as all the other bits and bobs in the extras folder, templates, wizards etc., such as in: autotext, misc_config, migration, templates, wordbook. These also need the ab-CD lang directory created and populated with suitable translated files. Information on how to translate these files is here.

A compress file with all the above mentioned files for 680_m100 can be found here (1.4 Mb).


In Windows, in  Add/Remove program, there is a support information for OpenOffice.  I want to modify the URL.  Specifically, I want to modify 
the HelpLink, URLInfoAbout and URLUpdateInfo.  How to do it? 

I have tried to change:
.\instsetoo_native\inc_openoffice\windows\msi_languages\
roperty.ulf, and localize.sdf
Ingo Schmidt answered:
Hi Work Klo,

Property.ulf and the corresponding sdf file are the correct files. Did you rebuild the ulf files? The file that is built from ulf and sdf files
and that is used during packaging is the file

instsetoo_native\common.pro\misc\win_ulffiles\Property.mlf

The content of this file is integrated into the msi database.

Could someone please advise me how to get a language listed on the OOo web site. 
If you go to http://download.openoffice.org/2.0.1/ British English is not listed in the box for download.
AFAIK, before getting listed, the version to be released has to pass QA in the responsible native language group. 
For test cases see http://qa.openoffice.org/testcase/index.html
I suggest to contact the dev@qa list for further procedures.
  Eike