Skip to main content

Preparing for Folder Item Localization

Preparing for Folder Item Localization

This section describes how to prepare for localization of strings in the dashboards, pivot tables, and other folder items.

Default Domain

DeepSeeUser is the domain that the system uses by default when it looks for a localized string in a dashboard. For details, see the following sections.

Adding Strings to the Message Dictionary

Create a class that, when compiled, generates a set of entries in the Message Dictionary. In this class:

  • Extend %RegisteredObjectOpens in a new tab or any other class that provides access to the standard system macros.

  • Specify the DOMAIN class parameter. For example:

    Parameter DOMAIN = "DeepSeeUser";

    The DeepSeeUser domain is the most convenient choice, because this is the default domain.

  • Define a method that uses $$$Text(Localizable String) to refer to each string that the given domain should contain. Localizable String is an expression that evaluates to a string in this domain.

    You can specify any name for the method. It does not need to take any arguments or return any values. The following shows an example:

    ClassMethod DefineL18N()
    {
       set x=$$$Text("Dashboard Title")
       set x=$$$Text("Dashboard Description")
       set x=$$$Text("KeywordA")
       set x=$$$Text("KeywordB")
       
       set x=$$$Text("Control Label")
       set x=$$$Text("Tooltip")
       set x=$$$Text("Widget Title")
       set x=$$$Text("Chart Title")
    }
    

    Or, instead of $$$Text(Localizable String}, use $$$Text(@MessageID@) where MessageID is a numeric ID that is unique within the given domain.

When you compile this class, the compiler finds each instance of the $$$Text macro and adds values to the ^IRIS.Msg global in this namespace.

Using Localizable Strings in a Dashboard, Pivot Table, or Other Folder Item

In the definition of a dashboard, pivot table, or other folder item, use one of the following values instead of the exact string that you want to see:

  • $$$Localizable String

    Where Localizable String is a string defined in the default domain.

    For example:

    Dashboard example, showing $$$Dashboard Description used as the Description and $$$KeywordA used as a Keyword.

    For another example:

    Widget control example, showing $$$Control Label used as the Control Label and $$$Tooltip used as the Control Tooltip.

  • $$$Localizable String/OtherDomain

    Where Localizable String is a string defined in the domain given by OtherDomain.

    For example:

    Dashboard example showing $$$Dashboard Description1/myDomain used as the Description and $$$KeywordA1/myDomain as a Keyword.

    If you do not include the /OtherDomain part, the system looks for this string in the default domain.

    Important:

    For the name of a folder or of a folder item, use the following variation: $$$Localizable String#OtherDomain

    For example: use the following as a folder name: $$$My Folder#MyDeepSeeDomain

  • $$$@MessageID

    Where MessageID is a numeric message ID defined in the default domain.

  • $$$@MessageID/OtherDomain

    Where MessageID is a numeric message ID defined in the domain given by OtherDomain.

    If you do not include the /OtherDomain part, the system looks for this string in the default domain.

Use these values for any of the following strings in the folder item definition:

  • Folder name

  • Folder item name

  • (For dashboards) Dashboard title (if specified, this is shown instead of the dashboard name)

  • Item description

  • Keywords

  • Labels for dashboard controls

  • Tooltips for dashboard controls

  • Titles of widgets (but not their logical names)

  • Chart titles within dashboard widgets that display charts

FeedbackOpens in a new tab