Multilanguage Legend

This chapter describes how to create and edit multilingual legend texts. The legend texts allows to create multilingual legends for WebOffice 10.9 R4. This chapter describes how to create them and implement them in your WebOffice 10.9 R4 project.

You can edit existing legend texts XML files or create them from scratch.

 

icon_warning

CAUTION!

At the moment it is not possible to edit legend texts via WebOffice author standalone because this functionality is currently not implemented.

However, the creation and editing of the legend texts is still possible with the WebOffice author as ArcMap extension.

As of version WebOffice 10.7, WebOffice author (ArcMap) is officially deprecated and not released with a current WebOffice version. However, for this tutorial, the WebOffice author (ArcMap) can still be used as a workaround.

A WebOffice author (ArcMap) version can be downloaded here: WebOffice 10.6 R2 Updates (vertigis.com).

The documentation for the WebOffice author (ArcMap) can be found in an older user manual version.

 

icon_comment

All multilingual legend text XML files must be stored in the following directory: C:\Tomcat\webapps\<WebOffice application>\WEB-INF\work\multilang_legend.

To use the generation of multilingual legend texts, they must be enabled in the Application Configuration.

 

The following steps are necessary to manually create and edit multilingual legends:

 

1.Open WebOffice author standalone and the Application Configuration. Navigate to WebOffice > Application configuration > WebOffice and change the parameter Multilingual legend? to true. Reload the application afterwards.

 

Activate multilingual legends feature in WebOffice application

Activate multilingual legends feature in WebOffice application

 

2.The first step is to open the Legend Texts dialog (found in the EXTRAS section) in the WebOffice author (ArcMap) and select one of your published map services for which you want to create a multilingual legend. Click the Get Services button to retrieve all available services and then select the one you want.

 

Open 'Legend texts' in WebOffice author (ArcMap) and get services

Open 'Legend texts' in WebOffice author (ArcMap) and get services

 

3.After the selection, the Base language (the language in which all legend values are defined in the ArcGIS MXD) can be selected. This will automatically open a dialog box to load an already existing XML file. If you do not have an existing multilingual legend XML file, cancel the dialog and click the Create Legend button instead. A list of IDs will be automatically displayed in the dialog box, representing all legend texts of the service with the nomenclature <layer name>~<legend name>.

 

Creating a legend file in the WebOffice author (ArcMap) 

Creating a legend file in the WebOffice author (ArcMap)

 

If you go to the C:\Tomcat\webapps\<WebOffice application>\WEB-INF\work\multilang_legend directory, you will see that a new XML file named <server name>_[<subfolder name>-]<service name>_<locale>.xml has been created with the same IDs as displayed in the legend text dialog box.

 

Created multilingual legends XML file

Created multilingual legends XML file

 

4.Then select the target language (the language in which the existing legend values should be translated) and again a file dialog window will open, allowing you to import an XML file (in case you want to update an already existing legend). If you are creating a legend for the first time, cancel the dialog and click the Translate button (for an automatic translation based on Microsoft Bing Translate) or translate the values manually.

 

icon_comment

You only need to translate the legend name and not the layer name.

Example: If the value Other Symbols~~Church should be translated to the language German, you only have to enter Kirche as value on the right side.

Layer names can be translated to WebOffice author standalone using the Translations functionality.

 

Selection of target language (1) and automatic translation of legend (2), automatic translation of single legend values (3), manual translation (4), or basis for copying a legend text to a target language (5) and exporting the target language legend file (6)

Selection of target language (1) and automatic translation of legend (2), automatic translation of single legend values (3), manual translation (4), or basis for copying a legend text to a target language (5) and exporting the target language legend file (6)

 

5.After the translation is finished, click the Export target language button to create the multilingual legend XML file for the selected target language.

 

Export target language in WebOffice author (ArcMap)

Export target language in WebOffice author (ArcMap)

 

6.The generated base files are then placed in the multilang_legend folder of your WebOffice 10.9 R4 application (e.g. C:\Tomcat\webapps\<WebOffice application>\WEB-INF\work\multilang_legend).

 

Display of the multilingual legend XML file for German and English in the multilang_legend directory of the application

Display of the multilingual legend XML file for German and English in the multilang_legend directory of the application

 

7.Afterwards, reload the WebOffice application and clear the browser cache if necessary.

8.Start the WebOffice project and change the language in the Project Settings. Legend texts in the Table of Content are now also displayed translated.

 

Example of multilingual legends in the Table of Content (left: English; right: German)

Example of multilingual legends in the Table of Content (left: English; right: German)

 

icon_comment

The files from the WebOffice Sample Project, which can be found on the WebOffice10.9R4-DVD in the following directory, can be used as a template: WebOffice10.9R4-DVD\SampleProject\Project\multilang_legend

 

icon_cross-reference

See the Internationalization chapter for the concept of full support for the internationalization of WebOffice 10.9 R4 projects.