Repository: microsoft/terminal (language: cpp)

Issue:
Rename the `newTabPosition` strings
Follow-up from #13421

### Settings UI
Position of the new tab --> Position of newly created tabs
Specifies position of the new tab --> Specifies where new tabs appear in the tab row
At the end --> After the last tab
After current tab	--> After the current tab

### JSON
atTheEnd --> afterLastTab
afterCurrentTab --> afterCurrentTab

No need for legacy converter

### Code
we _should_ rename the enums to match the new names


Discussion / hints:
Is this a legacy converter? It doesn't compile for me without it. https://github.com/microsoft/terminal/blob/6c2316df44779deb9480c769e3354187660e6736/src/cascadia/TerminalSettingsModel/TerminalSettingsSerializationHelpers.h#L240-L246


Fix patch:
diff --git a/doc/cascadia/profiles.schema.json b/doc/cascadia/profiles.schema.json
index 2ec1ac9033a..1543b7b3986 100644
--- a/doc/cascadia/profiles.schema.json
+++ b/doc/cascadia/profiles.schema.json
@@ -1976,15 +1976,14 @@
           "type": "string"
         },
         "newTabPosition": {
-          "default": "atTheEnd",
-          "description": "Specifies position of the new tab. Possible values are \"atTheEnd\" and \"afterCurrentTab\".",
+          "default": "afterLastTab",
+          "description": "Position of newly created tabs. Possible values are \"afterLastTab\" and \"afterCurrentTab\".",
           "enum": [
-            "atTheEnd",
+            "afterLastTab",
             "afterCurrentTab"
           ],
-          "type": "string"
-        }
-      },
+          "type": "string"        
+        },
         "autoHideWindow": {
           "default": false,
           "description": "If enabled, Terminal window will be hidden as soon as it loses focus.",
diff --git a/src/cascadia/TerminalSettingsEditor/Resources/en-US/Resources.resw b/src/cascadia/TerminalSettingsEditor/Resources/en-US/Resources.resw
index a863c90db33..391d7039ddf 100644
--- a/src/cascadia/TerminalSettingsEditor/Resources/en-US/Resources.resw
+++ b/src/cascadia/TerminalSettingsEditor/Resources/en-US/Resources.resw
@@ -236,20 +236,20 @@
     <comment>A description for what the "always show tabs" setting does. Presented near "Globals_AlwaysShowTabs.Header".</comment>
   </data>
   <data name="Globals_NewTabPosition.Header" xml:space="preserve">
-    <value>Position of the new tab</value>
-    <comment>Header for a control to select position of new tab.</comment>
+    <value>Position of newly created tabs</value>
+    <comment>Header for a control to select position of newly created tabs.</comment>
   </data>
   <data name="Globals_NewTabPosition.HelpText" xml:space="preserve">
-    <value>Specifies position of the new tab</value>
-    <comment>A description for what the "Position of the new tab" setting does.</comment>
+    <value>Specifies where new tabs appear in the tab row</value>
+    <comment>A description for what the "Position of newly created tabs" setting does.</comment>
   </data>
-  <data name="Globals_NewTabPositionAtTheEnd.Content" xml:space="preserve">
-    <value>At the end</value>
-    <comment>An option to choose from for the "Position of the new tab" setting. When selected new tab appears at the end.</comment>
+  <data name="Globals_NewTabPositionAfterLastTab.Content" xml:space="preserve">
+    <value>After the last tab</value>
+    <comment>An option to choose from for the "Position of newly created tabs" setting. When selected new tab appears after the last tab.</comment>
   </data>
   <data name="Globals_NewTabPositionAfterCurrentTab.Content" xml:space="preserve">
-    <value>After current tab</value>
-    <comment>An option to choose from for the "Position of the new tab" setting. When selected new tab appears after currently selected tab.</comment>
+    <value>After the current tab</value>
+    <comment>An option to choose from for the "Position of newly created tabs" setting. When selected new tab appears after the current tab.</comment>
   </data>
   <data name="Globals_CopyOnSelect.Header" xml:space="preserve">
     <value>Automatically copy selection to clipboard</value>
@@ -1469,4 +1469,4 @@
     <value>If enabled, the window will be hidden as soon as it loses focus.</value>
     <comment>A description for what the "Automatically hide window" setting does.</comment>
   </data>
-</root>
\ No newline at end of file
+</root>
diff --git a/src/cascadia/TerminalSettingsModel/GlobalAppSettings.idl b/src/cascadia/TerminalSettingsModel/GlobalAppSettings.idl
index 26ae0e10585..849cdd40824 100644
--- a/src/cascadia/TerminalSettingsModel/GlobalAppSettings.idl
+++ b/src/cascadia/TerminalSettingsModel/GlobalAppSettings.idl
@@ -44,7 +44,7 @@ namespace Microsoft.Terminal.Settings.Model
 
     enum NewTabPosition
     {
-        AtTheEnd,
+        AfterLastTab,
         AfterCurrentTab,
     };
 
diff --git a/src/cascadia/TerminalSettingsModel/MTSMSettings.h b/src/cascadia/TerminalSettingsModel/MTSMSettings.h
index 16c9b8ea52d..5b2882c7e6c 100644
--- a/src/cascadia/TerminalSettingsModel/MTSMSettings.h
+++ b/src/cascadia/TerminalSettingsModel/MTSMSettings.h
@@ -31,7 +31,7 @@ Author(s):
     X(bool, TrimBlockSelection, "trimBlockSelection", true)                                                                                                \
     X(bool, DetectURLs, "experimental.detectURLs", true)                                                                                                   \
     X(bool, AlwaysShowTabs, "alwaysShowTabs", true)                                                                                                        \
-    X(Model::NewTabPosition, NewTabPosition, "newTabPosition", Model::NewTabPosition::AtTheEnd)                                                            \
+    X(Model::NewTabPosition, NewTabPosition, "newTabPosition", Model::NewTabPosition::AfterLastTab)                                                        \
     X(bool, ShowTitleInTitlebar, "showTerminalTitleInTitlebar", true)                                                                                      \
     X(bool, ConfirmCloseAllTabs, "confirmCloseAllTabs", true)                                                                                              \
     X(hstring, Theme, "theme")                                                                                                                             \
diff --git a/src/cascadia/TerminalSettingsModel/TerminalSettingsSerializationHelpers.h b/src/cascadia/TerminalSettingsModel/TerminalSettingsSerializationHelpers.h
index f600db2f9c8..0cd768e3f8d 100644
--- a/src/cascadia/TerminalSettingsModel/TerminalSettingsSerializationHelpers.h
+++ b/src/cascadia/TerminalSettingsModel/TerminalSettingsSerializationHelpers.h
@@ -240,7 +240,7 @@ JSON_ENUM_MAPPER(::winrt::Windows::UI::Xaml::ElementTheme)
 JSON_ENUM_MAPPER(::winrt::Microsoft::Terminal::Settings::Model::NewTabPosition)
 {
     JSON_MAPPINGS(2) = {
-        pair_type{ "atTheEnd", ValueType::AtTheEnd },
+        pair_type{ "afterLastTab", ValueType::AfterLastTab },
         pair_type{ "afterCurrentTab", ValueType::AfterCurrentTab },
     };
 };


Test patch: