JAL-3187 i18n for titles in windows/tabs
authorJim Procter <jprocter@issues.jalview.org>
Wed, 19 Feb 2020 18:46:25 +0000 (18:46 +0000)
committerJim Procter <jprocter@issues.jalview.org>
Wed, 19 Feb 2020 18:46:25 +0000 (18:46 +0000)
resources/lang/Messages.properties
src/jalview/gui/SplitFrame.java

index 042ce28..3d2ffb1 100644 (file)
@@ -768,6 +768,7 @@ label.varna_params = VARNA - {0}
 label.sequence_feature_settings = Sequence Feature Settings
 label.sequence_feature_settings_for = Sequence Feature Settings for {0}
 label.sequence_feature_settings_for_view = Sequence Feature Settings for view "{0}"
+label.sequence_feature_settings_for_CDS_and_Protein = Sequence Feature Settings for CDS and Protein
 label.pairwise_aligned_sequences = Pairwise Aligned Sequences
 label.original_data_for_params = Original Data for {0}
 label.points_for_params = Points for {0}
index 77d8a96..948b73b 100644 (file)
@@ -865,8 +865,8 @@ public class SplitFrame extends GSplitFrame implements SplitContainerI
     {
       showInternalFrame = true;
       featureSettingsPanels = new JTabbedPane();
-      featureSettingsUI = new JInternalFrame(
-              "Feature Settings for CDS and Protein Views");
+      featureSettingsUI = new JInternalFrame(MessageManager.getString(
+              "label.sequence_feature_settings_for_CDS_and_Protein"));
       featureSettingsPanels.setOpaque(true);
       featureSettingsUI.setContentPane(featureSettingsPanels);
       createDummyTabs();
@@ -885,15 +885,19 @@ public class SplitFrame extends GSplitFrame implements SplitContainerI
     if (pos == 0)
     {
       featureSettingsPanels.removeTabAt(0);
-      featureSettingsPanels.insertTab("CDS", null,
-              (Component) featureSettings, "Feature Settings for DNA CDS",
+      featureSettingsPanels.insertTab(tabName[0], null,
+              (Component) featureSettings,
+              MessageManager.formatMessage(
+                      "label.sequence_feature_settings_for", tabName[0]),
               0);
     }
     if (pos == 1)
     {
       featureSettingsPanels.removeTabAt(1);
-      featureSettingsPanels.insertTab("Protein", null,
-              (Component) featureSettings, "Feature Settings for Protein",
+      featureSettingsPanels.insertTab(tabName[1], null,
+              (Component) featureSettings,
+              MessageManager.formatMessage(
+                      "label.sequence_feature_settings_for", tabName[1]),
               1);
     }
     featureSettingsPanels.setSelectedComponent((Component) featureSettings);
@@ -907,14 +911,14 @@ public class SplitFrame extends GSplitFrame implements SplitContainerI
       {
         Desktop.addInternalFrame(featureSettingsUI,
                 MessageManager.getString(
-                        "Feature Settings for CDS and Protein Views"),
+                        "label.sequence_feature_settings_for_CDS_and_Protein"),
                 600, 480);
       }
       else
       {
         Desktop.addInternalFrame(featureSettingsUI,
                 MessageManager.getString(
-                        "Feature Settings for CDS and Protein Views"),
+                        "label.sequence_feature_settings_for_CDS_and_Protein"),
                 600, 450);
       }
       featureSettingsUI
@@ -975,7 +979,7 @@ public class SplitFrame extends GSplitFrame implements SplitContainerI
    */
   private String[] tabName = new String[] {
       MessageManager.getString("label.CDS"),
-      MessageManager.getString("label.Protein") };
+      MessageManager.getString("label.protein") };
 
   /**
    * create placeholder tabs which materialise the feature settings for a given