diff --git a/.github/actions/spelling/allow/allow.txt b/.github/actions/spelling/allow/allow.txt
index 64bd05d091..630edfebce 100644
--- a/.github/actions/spelling/allow/allow.txt
+++ b/.github/actions/spelling/allow/allow.txt
@@ -23,6 +23,7 @@ dzhe
Emacspeak
Fitt
FTCS
+flac
gantt
gfm
ghe
diff --git a/.github/actions/spelling/allow/apis.txt b/.github/actions/spelling/allow/apis.txt
index 3ffc52f9fb..f7671d04f4 100644
--- a/.github/actions/spelling/allow/apis.txt
+++ b/.github/actions/spelling/allow/apis.txt
@@ -99,11 +99,9 @@ IImage
IInheritable
IMap
imm
-IMonarch
IObject
iosfwd
IPackage
-IPeasant
isa
ISetup
isspace
diff --git a/.github/actions/spelling/excludes.txt b/.github/actions/spelling/excludes.txt
index 4b6ae25b16..896211b8f1 100644
--- a/.github/actions/spelling/excludes.txt
+++ b/.github/actions/spelling/excludes.txt
@@ -99,6 +99,7 @@ Resources/(?!en)
^NOTICE.md
^oss/
^samples/PixelShaders/Screenshots/
+^src/cascadia/TerminalSettingsEditor/SegoeFluentIconList.h$
^src/interactivity/onecore/BgfxEngine\.
^src/renderer/atlas/
^src/renderer/wddmcon/WddmConRenderer\.
diff --git a/.github/actions/spelling/expect/expect.txt b/.github/actions/spelling/expect/expect.txt
index b09dcd5223..e78cb97139 100644
--- a/.github/actions/spelling/expect/expect.txt
+++ b/.github/actions/spelling/expect/expect.txt
@@ -163,6 +163,7 @@ CBN
cbt
Ccc
CCCBB
+CCCDDD
cch
CCHAR
CCmd
@@ -171,6 +172,7 @@ CCom
CConsole
CCRT
cdd
+cds
CELLSIZE
cfae
cfie
@@ -213,6 +215,7 @@ codepages
codepath
coinit
colorizing
+COLORONCOLOR
COLORREFs
colorschemes
colorspec
@@ -280,6 +283,8 @@ contypes
conwinuserrefs
coordnew
COPYCOLOR
+COPYDATA
+COPYDATASTRUCT
CORESYSTEM
cotaskmem
countof
@@ -366,6 +371,7 @@ DColor
dcommon
DComposition
dde
+DDDCCC
DDESHARE
DDevice
DEADCHAR
@@ -567,6 +573,7 @@ EOK
EPres
EQU
ERASEBKGND
+ERRORONEXIT
ESFCIB
esrp
ESV
@@ -837,6 +844,7 @@ IFACEMETHODIMP
ification
IGNORELANGUAGE
iid
+IInput
IIo
ILC
ILCo
@@ -856,6 +864,7 @@ inkscape
INLINEPREFIX
inproc
Inputkeyinfo
+inputpaneinterop
Inputreadhandledata
INPUTSCOPE
INSERTMODE
@@ -1348,6 +1357,7 @@ PNMLINK
pntm
POBJECT
Podcast
+POINTERUPDATE
POINTSLIST
policheck
POLYTEXTW
diff --git a/OpenConsole.sln b/OpenConsole.sln
index 7698af450d..fa94a4f8f0 100644
--- a/OpenConsole.sln
+++ b/OpenConsole.sln
@@ -178,7 +178,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Microsoft.Terminal.Control"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "WindowsTerminal", "src\cascadia\WindowsTerminal\WindowsTerminal.vcxproj", "{CA5CAD1A-1754-4A9D-93D7-857A9D17CB1B}"
ProjectSection(ProjectDependencies) = postProject
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE} = {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}
{9CBD7DFA-1754-4A9D-93D7-857A9D17CB1B} = {9CBD7DFA-1754-4A9D-93D7-857A9D17CB1B}
{CA5CAD1A-0B5E-45C3-96A8-BB496BFE4E32} = {CA5CAD1A-0B5E-45C3-96A8-BB496BFE4E32}
{CA5CAD1A-44BD-4AC7-AC72-F16E576FDD12} = {CA5CAD1A-44BD-4AC7-AC72-F16E576FDD12}
@@ -348,26 +347,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "UnitTests_SettingsModel", "
{CA5CAD1A-F542-4635-A069-7CAEFB930070} = {CA5CAD1A-F542-4635-A069-7CAEFB930070}
EndProjectSection
EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "MonarchPeasantSample", "src\tools\MonarchPeasantSample\MonarchPeasantSample.vcxproj", "{21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}"
- ProjectSection(ProjectDependencies) = postProject
- {18D09A24-8240-42D6-8CB6-236EEE820263} = {18D09A24-8240-42D6-8CB6-236EEE820263}
- EndProjectSection
-EndProject
-Project("{C7167F0D-BC9F-4E6E-AFE1-012C56B48DB5}") = "MonarchPeasantPackage", "src\tools\MonarchPeasantPackage\MonarchPeasantPackage.wapproj", "{F75E29D0-D288-478B-8D83-2C190F321A3F}"
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Microsoft.Terminal.Remoting.Lib", "src\cascadia\Remoting\Microsoft.Terminal.RemotingLib.vcxproj", "{43CE4CE5-0010-4B99-9569-672670D26E26}"
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Microsoft.Terminal.Remoting", "src\cascadia\Remoting\dll\Microsoft.Terminal.Remoting.vcxproj", "{27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}"
- ProjectSection(ProjectDependencies) = postProject
- {43CE4CE5-0010-4B99-9569-672670D26E26} = {43CE4CE5-0010-4B99-9569-672670D26E26}
- EndProjectSection
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "UnitTests_Remoting", "src\cascadia\UnitTests_Remoting\Remoting.UnitTests.vcxproj", "{68A10CD3-AA64-465B-AF5F-ED4E9700543C}"
- ProjectSection(ProjectDependencies) = postProject
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE} = {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}
- {43CE4CE5-0010-4B99-9569-672670D26E26} = {43CE4CE5-0010-4B99-9569-672670D26E26}
- EndProjectSection
-EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "wpf", "wpf", "{4DAF0299-495E-4CD1-A982-9BAC16A45932}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OpenConsoleProxy", "src\host\proxy\Host.Proxy.vcxproj", "{71CC9D78-BA29-4D93-946F-BEF5D9A3A6EF}"
@@ -1925,135 +1904,6 @@ Global
{CA5CAD1A-9B68-456A-B13E-C8218070DC42}.Release|x64.Build.0 = Release|x64
{CA5CAD1A-9B68-456A-B13E-C8218070DC42}.Release|x86.ActiveCfg = Release|Win32
{CA5CAD1A-9B68-456A-B13E-C8218070DC42}.Release|x86.Build.0 = Release|Win32
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.AuditMode|Any CPU.ActiveCfg = Debug|Win32
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.AuditMode|ARM64.ActiveCfg = Release|ARM64
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.AuditMode|x64.ActiveCfg = Release|x64
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.AuditMode|x86.ActiveCfg = Release|Win32
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Debug|Any CPU.ActiveCfg = Debug|Win32
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Debug|ARM64.ActiveCfg = Debug|ARM64
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Debug|ARM64.Build.0 = Debug|ARM64
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Debug|x64.ActiveCfg = Debug|x64
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Debug|x64.Build.0 = Debug|x64
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Debug|x86.ActiveCfg = Debug|Win32
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Debug|x86.Build.0 = Debug|Win32
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Fuzzing|Any CPU.ActiveCfg = Fuzzing|Win32
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Fuzzing|ARM64.ActiveCfg = Fuzzing|ARM64
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Fuzzing|x64.ActiveCfg = Fuzzing|x64
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Fuzzing|x86.ActiveCfg = Fuzzing|Win32
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Release|Any CPU.ActiveCfg = Release|Win32
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Release|ARM64.ActiveCfg = Release|ARM64
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Release|ARM64.Build.0 = Release|ARM64
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Release|x64.ActiveCfg = Release|x64
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Release|x64.Build.0 = Release|x64
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Release|x86.ActiveCfg = Release|Win32
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D}.Release|x86.Build.0 = Release|Win32
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.AuditMode|Any CPU.ActiveCfg = Release|Any CPU
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.AuditMode|ARM64.ActiveCfg = Debug|ARM64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.AuditMode|ARM64.Build.0 = Debug|ARM64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.AuditMode|ARM64.Deploy.0 = Debug|ARM64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.AuditMode|x64.ActiveCfg = Debug|x64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.AuditMode|x64.Build.0 = Debug|x64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.AuditMode|x64.Deploy.0 = Debug|x64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.AuditMode|x86.ActiveCfg = Debug|x86
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.AuditMode|x86.Build.0 = Debug|x86
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.AuditMode|x86.Deploy.0 = Debug|x86
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Debug|ARM64.ActiveCfg = Debug|ARM64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Debug|ARM64.Build.0 = Debug|ARM64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Debug|ARM64.Deploy.0 = Debug|ARM64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Debug|x64.ActiveCfg = Debug|x64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Debug|x64.Build.0 = Debug|x64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Debug|x64.Deploy.0 = Debug|x64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Debug|x86.ActiveCfg = Debug|x86
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Debug|x86.Build.0 = Debug|x86
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Debug|x86.Deploy.0 = Debug|x86
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Fuzzing|Any CPU.ActiveCfg = Release|Any CPU
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Fuzzing|ARM64.ActiveCfg = Fuzzing|ARM64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Fuzzing|x64.ActiveCfg = Release|x64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Fuzzing|x86.ActiveCfg = Release|x86
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Release|ARM64.ActiveCfg = Release|ARM64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Release|ARM64.Build.0 = Release|ARM64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Release|ARM64.Deploy.0 = Release|ARM64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Release|x64.ActiveCfg = Release|x64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Release|x64.Build.0 = Release|x64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Release|x64.Deploy.0 = Release|x64
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Release|x86.ActiveCfg = Release|x86
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Release|x86.Build.0 = Release|x86
- {F75E29D0-D288-478B-8D83-2C190F321A3F}.Release|x86.Deploy.0 = Release|x86
- {43CE4CE5-0010-4B99-9569-672670D26E26}.AuditMode|Any CPU.ActiveCfg = AuditMode|Win32
- {43CE4CE5-0010-4B99-9569-672670D26E26}.AuditMode|ARM64.ActiveCfg = AuditMode|ARM64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.AuditMode|ARM64.Build.0 = AuditMode|ARM64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.AuditMode|x64.ActiveCfg = Release|x64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.AuditMode|x64.Build.0 = Release|x64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.AuditMode|x86.ActiveCfg = AuditMode|Win32
- {43CE4CE5-0010-4B99-9569-672670D26E26}.AuditMode|x86.Build.0 = AuditMode|Win32
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Debug|Any CPU.ActiveCfg = Debug|Win32
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Debug|ARM64.ActiveCfg = Debug|ARM64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Debug|ARM64.Build.0 = Debug|ARM64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Debug|x64.ActiveCfg = Debug|x64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Debug|x64.Build.0 = Debug|x64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Debug|x86.ActiveCfg = Debug|Win32
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Debug|x86.Build.0 = Debug|Win32
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Fuzzing|Any CPU.ActiveCfg = Fuzzing|Win32
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Fuzzing|ARM64.ActiveCfg = Fuzzing|ARM64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Fuzzing|x64.ActiveCfg = Fuzzing|x64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Fuzzing|x86.ActiveCfg = Fuzzing|Win32
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Release|Any CPU.ActiveCfg = Release|Win32
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Release|ARM64.ActiveCfg = Release|ARM64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Release|ARM64.Build.0 = Release|ARM64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Release|x64.ActiveCfg = Release|x64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Release|x64.Build.0 = Release|x64
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Release|x86.ActiveCfg = Release|Win32
- {43CE4CE5-0010-4B99-9569-672670D26E26}.Release|x86.Build.0 = Release|Win32
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.AuditMode|Any CPU.ActiveCfg = AuditMode|Win32
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.AuditMode|ARM64.ActiveCfg = AuditMode|ARM64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.AuditMode|ARM64.Build.0 = AuditMode|ARM64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.AuditMode|x64.ActiveCfg = Release|x64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.AuditMode|x86.ActiveCfg = AuditMode|Win32
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.AuditMode|x86.Build.0 = AuditMode|Win32
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Debug|Any CPU.ActiveCfg = Debug|Win32
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Debug|ARM64.ActiveCfg = Debug|ARM64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Debug|ARM64.Build.0 = Debug|ARM64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Debug|x64.ActiveCfg = Debug|x64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Debug|x64.Build.0 = Debug|x64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Debug|x86.ActiveCfg = Debug|Win32
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Debug|x86.Build.0 = Debug|Win32
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Fuzzing|Any CPU.ActiveCfg = Fuzzing|Win32
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Fuzzing|ARM64.ActiveCfg = Fuzzing|ARM64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Fuzzing|x64.ActiveCfg = Fuzzing|x64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Fuzzing|x86.ActiveCfg = Fuzzing|Win32
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Release|Any CPU.ActiveCfg = Release|Win32
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Release|ARM64.ActiveCfg = Release|ARM64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Release|ARM64.Build.0 = Release|ARM64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Release|x64.ActiveCfg = Release|x64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Release|x64.Build.0 = Release|x64
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Release|x86.ActiveCfg = Release|Win32
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE}.Release|x86.Build.0 = Release|Win32
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.AuditMode|Any CPU.ActiveCfg = AuditMode|Win32
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.AuditMode|ARM64.ActiveCfg = AuditMode|ARM64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.AuditMode|ARM64.Build.0 = AuditMode|ARM64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.AuditMode|x64.ActiveCfg = AuditMode|x64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.AuditMode|x86.ActiveCfg = AuditMode|Win32
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.AuditMode|x86.Build.0 = AuditMode|Win32
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Debug|Any CPU.ActiveCfg = Debug|Win32
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Debug|ARM64.ActiveCfg = Debug|ARM64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Debug|ARM64.Build.0 = Debug|ARM64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Debug|x64.ActiveCfg = Debug|x64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Debug|x64.Build.0 = Debug|x64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Debug|x86.ActiveCfg = Debug|Win32
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Debug|x86.Build.0 = Debug|Win32
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Fuzzing|Any CPU.ActiveCfg = Fuzzing|Win32
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Fuzzing|ARM64.ActiveCfg = Fuzzing|ARM64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Fuzzing|x64.ActiveCfg = Fuzzing|x64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Fuzzing|x86.ActiveCfg = Fuzzing|Win32
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Release|Any CPU.ActiveCfg = Release|Win32
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Release|ARM64.ActiveCfg = Release|ARM64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Release|ARM64.Build.0 = Release|ARM64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Release|x64.ActiveCfg = Release|x64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Release|x64.Build.0 = Release|x64
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Release|x86.ActiveCfg = Release|Win32
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C}.Release|x86.Build.0 = Release|Win32
{71CC9D78-BA29-4D93-946F-BEF5D9A3A6EF}.AuditMode|Any CPU.ActiveCfg = AuditMode|Win32
{71CC9D78-BA29-4D93-946F-BEF5D9A3A6EF}.AuditMode|ARM64.ActiveCfg = AuditMode|ARM64
{71CC9D78-BA29-4D93-946F-BEF5D9A3A6EF}.AuditMode|ARM64.Build.0 = AuditMode|ARM64
@@ -2461,11 +2311,6 @@ Global
{CA5CAD1A-D7EC-4107-B7C6-79CB77AE2907} = {77875138-BB08-49F9-8BB1-409C2150E0E1}
{CA5CAD1A-082C-4476-9F33-94B339494076} = {77875138-BB08-49F9-8BB1-409C2150E0E1}
{CA5CAD1A-9B68-456A-B13E-C8218070DC42} = {BDB237B6-1D1D-400F-84CC-40A58FA59C8E}
- {21B7EA5E-1EF8-49B6-AC07-11714AF0E37D} = {A10C4720-DCA4-4640-9749-67F4314F527C}
- {F75E29D0-D288-478B-8D83-2C190F321A3F} = {A10C4720-DCA4-4640-9749-67F4314F527C}
- {43CE4CE5-0010-4B99-9569-672670D26E26} = {2D17E75D-2DDC-42C4-AD70-704D95A937AE}
- {27B5AAEB-A548-44CF-9777-F8BAA32AF7AE} = {2D17E75D-2DDC-42C4-AD70-704D95A937AE}
- {68A10CD3-AA64-465B-AF5F-ED4E9700543C} = {BDB237B6-1D1D-400F-84CC-40A58FA59C8E}
{4DAF0299-495E-4CD1-A982-9BAC16A45932} = {59840756-302F-44DF-AA47-441A9D673202}
{71CC9D78-BA29-4D93-946F-BEF5D9A3A6EF} = {E8F24881-5E37-4362-B191-A3BA0ED7F4EB}
{2D17E75D-2DDC-42C4-AD70-704D95A937AE} = {59840756-302F-44DF-AA47-441A9D673202}
diff --git a/README.md b/README.md
index 14f4c58bfe..71b0daad26 100644
--- a/README.md
+++ b/README.md
@@ -362,15 +362,6 @@ If you would like to ask a question that you feel doesn't warrant an issue
## Building the Code
-This repository uses [git
-submodules](https://git-scm.com/book/en/v2/Git-Tools-Submodules) for some of its
-dependencies. To make sure submodules are restored or updated, be sure to run
-the following prior to building:
-
-```shell
-git submodule update --init --recursive
-```
-
OpenConsole.sln may be built from within Visual Studio or from the command-line
using a set of convenience scripts & tools in the **/tools** directory:
diff --git a/build/StoreSubmission/Preview/PDPs/de-DE/PDP.xml b/build/StoreSubmission/Preview/PDPs/de-DE/PDP.xml
index f71e42e202..488e9d0da7 100644
--- a/build/StoreSubmission/Preview/PDPs/de-DE/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/de-DE/PDP.xml
@@ -56,15 +56,11 @@ Dies ist ein Open Source-Projekt, und wir freuen uns über die Teilnahme der Com
Version __VERSION_NUMBER__
-– Wir haben umgeschrieben, wie Konsolenanwendungen im Terminal gehostet werden! Melden Sie alle auftretenden Fehler.
-- Terminal unterstützt jetzt Sixels!
-- Sie können jetzt ein angedocktes Fenster öffnen, das Ausschnitte von Befehlen enthält, die Sie gespeichert haben, um sie später zu verwenden.
-- Für Benutzer der Eingabeaufforderung der neuesten Version von Windows 11 wird möglicherweise ein „Kurzer Tipp“-Symbol angezeigt, das installierbare Software von WinGet
- vorschlägt
-- Ausgewählter Text wird jetzt viel sichtbarer (und anpassbarer!)
-- Eine Reihe von Zuverlässigkeitsfehlern, Komfortproblemen und Ärgernissen wurden behoben.
+- Wir haben der Benutzeroberfläche durchschnittliche Einstellungen hinzugefügt, die nur einmal in der JSON-Datei vorhanden waren, einschließlich einer neuen Seite zum Anpassen des Layouts Ihres Menüs "Neue Registerkarte"!
+- Wir haben die Fensterverwaltung zurückgesetzt, um die Zuverlässigkeit zu verbessern; Melden Sie alle Fehler, die mit dem alias "wt.exe" auftreten.
+- Profile zeigen jetzt ein Symbol an, wenn sie ausgeblendet wurden oder auf programme verweisen, die deinstalliert wurden.
-Weitere Informationen finden Sie auf unserer GitHub-Releaseseite.
+Weitere Details finden Sie auf unserer GitHub-Releasesseite.
diff --git a/build/StoreSubmission/Preview/PDPs/en-US/PDP.xml b/build/StoreSubmission/Preview/PDPs/en-US/PDP.xml
index d535a80251..3e4fa3dbd8 100644
--- a/build/StoreSubmission/Preview/PDPs/en-US/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/en-US/PDP.xml
@@ -54,14 +54,11 @@ This is an open source project and we welcome community participation. To partic
- Version __VERSION_NUMBER__
+ Version __VERSION_NUMBER__
-- We've rewritten how console applications are hosted inside Terminal! Please report any bugs you encounter.
-- Terminal now supports Sixels!
-- You can now open a docked panel containing snippets of commands you have saved to use later
-- Command Prompt users on the latest Windows 11 release may see a "quick tip" icon that suggests installable software from WinGet
-- Selected text will now be much more visible (and customizable!)
-- A number of reliabilty bugs, convenience issues and annoyances have been fixed.
+- We've added dozens of settings to the UI that once only existed in the JSON file, including a new page for customizing the layout of your New Tab menu!
+- We have rearchitected window management to improve reliability; please file any bugs you encounter with the wt.exe alias
+- Profiles now show an icon if they've been hidden or refer to programs which were uninstalled.
Please see our GitHub releases page for additional details.
diff --git a/build/StoreSubmission/Preview/PDPs/es-ES/PDP.xml b/build/StoreSubmission/Preview/PDPs/es-ES/PDP.xml
index 0a414940f8..d93f10de27 100644
--- a/build/StoreSubmission/Preview/PDPs/es-ES/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/es-ES/PDP.xml
@@ -56,14 +56,11 @@ Este es un proyecto de fuente abierta y animamos a la comunidad a participar. Pa
Versión __VERSION_NUMBER__
-- Hemos reescrito cómo se hospedan las aplicaciones de consola en Terminal. Informe de los errores que encuentre.
-- Terminal ahora admite sixeles.
-- Ahora puede abrir un panel acoplado que contenga fragmentos de comandos que haya guardado para usarlos más adelante
-- Los usuarios del símbolo del sistema de la versión más reciente de Windows 11 pueden ver un icono de "sugerencia rápida" que sugiere software instalable de WinGet
-- El texto seleccionado ahora será mucho más visible (y personalizable)
-- Se han corregido varios errores de fiabilidad, problemas de comodidad y molestias.
+- Hemos agregado decenas de configuraciones a la interfaz de usuario que solo existían una vez en el archivo JSON, incluida una página nueva para personalizar el diseño del menú Nueva pestaña.
+- Tenemos administración de ventanas rearchitecdas para mejorar la confiabilidad; envíe los errores que encuentre con el alias de wt.exe.
+- Ahora, los perfiles muestran un icono si se han ocultado o hacen referencia a programas que se han desinstalado.
-Consulte la página de versiones de GitHub para más información.
+Consulte nuestra página de versiones de GitHub para obtener más detalles.
diff --git a/build/StoreSubmission/Preview/PDPs/fr-FR/PDP.xml b/build/StoreSubmission/Preview/PDPs/fr-FR/PDP.xml
index d8a1b84250..526be4f3ba 100644
--- a/build/StoreSubmission/Preview/PDPs/fr-FR/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/fr-FR/PDP.xml
@@ -54,16 +54,13 @@ Il s’agit d’un projet open source et nous vous invitons à participer dans l
- Version __VERSION_NUMBER__
+ __VERSION_NUMBER__ de version
-- Nous avons réécrit la manière dont les applications de console sont hébergées dans Terminal ! Veuillez signaler tout bug que vous rencontrez.
-- Le terminal prend désormais en charge Sixels !
-- Vous pouvez désormais ouvrir un panneau ancré contenant des extraits de commandes que vous avez enregistrées pour les utiliser ultérieurement
-- Les utilisateurs de l'invite de commande sur la dernière version de Windows 11 peuvent voir une icône « astuce rapide » qui suggère un logiciel installable à partir de WinGet
-- Le texte sélectionné sera désormais beaucoup plus visible (et personnalisable !)
-- Un certain nombre de bugs de fiabilité, de problèmes de commodité et de désagréments ont été corrigés.
+- Nous avons ajouté des milliers de paramètres à l’interface utilisateur qui n’existaient auparavant que dans le fichier JSON, y compris une nouvelle page pour personnaliser la disposition de votre menu Nouvel onglet !
+- Nous avons réarchitialiser la gestion des fenêtres pour améliorer la fiabilité ; entrez les bogues rencontrés avec l’alias wt.exe
+- Les profils affichent désormais une icône s’ils ont été masqués ou s’ils font référence à des programmes qui ont été désinstallés.
-Veuillez consulter notre page de versions GitHub pour plus de détails.
+Pour plus d’informations, consultez notre page des mises en production GitHub.
diff --git a/build/StoreSubmission/Preview/PDPs/it-IT/PDP.xml b/build/StoreSubmission/Preview/PDPs/it-IT/PDP.xml
index aa18255f78..8c5ca0a25c 100644
--- a/build/StoreSubmission/Preview/PDPs/it-IT/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/it-IT/PDP.xml
@@ -54,16 +54,13 @@ Si tratta di un progetto open source e la partecipazione della community è molt
- Versione __VERSION_NUMBER__
+ Versione __VERSION_NUMBER__
-- È stato riscritto il modo in cui le applicazioni della console vengono ospitate all'interno di Terminale. Segnala eventuali bug riscontrati.
-- Terminal supporta ora Sixel.
-- È ora possibile aprire un pannello ancorato contenente frammenti di comandi salvati per usarli in seguito
-- Gli utenti del prompt dei comandi nella versione più recente di Windows 11 potrebbero visualizzare un'icona di "suggerimento rapido" che consiglia il software installabile da WinGet
-- Il testo selezionato sarà ora molto più visibile, oltre che personalizzabile.
-- Sono stati risolti diversi bug di affidabilità, problemi di praticità e fastidi.
+- Sono state aggiunte decine di impostazioni all'interfaccia utente che una volta esisteva solo nel file JSON, inclusa una nuova pagina per personalizzare il layout del menu Nuova scheda.
+- È stata riattivata la gestione delle finestre per migliorare l'affidabilità; inserire eventuali bug riscontrati con l'alias wt.exe
+- I profili ora mostrano un'icona se sono stati nascosti o fanno riferimento ai programmi che sono stati disinstallati.
-Per altri dettagli, vedi la pagina delle versioni di GitHub.
+Per altri dettagli, vedere la pagina delle versioni di GitHub.
diff --git a/build/StoreSubmission/Preview/PDPs/ja-JP/PDP.xml b/build/StoreSubmission/Preview/PDPs/ja-JP/PDP.xml
index bc1f0be0fb..0390ceb54b 100644
--- a/build/StoreSubmission/Preview/PDPs/ja-JP/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/ja-JP/PDP.xml
@@ -56,14 +56,11 @@
バージョン __VERSION_NUMBER__
-- ターミナル内でのコンソール アプリケーションのホスト方法を書き換えました。発生したバグを報告してください。
-- ターミナルで Sixels がサポートされるようになりました。
-- 後で使用するために保存したコマンドのスニペットを含むドッキング パネルを開けるようになりました
-- 最新の Windows 11 リリースのコマンド プロンプト ユーザーには、WinGet からインストール可能なソフトウェアを提案する "クイック ヒント" アイコンが表示される場合があります
-- 選択したテキストが大幅に見やすくなりました (カスタマイズも可能です)
-- 信頼性に関するバグ、利便性の問題、不快な問題の多くが修正されました。
+- [新しいタブ] メニューのレイアウトをカスタマイズするための新しいページを含む、一度だけ JSON ファイルに存在した UI に多数の設定を追加しました。
+- 信頼性を向上させるためにウィンドウ管理を再選択しました。wt.exe エイリアスで発生したバグを報告してください
+- プロファイルが非表示になっているか、アンインストールされたプログラムを参照している場合にアイコンが表示されるようになりました。
-詳細については、GitHub リリース ページをご覧ください。
+詳細については、GitHub リリース ページを参照してください。
diff --git a/build/StoreSubmission/Preview/PDPs/ko-KR/PDP.xml b/build/StoreSubmission/Preview/PDPs/ko-KR/PDP.xml
index 6a1a5614ca..5ca7f5102d 100644
--- a/build/StoreSubmission/Preview/PDPs/ko-KR/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/ko-KR/PDP.xml
@@ -56,12 +56,9 @@
버전 __VERSION_NUMBER__
-- 콘솔 애플리케이션이 터미널 내에서 호스팅되는 방법을 다시 작성했습니다! 발생한 버그를 보고하세요.
-- 터미널에서 이제 Sixels를 지원합니다!
-- 이제 나중에 사용하기 위해 저장한 명령 조각이 포함된 도킹된 패널을 열 수 있습니다.
-- 최신 Windows 11 릴리스의 명령 프롬프트 사용자는 WinGet에서 설치 가능한 소프트웨어를 제안하는 "빠른 팁" 아이콘을 볼 수 있습니다.
-- 이제 선택한 텍스트가 훨씬 더 잘 표시됩니다(사용자 지정도 가능!).
-- 여러 신뢰성 버그, 편의 문제 및 성가신 사항이 수정되었습니다.
+- 새 탭 메뉴의 레이아웃을 사용자 지정하기 위한 새 페이지를 포함하여 JSON 파일에 한 번만 존재했던 UI에 수천 개의 설정을 추가했습니다.
+- 안정성을 개선하기 위해 창 관리를 다시 보관했습니다. wt.exe 별칭에 발생한 버그를 제출하세요.
+- 프로필이 숨겨졌거나 제거된 프로그램을 참조하는 경우 이제 프로필에 아이콘이 표시됩니다.
자세한 내용은 GitHub 릴리스 페이지를 참조하세요.
diff --git a/build/StoreSubmission/Preview/PDPs/pt-BR/PDP.xml b/build/StoreSubmission/Preview/PDPs/pt-BR/PDP.xml
index 041743bba6..c6c84a6815 100644
--- a/build/StoreSubmission/Preview/PDPs/pt-BR/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/pt-BR/PDP.xml
@@ -56,14 +56,11 @@ Este é um projeto de código aberto e a participação da comunidade é bem-vin
Versão __VERSION_NUMBER__
-- Reescrevemos a forma como os aplicativos de console são hospedados no Terminal! Certifique-se de reportar os bugs que você encontrar.
-- O terminal agora é compatível com o Sixels!
-- Agora você pode abrir um painel acoplado contendo snippets de comandos que você salvou para usar mais tarde
-- Os usuários do Prompt de Comando na versão mais recente do Windows 11 podem ver um ícone de "dica rápida", que sugere softwares instaláveis a partir do WinGet
-- O texto selecionado agora ficará muito mais visível (e personalizável!)
-- Vários bugs de confiabilidade, problemas de conveniência e incômodos foram resolvidos.
+- Adicionamos várias configurações à interface do usuário que só existiam no arquivo JSON, incluindo uma nova página para personalizar o layout do menu Nova Guia!
+- Temos o gerenciamento de janelas rearmado para melhorar a confiabilidade; registre todos os bugs encontrados com o wt.exe alias
+- Os perfis agora mostram um ícone se eles foram ocultos ou se referem a programas que foram desinstalados.
-Confira nossa página de lançamentos no GitHub para obter mais detalhes.
+Consulte nossa página de versões do GitHub para obter detalhes adicionais.
diff --git a/build/StoreSubmission/Preview/PDPs/qps-ploc/PDP.xml b/build/StoreSubmission/Preview/PDPs/qps-ploc/PDP.xml
index 941d2485de..e21d600da0 100644
--- a/build/StoreSubmission/Preview/PDPs/qps-ploc/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/qps-ploc/PDP.xml
@@ -56,14 +56,11 @@
Vėѓѕіöй __VERSION_NUMBER__ !!! !!! !
-- Ẁē'νё ŕéẁѓĭτťёñ ћοώ ĉòπşõℓε άррℓіċªťįõпѕ αяе ĥθѕťэđ įŋšιďé Ţєямїńąℓ! Рļéаšė яёροřτ αņу ьϋģš ýõμ éпćŏџήţęя. !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!
-- Ţëямΐʼnαļ ńóẃ ŝüррöятš Śїхέłś! !!! !!! !!!
-- ¥оų ĉåи ńòŵ θρėñ д đбčĸэď ράńέļ ċőлŧăīņϊňģ śⁿіφφëťś оƒ ςōмmàⁿďş ŷŏũ ĥªν℮ şåνěđ τσ üśε łαťэŗ !!! !!! !!! !!! !!! !!! !!! !!! !!!
-- Ćοмmäлđ Рřōmφť üş℮ŗѕ öη τће ļāťëšτ Щīйđôώѕ 11 řёℓеаѕĕ måў ŝэε ά "qůïςκ ŧĭр" ιсôñ τĥдт šűğģєѕŧѕ ίńśŧăłłавļз šôƒţẁαгέ ƒґόm ЩĩйĞéţ !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
-- Śєļèċťєď ţĕжт ωϊŀļ йǿẃ ьέ mџ¢н мǿѓε νĭŝϊъļė (άŋđ сŭŝтŏмΐżдьļē!) !!! !!! !!! !!! !!! !!! !
-- Ä ņϋmъ℮ŗ ŏƒ ѓēŀїаъïļŧÿ ьüĝś, ςôⁿνėηĭ℮иć℮ îѕšůëş ăπð âлňбγдňçėŝ ћªνε ъēёп ƒΐ×еð. !!! !!! !!! !!! !!! !!! !!! !!!
+- Ẁē'νё àðđέď đöžзńş öƒ śėŧťїńģš тб тнè ÛĮ ťħąт ŏņ¢з όⁿℓγ έжіѕŧéð іή тђε ЈŠΩŃ ƒїℓė, ĭňĉŀџđіņģ å ňэẅ φâģé ƒøя ςŭśŧŏmïżϊñģ тħέ ĺαŷöυτ öƒ убµř Йέẁ Ţàъ мęήµ! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Ẁè ĥаνė řэąřčħΐŧέсτέð щįлďοш мǻňαĝēмêиť ťô ϊmрябνé ŗĕŀĩāвîĺïтγ; ρŀěăѕе ƒíŀё αⁿу вûġš ÿøú εʼnćōùлťēѓ ẃïτħ ŧћё wt.exe ǻļĭâś !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Рґøƒíŀêŝ ňöẁ šћθẁ ãй ĭčöñ ίƒ ŧħэŷ'νę ъеєл ђіðδэñ őř řєƒěґ ŧσ φяοġгаmŝ ẅђíçĥ ẁ℮гέ џňϊйşťàľĺèð. !!! !!! !!! !!! !!! !!! !!! !!! !!! !
-Ρĺёàŝ℮ ŝез ǿúг ĢīťНŭъ řěłεαśèŝ φāğ℮ ƒóѓ дďδітĭøиąℓ ð℮тªїľŝ. !!! !!! !!! !!! !!! !!!
+Рļèāŝє ŝèĕ θџŗ ĢίťĤцъ řέĺэªşэš ρąĝę ƒόř áďđїτϊōπαľ đэŧдįļŝ. !!! !!! !!! !!! !!! !!!
diff --git a/build/StoreSubmission/Preview/PDPs/qps-ploca/PDP.xml b/build/StoreSubmission/Preview/PDPs/qps-ploca/PDP.xml
index 941d2485de..e21d600da0 100644
--- a/build/StoreSubmission/Preview/PDPs/qps-ploca/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/qps-ploca/PDP.xml
@@ -56,14 +56,11 @@
Vėѓѕіöй __VERSION_NUMBER__ !!! !!! !
-- Ẁē'νё ŕéẁѓĭτťёñ ћοώ ĉòπşõℓε άррℓіċªťįõпѕ αяе ĥθѕťэđ įŋšιďé Ţєямїńąℓ! Рļéаšė яёροřτ αņу ьϋģš ýõμ éпćŏџήţęя. !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!
-- Ţëямΐʼnαļ ńóẃ ŝüррöятš Śїхέłś! !!! !!! !!!
-- ¥оų ĉåи ńòŵ θρėñ д đбčĸэď ράńέļ ċőлŧăīņϊňģ śⁿіφφëťś оƒ ςōмmàⁿďş ŷŏũ ĥªν℮ şåνěđ τσ üśε łαťэŗ !!! !!! !!! !!! !!! !!! !!! !!! !!!
-- Ćοмmäлđ Рřōmφť üş℮ŗѕ öη τће ļāťëšτ Щīйđôώѕ 11 řёℓеаѕĕ måў ŝэε ά "qůïςκ ŧĭр" ιсôñ τĥдт šűğģєѕŧѕ ίńśŧăłłавļз šôƒţẁαгέ ƒґόm ЩĩйĞéţ !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
-- Śєļèċťєď ţĕжт ωϊŀļ йǿẃ ьέ mџ¢н мǿѓε νĭŝϊъļė (άŋđ сŭŝтŏмΐżдьļē!) !!! !!! !!! !!! !!! !!! !
-- Ä ņϋmъ℮ŗ ŏƒ ѓēŀїаъïļŧÿ ьüĝś, ςôⁿνėηĭ℮иć℮ îѕšůëş ăπð âлňбγдňçėŝ ћªνε ъēёп ƒΐ×еð. !!! !!! !!! !!! !!! !!! !!! !!!
+- Ẁē'νё àðđέď đöžзńş öƒ śėŧťїńģš тб тнè ÛĮ ťħąт ŏņ¢з όⁿℓγ έжіѕŧéð іή тђε ЈŠΩŃ ƒїℓė, ĭňĉŀџđіņģ å ňэẅ φâģé ƒøя ςŭśŧŏmïżϊñģ тħέ ĺαŷöυτ öƒ убµř Йέẁ Ţàъ мęήµ! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Ẁè ĥаνė řэąřčħΐŧέсτέð щįлďοш мǻňαĝēмêиť ťô ϊmрябνé ŗĕŀĩāвîĺïтγ; ρŀěăѕе ƒíŀё αⁿу вûġš ÿøú εʼnćōùлťēѓ ẃïτħ ŧћё wt.exe ǻļĭâś !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Рґøƒíŀêŝ ňöẁ šћθẁ ãй ĭčöñ ίƒ ŧħэŷ'νę ъеєл ђіðδэñ őř řєƒěґ ŧσ φяοġгаmŝ ẅђíçĥ ẁ℮гέ џňϊйşťàľĺèð. !!! !!! !!! !!! !!! !!! !!! !!! !!! !
-Ρĺёàŝ℮ ŝез ǿúг ĢīťНŭъ řěłεαśèŝ φāğ℮ ƒóѓ дďδітĭøиąℓ ð℮тªїľŝ. !!! !!! !!! !!! !!! !!!
+Рļèāŝє ŝèĕ θџŗ ĢίťĤцъ řέĺэªşэš ρąĝę ƒόř áďđїτϊōπαľ đэŧдįļŝ. !!! !!! !!! !!! !!! !!!
diff --git a/build/StoreSubmission/Preview/PDPs/qps-plocm/PDP.xml b/build/StoreSubmission/Preview/PDPs/qps-plocm/PDP.xml
index 941d2485de..e21d600da0 100644
--- a/build/StoreSubmission/Preview/PDPs/qps-plocm/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/qps-plocm/PDP.xml
@@ -56,14 +56,11 @@
Vėѓѕіöй __VERSION_NUMBER__ !!! !!! !
-- Ẁē'νё ŕéẁѓĭτťёñ ћοώ ĉòπşõℓε άррℓіċªťįõпѕ αяе ĥθѕťэđ įŋšιďé Ţєямїńąℓ! Рļéаšė яёροřτ αņу ьϋģš ýõμ éпćŏџήţęя. !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!
-- Ţëямΐʼnαļ ńóẃ ŝüррöятš Śїхέłś! !!! !!! !!!
-- ¥оų ĉåи ńòŵ θρėñ д đбčĸэď ράńέļ ċőлŧăīņϊňģ śⁿіφφëťś оƒ ςōмmàⁿďş ŷŏũ ĥªν℮ şåνěđ τσ üśε łαťэŗ !!! !!! !!! !!! !!! !!! !!! !!! !!!
-- Ćοмmäлđ Рřōmφť üş℮ŗѕ öη τће ļāťëšτ Щīйđôώѕ 11 řёℓеаѕĕ måў ŝэε ά "qůïςκ ŧĭр" ιсôñ τĥдт šűğģєѕŧѕ ίńśŧăłłавļз šôƒţẁαгέ ƒґόm ЩĩйĞéţ !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
-- Śєļèċťєď ţĕжт ωϊŀļ йǿẃ ьέ mџ¢н мǿѓε νĭŝϊъļė (άŋđ сŭŝтŏмΐżдьļē!) !!! !!! !!! !!! !!! !!! !
-- Ä ņϋmъ℮ŗ ŏƒ ѓēŀїаъïļŧÿ ьüĝś, ςôⁿνėηĭ℮иć℮ îѕšůëş ăπð âлňбγдňçėŝ ћªνε ъēёп ƒΐ×еð. !!! !!! !!! !!! !!! !!! !!! !!!
+- Ẁē'νё àðđέď đöžзńş öƒ śėŧťїńģš тб тнè ÛĮ ťħąт ŏņ¢з όⁿℓγ έжіѕŧéð іή тђε ЈŠΩŃ ƒїℓė, ĭňĉŀџđіņģ å ňэẅ φâģé ƒøя ςŭśŧŏmïżϊñģ тħέ ĺαŷöυτ öƒ убµř Йέẁ Ţàъ мęήµ! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Ẁè ĥаνė řэąřčħΐŧέсτέð щįлďοш мǻňαĝēмêиť ťô ϊmрябνé ŗĕŀĩāвîĺïтγ; ρŀěăѕе ƒíŀё αⁿу вûġš ÿøú εʼnćōùлťēѓ ẃïτħ ŧћё wt.exe ǻļĭâś !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Рґøƒíŀêŝ ňöẁ šћθẁ ãй ĭčöñ ίƒ ŧħэŷ'νę ъеєл ђіðδэñ őř řєƒěґ ŧσ φяοġгаmŝ ẅђíçĥ ẁ℮гέ џňϊйşťàľĺèð. !!! !!! !!! !!! !!! !!! !!! !!! !!! !
-Ρĺёàŝ℮ ŝез ǿúг ĢīťНŭъ řěłεαśèŝ φāğ℮ ƒóѓ дďδітĭøиąℓ ð℮тªїľŝ. !!! !!! !!! !!! !!! !!!
+Рļèāŝє ŝèĕ θџŗ ĢίťĤцъ řέĺэªşэš ρąĝę ƒόř áďđїτϊōπαľ đэŧдįļŝ. !!! !!! !!! !!! !!! !!!
diff --git a/build/StoreSubmission/Preview/PDPs/ru-RU/PDP.xml b/build/StoreSubmission/Preview/PDPs/ru-RU/PDP.xml
index 7561a5dd7e..c5c90ff6da 100644
--- a/build/StoreSubmission/Preview/PDPs/ru-RU/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/ru-RU/PDP.xml
@@ -56,12 +56,9 @@
Версия __VERSION_NUMBER__
-– Мы переписали, как консольные приложения размещаются внутри Терминала! Сообщайте о любых ошибках, с которыми вы столкнулись.
-– Терминал теперь поддерживает форматы Sixel!
-– Теперь вы можете открыть закрепленную панель, содержащую фрагменты команд, которые вы сохранили для использования в дальнейшем
-– Пользователи командной строки в новейшем выпуске Windows 11 могут увидеть значок "краткой подсказки", который предлагает устанавливаемые программы из WinGet
-– Выделенный текст теперь станет более видимым (и настраиваемым!)
-– Исправлено несколько ошибок надежности, проблем с удобством, а также устранены раздражающие моменты.
+- Мы добавили в пользовательский интерфейс десятки параметров, которые существовали только в JSON-файле, включая новую страницу для настройки макета меню "Новая вкладка".
+- Для повышения надежности мы переупоряхлили управление окнами; создайте все ошибки, обнаруженные с wt.exe псевдонимом
+- Профили теперь показывают значок, если они скрыты или ссылаются на программы, которые были удалены.
Дополнительные сведения см. на странице выпусков GitHub.
diff --git a/build/StoreSubmission/Preview/PDPs/zh-CN/PDP.xml b/build/StoreSubmission/Preview/PDPs/zh-CN/PDP.xml
index 44ef68818c..cd0783394c 100644
--- a/build/StoreSubmission/Preview/PDPs/zh-CN/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/zh-CN/PDP.xml
@@ -54,16 +54,13 @@
- Version __VERSION_NUMBER__
+ 版本 __VERSION_NUMBER__
-- 我们已改变主机应用程序在终端内的托管方式!请报告遇到的任何 bug。
-- 终端现在支持 Sixels!
-- 现在可以打开一个停靠面板,其中包含已保存供以后使用的命令片段
-- 最新 Windows 11 版本上的命令提示用户可能会看到“快速提示”图标,该图标建议从 WinGet 安装软件
-- 所选文本现在将具有更高的可见性(和可自定义性!)
-- 修复了许多可靠性 bug、便利性问题和令人烦恼的问题。
+- 我们向用户界面添加了许多设置,这些设置仅存在于 JSON 文件中,包括用于自定义“新建标签页”菜单布局的新页面!
+- 我们已重新检测窗口管理以提高可靠性;请将遇到的任何 bug 归档为 wt.exe 别名
+- 如果配置文件已隐藏或引用已卸载的程序,则它们现在将显示一个图标。
-有关其他详细信息,请参阅我们的 GitHub 发布页面。
+有关其他详细信息,请参阅 GitHub 发布页面。
diff --git a/build/StoreSubmission/Preview/PDPs/zh-TW/PDP.xml b/build/StoreSubmission/Preview/PDPs/zh-TW/PDP.xml
index e902f1a5e0..eeec299d96 100644
--- a/build/StoreSubmission/Preview/PDPs/zh-TW/PDP.xml
+++ b/build/StoreSubmission/Preview/PDPs/zh-TW/PDP.xml
@@ -56,14 +56,11 @@
版本 __VERSION_NUMBER__
-- 我們已重寫主機應用程式在終端機內託管的方式!請報告您遇到的錯誤。
-- 終端機現在支援 Sixels!
-- 現在,您可以開啟包含已儲存命令程式碼片段的固定面板,以供稍後使用
-- 最新 Windows 11 版本中的 [命令提示] 使用者可能會看到「快速提示」圖示,建議可自 WinGet 安裝的軟體
-- 選取的文字現在會更明顯 (且可自訂!)
-- 已修正一些可靠性錯誤、便利性問題和令人困擾的問題。
+- 我們已新增數十個只存在於 JSON 檔案中的設定到 UI,包括自定義 [新索引標籤] 功能表版面配置的新頁面!
+- 我們已重新設定視窗管理,以改善可靠性;請提出您在 wt.exe 別名遇到的任何錯誤
+- 設定文件現在會在隱藏或參照已卸載的程式時顯示圖示。
-如需更多詳細資訊,請參閱我們的 GitHub 發行頁面。
+如需詳細數據,請參閱我們的 GitHub 版本頁面。
diff --git a/build/StoreSubmission/Stable/PDPs/de-DE/PDP.xml b/build/StoreSubmission/Stable/PDPs/de-DE/PDP.xml
index 9b03ca9d01..47ff614bd0 100644
--- a/build/StoreSubmission/Stable/PDPs/de-DE/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/de-DE/PDP.xml
@@ -56,12 +56,12 @@ Dies ist ein Open Source-Projekt, und wir freuen uns über die Teilnahme an der
Version __VERSION_NUMBER__
-– Terminal speichert jetzt den Inhalt des Fensters, wenn Sie die Sitzungswiederherstellung verwenden.
-– Sie können jetzt mehrere Schriftarten gleichzeitig verwenden.
-– Kästchenzeichnende Zeichen werden jetzt pixelgenau gerendert.
-– Die Verwendung eines IME innerhalb des Terminals wurde erheblich verbessert.
-– Die Farbschemas in Ihrer JSON-Datei sind jetzt viel einfacher.
-– Eine Reihe von Fehlern im Zusammenhang mit der URL-Verarbeitung, Zeilen mit doppelter Breite, Zeilenumbruch und mehr wurden behoben.
+– Wir haben umgeschrieben, wie Konsolenanwendungen im Terminal gehostet werden! Melden Sie alle auftretenden Fehler.
+– Terminal unterstützt jetzt Sixels!
+– Sie können jetzt einen angedockten Bereich öffnen, der Ausschnitte von Befehlen enthält, die Sie gespeichert haben, um sie später zu verwenden.
+– Für Benutzer der Eingabeaufforderung der neuesten Version von Windows 11 wird möglicherweise ein QuickInfo-Symbol angezeigt, das installierbare Software von WinGet vorschlägt.
+– Ausgewählter Text wird jetzt viel sichtbarer (und anpassbarer!).
+- Eine Reihe von Zuverlässigkeitsfehlern, Benutzerfreundlichkeitsproblemen und Ärgernissen wurden behoben.
Weitere Informationen finden Sie auf unserer GitHub-Releaseseite.
diff --git a/build/StoreSubmission/Stable/PDPs/en-US/PDP.xml b/build/StoreSubmission/Stable/PDPs/en-US/PDP.xml
index cab23331c5..993c27e011 100644
--- a/build/StoreSubmission/Stable/PDPs/en-US/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/en-US/PDP.xml
@@ -56,12 +56,12 @@ This is an open source project and we welcome community participation. To partic
Version __VERSION_NUMBER__
-- Terminal will now remember the contents of the window when you use session restoration.
-- You can now use multiple fonts at the same time.
-- Box-drawing characters are now rendered with pixel perfection.
-- The experience of using an IME inside Terminal has been significantly improved.
-- The color schemes inside your JSON file will now be much simpler.
-- A number of bugs around URL handling, double-width rows, line wrapping, and more have been fixed.
+- We've rewritten how console applications are hosted inside Terminal! Please report any bugs you encounter.
+- Terminal now supports Sixels!
+- You can now open a docked panel containing snippets of commands you have saved to use later
+- Command Prompt users on the latest Windows 11 release may see a "quick tip" icon that suggests installable software from WinGet
+- Selected text will now be much more visible (and customizable!)
+- A number of reliabilty bugs, convenience issues and annoyances have been fixed.
Please see our GitHub releases page for additional details.
diff --git a/build/StoreSubmission/Stable/PDPs/es-ES/PDP.xml b/build/StoreSubmission/Stable/PDPs/es-ES/PDP.xml
index 1d2c1d5330..84bd2cc399 100644
--- a/build/StoreSubmission/Stable/PDPs/es-ES/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/es-ES/PDP.xml
@@ -56,12 +56,12 @@ Este es un proyecto de fuente abierta y animamos a la comunidad a participar. Pa
Versión __VERSION_NUMBER__
-- Terminal recordará ahora el contenido de la ventana cuando use la restauración de la sesión.
-- Ahora puede usar varias fuentes al mismo tiempo.
-- Los caracteres que dibujan recuadros ahora se representan con precisión de píxel.
-- Se ha mejorado significativamente la experiencia de utilizar un IME dentro de Terminal.
-- Las combinaciones de colores dentro del archivo JSON ahora serán mucho más sencillas.
-- Se han corregido varios errores relacionados con el control de direcciones URL, las filas de ancho doble, el ajuste de líneas y mucho más.
+- Hemos reescrito cómo se hospedan las aplicaciones de consola en Terminal. Informe de los errores que encuentre.
+- Terminal ahora admite síxeles.
+- Ahora puede abrir un panel acoplado que contenga fragmentos de comandos que haya guardado para usarlos más adelante
+- Los usuarios del símbolo del sistema de la versión más reciente de Windows 11 pueden ver un icono de "sugerencia rápida" que sugiere software instalable de WinGet
+- El texto seleccionado ahora será mucho más visible (y personalizable)
+- Se han corregido varios errores de fiabilidad, problemas de comodidad y molestias.
Consulte la página de versiones de GitHub para más información.
diff --git a/build/StoreSubmission/Stable/PDPs/fr-FR/PDP.xml b/build/StoreSubmission/Stable/PDPs/fr-FR/PDP.xml
index 73122c2dba..34c6a13ea8 100644
--- a/build/StoreSubmission/Stable/PDPs/fr-FR/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/fr-FR/PDP.xml
@@ -56,14 +56,14 @@ Il s’agit d’un projet open source et nous encourageons la participation à l
Version __VERSION_NUMBER__
-- Le terminal mémorisera désormais le contenu de la fenêtre lorsque vous utiliserez la restauration de session.
-- Vous pouvez désormais utiliser plusieurs polices en même temps.
-- Les personnages dessinés en boîte sont désormais rendus avec une perfection de pixel.
-- L'expérience d'utilisation d'un IME dans le Terminal a été considérablement améliorée.
-- Les schémas de couleurs à l'intérieur de votre fichier JSON seront désormais beaucoup plus simples.
-- Un certain nombre de bugs concernant la gestion des URL, les lignes à double largeur, le retour à la ligne, etc. ont été corrigés.
+– Nous avons réécrit la manière dont les applications de console sont hébergées dans Terminal ! Veuillez signaler tout bogue que vous rencontrez.
+– Terminal prend désormais en charge Sixels !
+– Vous pouvez maintenant ouvrir un panneau ancré contenant des extraits de commandes que vous avez enregistrées pour les utiliser ultérieurement
+– Les utilisateurs de l’invite de commande sur la dernière version de Windows 11 peuvent voir une icône « astuce rapide » qui suggère un logiciel installable à partir de WinGet
+– Le texte sélectionné sera désormais beaucoup plus visible (et personnalisable !)
+– Un certain nombre de bogues de fiabilité, de problèmes de commodité et de désagréments ont été corrigés.
-Veuillez consulter notre page de versions GitHub pour plus de détails.
+Veuillez consulter notre page des versions GitHub pour découvrir d’autres détails.
diff --git a/build/StoreSubmission/Stable/PDPs/it-IT/PDP.xml b/build/StoreSubmission/Stable/PDPs/it-IT/PDP.xml
index 1588f40494..9d7ce218e8 100644
--- a/build/StoreSubmission/Stable/PDPs/it-IT/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/it-IT/PDP.xml
@@ -54,16 +54,16 @@ Si tratta di un progetto open source e la partecipazione della community è molt
- Versione __VERSION_NUMBER__
+ Versione __VERSION_NUMBER__
-- Il terminale ricorda ora il contenuto della finestra quando si usa il ripristino della sessione.
-- È ora possibile usare più tipi di carattere contemporaneamente.
-- I caratteri tracciati vengono ora sottoposti a rendering con pixel di perfezionamento.
-- L'esperienza di utilizzo di un IME all'interno di Terminale è stata notevolmente migliorata.
-- Le combinazioni di colori all'interno del file JSON saranno ora molto più semplici.
-- Sono stati corretti alcuni bug relativi alla gestione degli URL, alle righe a doppia larghezza, al ritorno a capo delle righe e altro ancora.
+- Abbiamo cambiato il modo in cui le applicazioni della console vengono ospitate all’interno di Terminale. Segnala eventuali bug riscontrati.
+- Ora Terminale supporta i Sixel.
+- Puoi aprire un pannello ancorato contenente frammenti di comandi salvati per usarli in seguito
+- Gli utenti che usano il prompt dei comandi nella versione più recente di Windows 11 potrebbero visualizzare un’icona di “suggerimento rapido” che consiglia il software installabile da WinGet
+- Il testo selezionato sarà ora molto più visibile, oltre che personalizzabile.
+- Sono stati risolti diversi bug di affidabilità e problemi di ordine pratico.
-Per altri dettagli, vedi la pagina delle versioni di GitHub.
+Per altri dettagli, vedi la pagina delle release di GitHub.
diff --git a/build/StoreSubmission/Stable/PDPs/ja-JP/PDP.xml b/build/StoreSubmission/Stable/PDPs/ja-JP/PDP.xml
index 8a56c14bbe..27a38762bb 100644
--- a/build/StoreSubmission/Stable/PDPs/ja-JP/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/ja-JP/PDP.xml
@@ -56,12 +56,12 @@
バージョン __VERSION_NUMBER__
-- セッションの復元を使用すると、ターミナルがウィンドウの内容を記憶するようになりました。
-- 複数のフォントを同時に使用できるようになりました。
-- ボックス描画文字がピクセル単位の精度でレンダリングされるようになりました。
-- ターミナル内での IME の使用エクスペリエンスが大幅に改善されました。
-- JSON ファイル内の配色がはるかにシンプルになりました。
-- URL 処理、二重幅の行、行の折り返しなどに関するいくつかのバグが修正されました。
+- ターミナル内でのコンソール アプリケーションのホスト方法を書き換えました。発生したバグを報告してください。
+- ターミナルで Sixels がサポートされるようになりました。
+- 後で使用するために保存したコマンドのスニペットを含むドッキング パネルを開けるようになりました
+- 最新の Windows 11 リリースのコマンド プロンプト ユーザーには、WinGet からインストール可能なソフトウェアを提案する "クイック ヒント" アイコンが表示される場合があります
+- 選択したテキストが大幅に見やすくなりました (カスタマイズも可能です)
+- 信頼性に関するバグ、利便性の問題、不快な問題の多くが修正されました。
詳細については、GitHub リリース ページをご覧ください。
diff --git a/build/StoreSubmission/Stable/PDPs/ko-KR/PDP.xml b/build/StoreSubmission/Stable/PDPs/ko-KR/PDP.xml
index 29be907d86..8dac845667 100644
--- a/build/StoreSubmission/Stable/PDPs/ko-KR/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/ko-KR/PDP.xml
@@ -56,12 +56,12 @@
버전 __VERSION_NUMBER__
-- 터미널은 이제 세션 복원을 사용할 때 창의 내용을 기억합니다.
-- 이제 여러 글꼴을 동시에 사용할 수 있습니다.
-- 상자 그리기 캐릭터가 이제 픽셀 완성도로 렌더링됩니다.
-- 터미널 내에서 IME를 사용하는 환경이 크게 개선되었습니다.
-- 이제 JSON 파일 내의 색 구성표가 훨씬 더 간단해집니다.
-- URL 처리, 이중 너비 행, 줄 바꿈 등과 관련된 여러 버그가 수정되었습니다.
+- 콘솔 애플리케이션이 터미널 내에서 호스팅되는 방법을 다시 작성했습니다. 버그가 발생하면 보고해 주세요.
+- 터미널에서 이제 Sixels를 지원합니다.
+- 이제 나중에 사용하기 위해 저장한 명령 조각이 포함된 도킹된 패널을 열 수 있습니다.
+- 최신 Windows 11 릴리스의 명령 프롬프트 사용자는 WinGet에서 설치 가능한 소프트웨어를 추천하는 "간단한 팁" 아이콘을 볼 수 있습니다.
+- 이제 선택한 텍스트가 훨씬 더 잘 보입니다(사용자 지정 가능).
+- 여러 안정성 버그, 편의성 문제, 불편 사항이 수정되었습니다.
자세한 내용은 GitHub 릴리스 페이지를 참조하세요.
diff --git a/build/StoreSubmission/Stable/PDPs/pt-BR/PDP.xml b/build/StoreSubmission/Stable/PDPs/pt-BR/PDP.xml
index 1ddfe8815c..cd3b5ce368 100644
--- a/build/StoreSubmission/Stable/PDPs/pt-BR/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/pt-BR/PDP.xml
@@ -56,12 +56,12 @@ Este é um projeto de código aberto e a participação da comunidade é bem-vin
Versão __VERSION_NUMBER__
-- O terminal agora se lembra do conteúdo da janela quando você usa a restauração de sessão.
-- Agora você pode usar várias fontes ao mesmo tempo.
-- Os caracteres da caixa de desenho agora são renderizados com a perfeição de pixels.
-- A experiência de usar uma IME dentro do Terminal foi significativamente aprimorada.
-- Os esquemas de cores dentro do seu arquivo JSON agora estão muito mais simples.
-- Foram corrigidos vários bugs envolvendo o tratamento de URLs, linhas de largura dupla, quebra de linha automática e muito mais.
+– Reescrevemos a forma como os aplicativos de console são hospedados no Terminal! Relate os bugs encontrados.
+– O terminal agora oferece suporte ao Sixels!
+– Agora você pode abrir um painel acoplado contendo snippets de comandos que você salvou para usar mais tarde
+– Os usuários do Prompt de Comando na versão mais recente do Windows 11 podem ver um ícone de "dica rápida", que sugere softwares instaláveis a partir do WinGet
+– O texto selecionado agora ficará muito mais visível (e personalizável!)
+– Vários bugs de confiabilidade, problemas de conveniência e incômodos foram resolvidos.
Confira nossa página de lançamentos no GitHub para obter mais detalhes.
diff --git a/build/StoreSubmission/Stable/PDPs/qps-ploc/PDP.xml b/build/StoreSubmission/Stable/PDPs/qps-ploc/PDP.xml
index 5f716b97c4..d911bbd69b 100644
--- a/build/StoreSubmission/Stable/PDPs/qps-ploc/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/qps-ploc/PDP.xml
@@ -56,14 +56,14 @@
Vėѓѕіöй __VERSION_NUMBER__ !!! !!! !
-- Ŧēгмíйǻŀ шιļł ñσщ řėmėmвзґ τђз ςоńţëηťŝ σƒ ŧћé ẅιⁿδőщ ẅђеή ýóύ ŭš℮ şεššîóŋ řėşτŏѓдτіόŋ. !!! !!! !!! !!! !!! !!! !!! !!! !!!
-- Ύоџ ςàⁿ ŋóώ ũşэ múľŧìφľё ƒоʼnťş àт ťħе ѕâmз тìме. !!! !!! !!! !!! !!!
-- Вό×-ðгăшĭиġ ¢ĥаяäςтеřѕ äřę ηоẁ ѓëńđêяεď ẁϊτђ φïжêĺ φėŗƒēςŧΐøй. !!! !!! !!! !!! !!! !!! !
-- Ťħέ ĕхφêŕï℮ηĉε ŏƒ ύѕïйġ ǻʼn ÎМË îńšïďê Τєřmíлäļ нαŝ ьēέň ѕιĝήîƒіčäπţŀý ĩмφґθνзđ. !!! !!! !!! !!! !!! !!! !!! !!!
-- Ťĥę čöℓοг şçђėmęš ιʼnśΐδê убџѓ ĴŠОИ ƒϊŀε ωĭŀł ʼnθω вз мúçĥ ѕїмρℓёґ. !!! !!! !!! !!! !!! !!! !!
-- Á ήũmьéŕ òƒ вµġŝ άřòūñδ ÛҐĿ ħàŋδľįйģ, ðőџъŀε-ŵĭďτђ ŗōẁš, ŀϊπė ẃяąрρΐηğ, âⁿđ мŏř℮ ĥāνě везŋ ƒï×έð. !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Ẁē'νё ŕéẁѓĭτťёñ ћοώ ĉòπşõℓε άррℓіċªťįõпѕ αяе ĥθѕťэđ įŋšιďé Ţєямїńąℓ! Рļéаšė яёροřτ αņу ьϋģš ýõμ éпćŏџήţęя. !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!
+- Ţëямΐʼnαļ ńóẃ ŝüррöятš Śїхέłś! !!! !!! !!!
+- ¥оų ĉåи ńòŵ θρėñ д đбčĸэď ράńέļ ċőлŧăīņϊňģ śⁿіφφëťś оƒ ςōмmàⁿďş ŷŏũ ĥªν℮ şåνěđ τσ üśε łαťэŗ !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Ćοмmäлđ Рřōmφť üş℮ŗѕ öη τће ļāťëšτ Щīйđôώѕ 11 řёℓеаѕĕ måў ŝэε ά "qůïςκ ŧĭр" ιсôñ τĥдт šűğģєѕŧѕ ίńśŧăłłавļз šôƒţẁαгέ ƒґόm ЩĩйĞéţ !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Śєļèċťєď ţĕжт ωϊŀļ йǿẃ ьέ mџ¢н мǿѓε νĭŝϊъļė (άŋđ сŭŝтŏмΐżдьļē!) !!! !!! !!! !!! !!! !!! !
+- Ä ņϋmъ℮ŗ ŏƒ ѓēŀїаъïļŧÿ ьüĝś, ςôⁿνėηĭ℮иć℮ îѕšůëş ăπð âлňбγдňçėŝ ћªνε ъēёп ƒΐ×еð. !!! !!! !!! !!! !!! !!! !!! !!!
-Ρļēªšê ŝέė őůг ĜīтĤųъ яëŀεäśēś рдġэ ƒõя ãδðìτϊöňãł δèτâĩĺѕ. !!! !!! !!! !!! !!! !!!
+Ρĺёàŝ℮ ŝез ǿúг ĢīťНŭъ řěłεαśèŝ φāğ℮ ƒóѓ дďδітĭøиąℓ ð℮тªїľŝ. !!! !!! !!! !!! !!! !!!
diff --git a/build/StoreSubmission/Stable/PDPs/qps-ploca/PDP.xml b/build/StoreSubmission/Stable/PDPs/qps-ploca/PDP.xml
index 5f716b97c4..d911bbd69b 100644
--- a/build/StoreSubmission/Stable/PDPs/qps-ploca/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/qps-ploca/PDP.xml
@@ -56,14 +56,14 @@
Vėѓѕіöй __VERSION_NUMBER__ !!! !!! !
-- Ŧēгмíйǻŀ шιļł ñσщ řėmėmвзґ τђз ςоńţëηťŝ σƒ ŧћé ẅιⁿδőщ ẅђеή ýóύ ŭš℮ şεššîóŋ řėşτŏѓдτіόŋ. !!! !!! !!! !!! !!! !!! !!! !!! !!!
-- Ύоџ ςàⁿ ŋóώ ũşэ múľŧìφľё ƒоʼnťş àт ťħе ѕâmз тìме. !!! !!! !!! !!! !!!
-- Вό×-ðгăшĭиġ ¢ĥаяäςтеřѕ äřę ηоẁ ѓëńđêяεď ẁϊτђ φïжêĺ φėŗƒēςŧΐøй. !!! !!! !!! !!! !!! !!! !
-- Ťħέ ĕхφêŕï℮ηĉε ŏƒ ύѕïйġ ǻʼn ÎМË îńšïďê Τєřmíлäļ нαŝ ьēέň ѕιĝήîƒіčäπţŀý ĩмφґθνзđ. !!! !!! !!! !!! !!! !!! !!! !!!
-- Ťĥę čöℓοг şçђėmęš ιʼnśΐδê убџѓ ĴŠОИ ƒϊŀε ωĭŀł ʼnθω вз мúçĥ ѕїмρℓёґ. !!! !!! !!! !!! !!! !!! !!
-- Á ήũmьéŕ òƒ вµġŝ άřòūñδ ÛҐĿ ħàŋδľįйģ, ðőџъŀε-ŵĭďτђ ŗōẁš, ŀϊπė ẃяąрρΐηğ, âⁿđ мŏř℮ ĥāνě везŋ ƒï×έð. !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Ẁē'νё ŕéẁѓĭτťёñ ћοώ ĉòπşõℓε άррℓіċªťįõпѕ αяе ĥθѕťэđ įŋšιďé Ţєямїńąℓ! Рļéаšė яёροřτ αņу ьϋģš ýõμ éпćŏџήţęя. !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!
+- Ţëямΐʼnαļ ńóẃ ŝüррöятš Śїхέłś! !!! !!! !!!
+- ¥оų ĉåи ńòŵ θρėñ д đбčĸэď ράńέļ ċőлŧăīņϊňģ śⁿіφφëťś оƒ ςōмmàⁿďş ŷŏũ ĥªν℮ şåνěđ τσ üśε łαťэŗ !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Ćοмmäлđ Рřōmφť üş℮ŗѕ öη τће ļāťëšτ Щīйđôώѕ 11 řёℓеаѕĕ måў ŝэε ά "qůïςκ ŧĭр" ιсôñ τĥдт šűğģєѕŧѕ ίńśŧăłłавļз šôƒţẁαгέ ƒґόm ЩĩйĞéţ !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Śєļèċťєď ţĕжт ωϊŀļ йǿẃ ьέ mџ¢н мǿѓε νĭŝϊъļė (άŋđ сŭŝтŏмΐżдьļē!) !!! !!! !!! !!! !!! !!! !
+- Ä ņϋmъ℮ŗ ŏƒ ѓēŀїаъïļŧÿ ьüĝś, ςôⁿνėηĭ℮иć℮ îѕšůëş ăπð âлňбγдňçėŝ ћªνε ъēёп ƒΐ×еð. !!! !!! !!! !!! !!! !!! !!! !!!
-Ρļēªšê ŝέė őůг ĜīтĤųъ яëŀεäśēś рдġэ ƒõя ãδðìτϊöňãł δèτâĩĺѕ. !!! !!! !!! !!! !!! !!!
+Ρĺёàŝ℮ ŝез ǿúг ĢīťНŭъ řěłεαśèŝ φāğ℮ ƒóѓ дďδітĭøиąℓ ð℮тªїľŝ. !!! !!! !!! !!! !!! !!!
diff --git a/build/StoreSubmission/Stable/PDPs/qps-plocm/PDP.xml b/build/StoreSubmission/Stable/PDPs/qps-plocm/PDP.xml
index 5f716b97c4..d911bbd69b 100644
--- a/build/StoreSubmission/Stable/PDPs/qps-plocm/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/qps-plocm/PDP.xml
@@ -56,14 +56,14 @@
Vėѓѕіöй __VERSION_NUMBER__ !!! !!! !
-- Ŧēгмíйǻŀ шιļł ñσщ řėmėmвзґ τђз ςоńţëηťŝ σƒ ŧћé ẅιⁿδőщ ẅђеή ýóύ ŭš℮ şεššîóŋ řėşτŏѓдτіόŋ. !!! !!! !!! !!! !!! !!! !!! !!! !!!
-- Ύоџ ςàⁿ ŋóώ ũşэ múľŧìφľё ƒоʼnťş àт ťħе ѕâmз тìме. !!! !!! !!! !!! !!!
-- Вό×-ðгăшĭиġ ¢ĥаяäςтеřѕ äřę ηоẁ ѓëńđêяεď ẁϊτђ φïжêĺ φėŗƒēςŧΐøй. !!! !!! !!! !!! !!! !!! !
-- Ťħέ ĕхφêŕï℮ηĉε ŏƒ ύѕïйġ ǻʼn ÎМË îńšïďê Τєřmíлäļ нαŝ ьēέň ѕιĝήîƒіčäπţŀý ĩмφґθνзđ. !!! !!! !!! !!! !!! !!! !!! !!!
-- Ťĥę čöℓοг şçђėmęš ιʼnśΐδê убџѓ ĴŠОИ ƒϊŀε ωĭŀł ʼnθω вз мúçĥ ѕїмρℓёґ. !!! !!! !!! !!! !!! !!! !!
-- Á ήũmьéŕ òƒ вµġŝ άřòūñδ ÛҐĿ ħàŋδľįйģ, ðőџъŀε-ŵĭďτђ ŗōẁš, ŀϊπė ẃяąрρΐηğ, âⁿđ мŏř℮ ĥāνě везŋ ƒï×έð. !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Ẁē'νё ŕéẁѓĭτťёñ ћοώ ĉòπşõℓε άррℓіċªťįõпѕ αяе ĥθѕťэđ įŋšιďé Ţєямїńąℓ! Рļéаšė яёροřτ αņу ьϋģš ýõμ éпćŏџήţęя. !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!
+- Ţëямΐʼnαļ ńóẃ ŝüррöятš Śїхέłś! !!! !!! !!!
+- ¥оų ĉåи ńòŵ θρėñ д đбčĸэď ράńέļ ċőлŧăīņϊňģ śⁿіφφëťś оƒ ςōмmàⁿďş ŷŏũ ĥªν℮ şåνěđ τσ üśε łαťэŗ !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Ćοмmäлđ Рřōmφť üş℮ŗѕ öη τће ļāťëšτ Щīйđôώѕ 11 řёℓеаѕĕ måў ŝэε ά "qůïςκ ŧĭр" ιсôñ τĥдт šűğģєѕŧѕ ίńśŧăłłавļз šôƒţẁαгέ ƒґόm ЩĩйĞéţ !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!! !!!
+- Śєļèċťєď ţĕжт ωϊŀļ йǿẃ ьέ mџ¢н мǿѓε νĭŝϊъļė (άŋđ сŭŝтŏмΐżдьļē!) !!! !!! !!! !!! !!! !!! !
+- Ä ņϋmъ℮ŗ ŏƒ ѓēŀїаъïļŧÿ ьüĝś, ςôⁿνėηĭ℮иć℮ îѕšůëş ăπð âлňбγдňçėŝ ћªνε ъēёп ƒΐ×еð. !!! !!! !!! !!! !!! !!! !!! !!!
-Ρļēªšê ŝέė őůг ĜīтĤųъ яëŀεäśēś рдġэ ƒõя ãδðìτϊöňãł δèτâĩĺѕ. !!! !!! !!! !!! !!! !!!
+Ρĺёàŝ℮ ŝез ǿúг ĢīťНŭъ řěłεαśèŝ φāğ℮ ƒóѓ дďδітĭøиąℓ ð℮тªїľŝ. !!! !!! !!! !!! !!! !!!
diff --git a/build/StoreSubmission/Stable/PDPs/ru-RU/PDP.xml b/build/StoreSubmission/Stable/PDPs/ru-RU/PDP.xml
index 16779a4422..011e5152d7 100644
--- a/build/StoreSubmission/Stable/PDPs/ru-RU/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/ru-RU/PDP.xml
@@ -56,12 +56,12 @@
Версия __VERSION_NUMBER__
-– Терминал теперь будет запоминать содержимое окна при восстановлении сеанса.
-– Теперь вы можете использовать несколько шрифтов одновременно.
-– Символы псевдографики теперь отрисовываются с пиксельной точностью.
-– Значительно улучшена возможность использования IME внутри Терминала.
-– Цветовые схемы в JSON-файле теперь будут намного проще.
-– Исправлено несколько ошибок в обработке URL-адресов, строках двойной ширины, переносе строк и т. д.
+– Мы переписали, как консольные приложения размещаются внутри Терминала! Сообщайте о любых ошибках, с которыми вы столкнулись.
+– Терминал теперь поддерживает форматы Sixel!
+– Теперь вы можете открыть закрепленную панель, содержащую фрагменты команд, которые вы сохранили для использования в дальнейшем
+– Пользователи командной строки в новейшем выпуске Windows 11 могут увидеть значок "краткой подсказки", который предлагает устанавливаемые программы из WinGet
+– Выделенный текст теперь станет более видимым (и настраиваемым!)
+– Исправлено несколько ошибок надежности, проблем с удобством, а также устранены раздражающие моменты.
Дополнительные сведения см. на странице выпусков GitHub.
diff --git a/build/StoreSubmission/Stable/PDPs/zh-CN/PDP.xml b/build/StoreSubmission/Stable/PDPs/zh-CN/PDP.xml
index 17d6c841c5..21db7d2c3d 100644
--- a/build/StoreSubmission/Stable/PDPs/zh-CN/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/zh-CN/PDP.xml
@@ -56,12 +56,12 @@
Version __VERSION_NUMBER__
-- 现在,使用会话还原时,终端将记住窗口的内容。
-- 现在可以同时使用多种字体。
-- 现在以像素为单位呈现框绘图字符。
-- 在终端内使用输入法的体验已得到显著提升。
-- JSON 文件中的配色方案现在要简单得多。
-- 已修复有关 URL 处理、双倍行宽、换行等大量 bug。
+- 我们已改变主机应用程序在终端内的托管方式!请报告遇到的任何 bug。
+- 终端现在支持 Sixels!
+- 现在可以打开一个停靠面板,其中包含已保存供以后使用的命令片段
+- 最新 Windows 11 版本上的命令提示用户可能会看到“快速提示”图标,该图标建议从 WinGet 安装软件
+- 所选文本现在将具有更高的可见性(和可自定义性!)
+- 修复了许多可靠性 bug、便利性问题和令人烦恼的问题。
有关其他详细信息,请参阅我们的 GitHub 发布页面。
diff --git a/build/StoreSubmission/Stable/PDPs/zh-TW/PDP.xml b/build/StoreSubmission/Stable/PDPs/zh-TW/PDP.xml
index df182dd95a..02e5b69a3c 100644
--- a/build/StoreSubmission/Stable/PDPs/zh-TW/PDP.xml
+++ b/build/StoreSubmission/Stable/PDPs/zh-TW/PDP.xml
@@ -56,12 +56,12 @@
版本 __VERSION_NUMBER__
-- 當您使用工作階段還原時,終端機現在會記住視窗的內容。
-- 現在您可以同時使用多個字型。
-- 製表格圖字元現在會以完美像素模式呈現。
-- 在終端機內使用 IME 的體驗已大幅改善。
-- JSON 檔案內的色彩配置現在將變得更簡單了。
-- 已修正一些 URL 處理、雙寬度列、換行等相關錯誤。
+- 我們已重寫主機應用程式在終端機內託管的方式!請報告您遇到的錯誤。
+- 終端機現在支援 Sixels!
+- 現在,您可以開啟包含已儲存命令程式碼片段的固定面板,以供稍後使用
+- 最新 Windows 11 版本中的 [命令提示] 使用者可能會看到「快速提示」圖示,建議可自 WinGet 安裝的軟體
+- 選取的文字現在會更明顯 (且可自訂!)
+- 已修正一些可靠性錯誤、便利性問題和令人困擾的問題。
如需更多詳細資訊,請參閱我們的 GitHub 發行頁面。
diff --git a/build/pipelines/ob-nightly.yml b/build/pipelines/ob-nightly.yml
index ca863eb00f..033d075cd6 100644
--- a/build/pipelines/ob-nightly.yml
+++ b/build/pipelines/ob-nightly.yml
@@ -37,6 +37,8 @@ extends:
akvName: $(SigningAKVName)
authCertName: $(SigningAuthCertName)
signCertName: $(SigningSignCertName)
+ useManagedIdentity: $(SigningUseManagedIdentity)
+ clientId: $(SigningOriginalClientId)
publishSymbolsToPublic: true
publishVpackToWindows: false
symbolExpiryTime: 15
diff --git a/build/pipelines/ob-release.yml b/build/pipelines/ob-release.yml
index c403920b54..d7de0e0a3a 100644
--- a/build/pipelines/ob-release.yml
+++ b/build/pipelines/ob-release.yml
@@ -85,6 +85,8 @@ extends:
akvName: $(SigningAKVName)
authCertName: $(SigningAuthCertName)
signCertName: $(SigningSignCertName)
+ useManagedIdentity: $(SigningUseManagedIdentity)
+ clientId: $(SigningOriginalClientId)
terminalInternalPackageVersion: ${{ parameters.terminalInternalPackageVersion }}
publishSymbolsToPublic: ${{ parameters.publishSymbolsToPublic }}
publishVpackToWindows: ${{ parameters.publishVpackToWindows }}
diff --git a/build/pipelines/templates-v2/steps-esrp-signing.yml b/build/pipelines/templates-v2/steps-esrp-signing.yml
index 9a8e6dbd9a..ef5a8d776b 100644
--- a/build/pipelines/templates-v2/steps-esrp-signing.yml
+++ b/build/pipelines/templates-v2/steps-esrp-signing.yml
@@ -19,4 +19,6 @@ steps:
AuthAKVName: ${{ parameters.signingIdentity.akvName }}
AuthCertName: ${{ parameters.signingIdentity.authCertName }}
AuthSignCertName: ${{ parameters.signingIdentity.signCertName }}
+ UseMSIAuthentication: ${{ coalesce(parameters.signingIdentity.useManagedIdentity, 'false') }}
+ EsrpClientId: ${{ parameters.signingIdentity.clientId }}
${{ insert }}: ${{ parameters.inputs }}
diff --git a/build/scripts/New-UnpackagedTerminalDistribution.ps1 b/build/scripts/New-UnpackagedTerminalDistribution.ps1
index 9605f13256..9f8d295be8 100644
--- a/build/scripts/New-UnpackagedTerminalDistribution.ps1
+++ b/build/scripts/New-UnpackagedTerminalDistribution.ps1
@@ -34,7 +34,7 @@ Param(
)
$filesToRemove = @("*.xml", "*.winmd", "Appx*", "Images/*Tile*", "Images/*Logo*") # Remove from Terminal
-$filesToKeep = @("Microsoft.Terminal.Remoting.winmd") # ... except for these
+$filesToKeep = @() # ... except for these
$filesToCopyFromXaml = @("Microsoft.UI.Xaml.dll", "Microsoft.UI.Xaml") # We don't need the .winmd
$ErrorActionPreference = 'Stop'
diff --git a/build/scripts/Set-LatestVCToolsVersion.ps1 b/build/scripts/Set-LatestVCToolsVersion.ps1
index 54a43b3a01..3156fff1bc 100644
--- a/build/scripts/Set-LatestVCToolsVersion.ps1
+++ b/build/scripts/Set-LatestVCToolsVersion.ps1
@@ -1,6 +1,6 @@
$VSInstances = ([xml](& 'C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe' -latest -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64 -include packages -format xml))
$VSPackages = $VSInstances.instances.instance.packages.package
-$LatestVCPackage = ($VSInstances.instances.instance.packages.package | ? { $_.id -eq "Microsoft.VisualCpp.CRT.Source" })
+$LatestVCPackage = ($VSInstances.instances.instance.packages.package | ? { $_.id -eq "Microsoft.VisualCpp.Tools.Core" })
$LatestVCToolsVersion = $LatestVCPackage.version;
Write-Output "Latest VCToolsVersion: $LatestVCToolsVersion"
diff --git a/build/scripts/Test-WindowsTerminalPackage.ps1 b/build/scripts/Test-WindowsTerminalPackage.ps1
index b405d98c21..b492eca05f 100644
--- a/build/scripts/Test-WindowsTerminalPackage.ps1
+++ b/build/scripts/Test-WindowsTerminalPackage.ps1
@@ -58,7 +58,7 @@ Try {
### Check the activatable class entries for a few DLLs we need.
$inProcServers = $Manifest.Package.Extensions.Extension.InProcessServer.Path
- $RequiredInProcServers = ("TerminalApp.dll", "Microsoft.Terminal.Control.dll", "Microsoft.Terminal.Remoting.dll", "Microsoft.Terminal.Settings.Editor.dll", "Microsoft.Terminal.Settings.Model.dll", "TerminalConnection.dll")
+ $RequiredInProcServers = ("TerminalApp.dll", "Microsoft.Terminal.Control.dll", "Microsoft.Terminal.Settings.Editor.dll", "Microsoft.Terminal.Settings.Model.dll", "TerminalConnection.dll")
Write-Verbose "InProc Servers: $inProcServers"
diff --git a/consolegit2gitfilters.json b/consolegit2gitfilters.json
index 3dbcfdc9a2..1d570f2497 100644
--- a/consolegit2gitfilters.json
+++ b/consolegit2gitfilters.json
@@ -24,8 +24,6 @@
"/doc/specs/",
"/doc/cascadia/",
"/doc/user-docs/",
- "/src/tools/MonarchPeasantSample/",
- "/src/tools/MonarchPeasantPackage/",
"/src/tools/ansi-color/",
"/src/tools/ColorTool/",
"/scratch/",
diff --git a/custom.props b/custom.props
index e25b9e8e97..8e358b3e0b 100644
--- a/custom.props
+++ b/custom.props
@@ -3,9 +3,9 @@
true
- 2024
+ 20251
- 23
+ 24Windows Terminal
diff --git a/doc/cascadia/profiles.schema.json b/doc/cascadia/profiles.schema.json
index 09be784c15..315d103c53 100644
--- a/doc/cascadia/profiles.schema.json
+++ b/doc/cascadia/profiles.schema.json
@@ -35,7 +35,8 @@
"enum": [
"Windows.Terminal.Wsl",
"Windows.Terminal.Azure",
- "Windows.Terminal.PowershellCore"
+ "Windows.Terminal.PowershellCore",
+ "Windows.Terminal.VisualStudio"
],
"type": "string"
},
@@ -2372,16 +2373,6 @@
"description": "When set to true, Windows Terminal will run in the background. This allows globalSummon and quakeMode actions to work even when no windows are open.",
"type": "boolean"
},
- "compatibility.isolatedMode": {
- "default": false,
- "description": "When set to true, Terminal windows will not be able to interact with each other (including global hotkeys, tab drag/drop, running commandlines in existing windows, etc.). This is a compatibility escape hatch for users who are running into certain windowing issues.",
- "type": "boolean"
- },
- "compatibility.allowDECRQCRA": {
- "default": false,
- "description": "When set to true, the terminal will support the DECRQCRA (Request Checksum of Rectangular Area) escape sequence.",
- "type": "boolean"
- },
"compatibility.textMeasurement": {
"default": "graphemes",
"description": "This changes the way incoming text is grouped into cells. The \"graphemes\" option is the most modern and Unicode-correct way to do so, while \"wcswidth\" is a common approach on UNIX, and \"console\" replicates the way it used to work on Windows.",
@@ -2541,6 +2532,11 @@
"description": "When set to true, the Terminal's tab row will display a shield icon when the Terminal is running with administrator privileges",
"type": "boolean"
},
+ "showTabsFullscreen": {
+ "default": false,
+ "description": "When set to true, tabs remain visible in fullscreen mode. When set to false, tabs will be hidden when entering fullscreen mode.",
+ "type": "boolean"
+ },
"useAcrylicInTabRow": {
"default": false,
"description": "When set to true, the tab row will have an acrylic material background with 50% opacity.",
@@ -2730,6 +2726,16 @@
"description": "When set to true, when opening a new tab or pane it will get reloaded environment variables.",
"type": "boolean"
},
+ "compatibility.allowDECRQCRA": {
+ "default": false,
+ "description": "When set to true, the terminal will support the DECRQCRA (Request Checksum of Rectangular Area) escape sequence.",
+ "type": "boolean"
+ },
+ "compatibility.allowOSC52": {
+ "default": true,
+ "description": "When set to true, VT applications will be allowed to set the contents of the local clipboard using OSC 52 (Manipulate Selection Data).",
+ "type": "boolean"
+ },
"unfocusedAppearance": {
"$ref": "#/$defs/AppearanceConfig",
"description": "Sets the appearance of the terminal when it is unfocused.",
@@ -2911,7 +2917,7 @@
},
"experimental.rightClickContextMenu": {
"default": false,
- "description": "When set to true, right-clicking on the terminal will show a context menu. When set to false, right-click will copy",
+ "description": "When true, right-click shows a context menu; otherwise, it pastes from the clipboard or copies selection.",
"type": "boolean"
},
"experimental.repositionCursorWithMouse": {
diff --git a/res/fonts/CascadiaCode.ttf b/res/fonts/CascadiaCode.ttf
index 4e55e88db5..bba59c9600 100644
Binary files a/res/fonts/CascadiaCode.ttf and b/res/fonts/CascadiaCode.ttf differ
diff --git a/res/fonts/CascadiaCodeItalic.ttf b/res/fonts/CascadiaCodeItalic.ttf
index c0233a1b7a..7941ecd712 100644
Binary files a/res/fonts/CascadiaCodeItalic.ttf and b/res/fonts/CascadiaCodeItalic.ttf differ
diff --git a/res/fonts/CascadiaMono.ttf b/res/fonts/CascadiaMono.ttf
index 4c9f3d2158..f6f62d49c3 100644
Binary files a/res/fonts/CascadiaMono.ttf and b/res/fonts/CascadiaMono.ttf differ
diff --git a/res/fonts/CascadiaMonoItalic.ttf b/res/fonts/CascadiaMonoItalic.ttf
index c13eddbb6f..35bfe6f197 100644
Binary files a/res/fonts/CascadiaMonoItalic.ttf and b/res/fonts/CascadiaMonoItalic.ttf differ
diff --git a/res/fonts/README.md b/res/fonts/README.md
index e30d23aa8b..7d4e0ada97 100644
--- a/res/fonts/README.md
+++ b/res/fonts/README.md
@@ -8,5 +8,5 @@ Please consult the [license](https://raw.githubusercontent.com/microsoft/cascadi
### Fonts Included
-* Cascadia Code, Cascadia Mono (2404.23)
- * from microsoft/cascadia-code@1034791e5fc6e060a448d2b29cd94a6c683edb36
+* Cascadia Code, Cascadia Mono (2407.24)
+ * from microsoft/cascadia-code@56bcca3f2c1e4cb19458954f0e2bb4635960df91
diff --git a/src/Terminal.wprp b/src/Terminal.wprp
index 1abe7df41a..754cc1af26 100644
--- a/src/Terminal.wprp
+++ b/src/Terminal.wprp
@@ -10,7 +10,6 @@
-
@@ -30,7 +29,6 @@
-
@@ -51,7 +49,6 @@
-
diff --git a/src/buffer/out/Row.cpp b/src/buffer/out/Row.cpp
index 7a46215b6f..63ba83f4cd 100644
--- a/src/buffer/out/Row.cpp
+++ b/src/buffer/out/Row.cpp
@@ -80,11 +80,12 @@ constexpr OutIt copy_n_small(InIt first, Diff count, OutIt dest)
return dest;
}
-CharToColumnMapper::CharToColumnMapper(const wchar_t* chars, const uint16_t* charOffsets, ptrdiff_t lastCharOffset, til::CoordType currentColumn) noexcept :
+CharToColumnMapper::CharToColumnMapper(const wchar_t* chars, const uint16_t* charOffsets, ptrdiff_t charsLength, til::CoordType currentColumn, til::CoordType columnCount) noexcept :
_chars{ chars },
_charOffsets{ charOffsets },
- _lastCharOffset{ lastCharOffset },
- _currentColumn{ currentColumn }
+ _charsLength{ charsLength },
+ _currentColumn{ currentColumn },
+ _columnCount{ columnCount }
{
}
@@ -92,7 +93,7 @@ CharToColumnMapper::CharToColumnMapper(const wchar_t* chars, const uint16_t* cha
// This function in particular returns the glyph's first column.
til::CoordType CharToColumnMapper::GetLeadingColumnAt(ptrdiff_t targetOffset) noexcept
{
- targetOffset = clamp(targetOffset, 0, _lastCharOffset);
+ targetOffset = clamp(targetOffset, 0, _charsLength);
// This code needs to fulfill two conditions on top of the obvious (a forward/backward search):
// A: We never want to stop on a column that is marked with CharOffsetsTrailer (= "GetLeadingColumn").
@@ -130,10 +131,14 @@ til::CoordType CharToColumnMapper::GetLeadingColumnAt(ptrdiff_t targetOffset) no
til::CoordType CharToColumnMapper::GetTrailingColumnAt(ptrdiff_t offset) noexcept
{
auto col = GetLeadingColumnAt(offset);
- // This loop is a little redundant with the forward search loop in GetLeadingColumnAt()
- // but it's realistically not worth caring about this. This code is not a bottleneck.
- for (; WI_IsFlagSet(_charOffsets[col + 1], CharOffsetsTrailer); ++col)
+
+ if (col < _columnCount)
{
+ // This loop is a little redundant with the forward search loop in GetLeadingColumnAt()
+ // but it's realistically not worth caring about this. This code is not a bottleneck.
+ for (; WI_IsFlagSet(_charOffsets[col + 1], CharOffsetsTrailer); ++col)
+ {
+ }
}
return col;
}
@@ -1114,6 +1119,9 @@ std::wstring_view ROW::GetText() const noexcept
return { _chars.data(), width };
}
+// Arguments:
+// - columnBegin: inclusive
+// - columnEnd: exclusive
std::wstring_view ROW::GetText(til::CoordType columnBegin, til::CoordType columnEnd) const noexcept
{
const auto columns = GetReadableColumnCount();
@@ -1219,15 +1227,15 @@ T ROW::_adjustForward(T column) const noexcept
}
// Creates a CharToColumnMapper given an offset into _chars.data().
-// In other words, for a 120 column ROW with just ASCII text, the offset should be [0,120).
+// In other words, for a 120 column ROW with just ASCII text, the offset should be [0,120].
CharToColumnMapper ROW::_createCharToColumnMapper(ptrdiff_t offset) const noexcept
{
const auto charsSize = _charSize();
- const auto lastChar = gsl::narrow_cast(charsSize - 1);
+ const auto lastChar = gsl::narrow_cast(charsSize);
// We can sort of guess what column belongs to what offset because BMP glyphs are very common and
// UTF-16 stores them in 1 char. In other words, usually a ROW will have N chars for N columns.
const auto guessedColumn = gsl::narrow_cast(clamp(offset, 0, _columnCount));
- return CharToColumnMapper{ _chars.data(), _charOffsets.data(), lastChar, guessedColumn };
+ return CharToColumnMapper{ _chars.data(), _charOffsets.data(), lastChar, guessedColumn, _columnCount };
}
const std::optional& ROW::GetScrollbarData() const noexcept
diff --git a/src/buffer/out/Row.hpp b/src/buffer/out/Row.hpp
index d2c19036ba..44156d1b88 100644
--- a/src/buffer/out/Row.hpp
+++ b/src/buffer/out/Row.hpp
@@ -71,7 +71,7 @@ struct RowCopyTextFromState
// into a ROW's text this class can tell you what cell that pointer belongs to.
struct CharToColumnMapper
{
- CharToColumnMapper(const wchar_t* chars, const uint16_t* charOffsets, ptrdiff_t lastCharOffset, til::CoordType currentColumn) noexcept;
+ CharToColumnMapper(const wchar_t* chars, const uint16_t* charOffsets, ptrdiff_t lastCharOffset, til::CoordType currentColumn, til::CoordType columnCount) noexcept;
til::CoordType GetLeadingColumnAt(ptrdiff_t targetOffset) noexcept;
til::CoordType GetTrailingColumnAt(ptrdiff_t offset) noexcept;
@@ -85,8 +85,9 @@ private:
const wchar_t* _chars;
const uint16_t* _charOffsets;
- ptrdiff_t _lastCharOffset;
+ ptrdiff_t _charsLength;
til::CoordType _currentColumn;
+ til::CoordType _columnCount;
};
class ROW final
diff --git a/src/buffer/out/UTextAdapter.cpp b/src/buffer/out/UTextAdapter.cpp
index ff0861ce54..717d97812a 100644
--- a/src/buffer/out/UTextAdapter.cpp
+++ b/src/buffer/out/UTextAdapter.cpp
@@ -411,16 +411,13 @@ Microsoft::Console::ICU::unique_uregex Microsoft::Console::ICU::CreateRegex(cons
return unique_uregex{ re };
}
-// Returns an inclusive point range given a text start and end position.
+// Returns a half-open [beg,end) range given a text start and end position.
// This function is designed to be used with uregex_start64/uregex_end64.
til::point_span Microsoft::Console::ICU::BufferRangeFromMatch(UText* ut, URegularExpression* re)
{
UErrorCode status = U_ZERO_ERROR;
const auto nativeIndexBeg = uregex_start64(re, 0, &status);
- auto nativeIndexEnd = uregex_end64(re, 0, &status);
-
- // The parameters are given as a half-open [beg,end) range, but the point_span we return in closed [beg,end].
- nativeIndexEnd--;
+ const auto nativeIndexEnd = uregex_end64(re, 0, &status);
const auto& textBuffer = *static_cast(ut->context);
til::point_span ret;
@@ -439,7 +436,7 @@ til::point_span Microsoft::Console::ICU::BufferRangeFromMatch(UText* ut, URegula
if (utextAccess(ut, nativeIndexEnd, true))
{
const auto y = accessCurrentRow(ut);
- ret.end.x = textBuffer.GetRowByOffset(y).GetTrailingColumnAtCharOffset(ut->chunkOffset);
+ ret.end.x = textBuffer.GetRowByOffset(y).GetLeadingColumnAtCharOffset(ut->chunkOffset);
ret.end.y = y;
}
else
diff --git a/src/buffer/out/textBuffer.cpp b/src/buffer/out/textBuffer.cpp
index a920854b73..df30a3ffb2 100644
--- a/src/buffer/out/textBuffer.cpp
+++ b/src/buffer/out/textBuffer.cpp
@@ -1118,6 +1118,14 @@ void TextBuffer::TriggerNewTextNotification(const std::wstring_view newText)
}
}
+void TextBuffer::TriggerSelection()
+{
+ if (_isActiveBuffer && _renderer)
+ {
+ _renderer->TriggerSelection();
+ }
+}
+
// Method Description:
// - get delimiter class for buffer cell position
// - used for double click selection and uia word navigation
@@ -1132,6 +1140,213 @@ DelimiterClass TextBuffer::_GetDelimiterClassAt(const til::point pos, const std:
return GetRowByOffset(realPos.y).DelimiterClassAt(realPos.x, wordDelimiters);
}
+til::point TextBuffer::GetWordStart2(til::point pos, const std::wstring_view wordDelimiters, bool includeWhitespace, std::optional limitOptional) const
+{
+ const auto bufferSize{ GetSize() };
+ const auto limit{ limitOptional.value_or(bufferSize.BottomInclusiveRightExclusive()) };
+
+ if (pos < bufferSize.Origin())
+ {
+ // can't move further back, so return early at origin
+ return bufferSize.Origin();
+ }
+ else if (pos >= limit)
+ {
+ // clamp to limit,
+ // but still do movement
+ pos = limit;
+ }
+
+ // Consider the delimiter classes represented as these chars:
+ // - ControlChar: "_"
+ // - DelimiterChar: "D"
+ // - RegularChar: "C"
+ // Expected results ("|" is the position):
+ // includeWhitespace: true false
+ // CCC___| --> |CCC___ CCC|___
+ // DDD___| --> |DDD___ DDD|___
+ // ___CCC| --> ___|CCC ___|CCC
+ // DDDCCC| --> DDD|CCC DDD|CCC
+ // ___DDD| --> ___|DDD ___|DDD
+ // CCCDDD| --> CCC|DDD CCC|DDD
+ // So the heuristic we use is:
+ // 1. move to the beginning of the delimiter class run
+ // 2. (includeWhitespace) if we were on a ControlChar, go back one more delimiter class run
+ const auto initialDelimiter = bufferSize.IsInBounds(pos) ? _GetDelimiterClassAt(pos, wordDelimiters) : DelimiterClass::ControlChar;
+ pos = _GetDelimiterClassRunStart(pos, wordDelimiters);
+ if (!includeWhitespace || pos.x == bufferSize.Left())
+ {
+ // Special case:
+ // we're at the left boundary (and end of a delimiter class run),
+ // we already know we can't wrap, so return early
+ return pos;
+ }
+ else if (initialDelimiter == DelimiterClass::ControlChar)
+ {
+ bufferSize.DecrementInExclusiveBounds(pos);
+ pos = _GetDelimiterClassRunStart(pos, wordDelimiters);
+ }
+ return pos;
+}
+
+til::point TextBuffer::GetWordEnd2(til::point pos, const std::wstring_view wordDelimiters, bool includeWhitespace, std::optional limitOptional) const
+{
+ const auto bufferSize{ GetSize() };
+ const auto limit{ limitOptional.value_or(bufferSize.BottomInclusiveRightExclusive()) };
+
+ if (pos >= limit)
+ {
+ // can't move further forward,
+ // so return early at limit
+ return limit;
+ }
+ else if (const auto origin{ bufferSize.Origin() }; pos < origin)
+ {
+ // clamp to origin,
+ // but still do movement
+ pos = origin;
+ }
+
+ // Consider the delimiter classes represented as these chars:
+ // - ControlChar: "_"
+ // - DelimiterChar: "D"
+ // - RegularChar: "C"
+ // Expected results ("|" is the position):
+ // includeWhitespace: true false
+ // |CCC___ --> CCC___| CCC|___
+ // |DDD___ --> DDD___| DDD|___
+ // |___CCC --> ___|CCC ___|CCC
+ // |DDDCCC --> DDD|CCC DDD|CCC
+ // |___DDD --> ___|DDD ___|DDD
+ // |CCCDDD --> CCC|DDD CCC|DDD
+ // So the heuristic we use is:
+ // 1. move to the end of the delimiter class run
+ // 2. (includeWhitespace) if the next delimiter class run is a ControlChar, go forward one more delimiter class run
+ pos = _GetDelimiterClassRunEnd(pos, wordDelimiters);
+ if (!includeWhitespace || pos.x == bufferSize.RightExclusive())
+ {
+ // Special case:
+ // we're at the right boundary (and end of a delimiter class run),
+ // we already know we can't wrap, so return early
+ return pos;
+ }
+
+ if (const auto nextDelimClass = bufferSize.IsInBounds(pos) ? _GetDelimiterClassAt(pos, wordDelimiters) : DelimiterClass::ControlChar;
+ nextDelimClass == DelimiterClass::ControlChar)
+ {
+ return _GetDelimiterClassRunEnd(pos, wordDelimiters);
+ }
+ return pos;
+}
+
+bool TextBuffer::IsWordBoundary(const til::point pos, const std::wstring_view wordDelimiters) const
+{
+ const auto bufferSize = GetSize();
+ if (!bufferSize.IsInExclusiveBounds(pos))
+ {
+ // not in bounds
+ return false;
+ }
+
+ // buffer boundaries are always word boundaries
+ if (pos == bufferSize.Origin() || pos == bufferSize.BottomInclusiveRightExclusive())
+ {
+ return true;
+ }
+
+ // at beginning of the row, but we didn't wrap
+ if (pos.x == bufferSize.Left())
+ {
+ const auto& row = GetRowByOffset(pos.y - 1);
+ if (!row.WasWrapForced())
+ {
+ return true;
+ }
+ }
+
+ // at end of the row, but we didn't wrap
+ if (pos.x == bufferSize.RightExclusive())
+ {
+ const auto& row = GetRowByOffset(pos.y);
+ if (!row.WasWrapForced())
+ {
+ return true;
+ }
+ }
+
+ // we can treat text as contiguous,
+ // use DecrementInBounds (not exclusive) here
+ auto prevPos = pos;
+ bufferSize.DecrementInBounds(prevPos);
+ const auto prevDelimiterClass = _GetDelimiterClassAt(prevPos, wordDelimiters);
+
+ // if we changed delimiter class
+ // and the current delimiter class is not a control char,
+ // we're at a word boundary
+ const auto currentDelimiterClass = _GetDelimiterClassAt(pos, wordDelimiters);
+ return prevDelimiterClass != currentDelimiterClass && currentDelimiterClass != DelimiterClass::ControlChar;
+}
+
+til::point TextBuffer::_GetDelimiterClassRunStart(til::point pos, const std::wstring_view wordDelimiters) const
+{
+ const auto bufferSize = GetSize();
+ const auto initialDelimClass = bufferSize.IsInBounds(pos) ? _GetDelimiterClassAt(pos, wordDelimiters) : DelimiterClass::ControlChar;
+ for (auto nextPos = pos; nextPos != bufferSize.Origin(); pos = nextPos)
+ {
+ bufferSize.DecrementInExclusiveBounds(nextPos);
+
+ if (nextPos.x == bufferSize.RightExclusive())
+ {
+ // wrapped onto previous line,
+ // check if it was forced to wrap
+ const auto& row = GetRowByOffset(nextPos.y);
+ if (!row.WasWrapForced())
+ {
+ return pos;
+ }
+ }
+ else if (_GetDelimiterClassAt(nextPos, wordDelimiters) != initialDelimClass)
+ {
+ // if we changed delim class, we're done (don't apply move)
+ return pos;
+ }
+ }
+ return pos;
+}
+
+// Method Description:
+// - Get the exclusive position for the end of the current delimiter class run
+// Arguments:
+// - pos - the buffer position being within the current delimiter class
+// - wordDelimiters - what characters are we considering for the separation of words
+til::point TextBuffer::_GetDelimiterClassRunEnd(til::point pos, const std::wstring_view wordDelimiters) const
+{
+ const auto bufferSize = GetSize();
+ const auto initialDelimClass = bufferSize.IsInBounds(pos) ? _GetDelimiterClassAt(pos, wordDelimiters) : DelimiterClass::ControlChar;
+ for (auto nextPos = pos; nextPos != bufferSize.BottomInclusiveRightExclusive(); pos = nextPos)
+ {
+ bufferSize.IncrementInExclusiveBounds(nextPos);
+
+ if (nextPos.x == bufferSize.Left())
+ {
+ // wrapped onto next line,
+ // check if it was forced to wrap or switched delimiter class
+ const auto& row = GetRowByOffset(pos.y);
+ if (!row.WasWrapForced() || _GetDelimiterClassAt(nextPos, wordDelimiters) != initialDelimClass)
+ {
+ return pos;
+ }
+ }
+ else if (bufferSize.IsInBounds(nextPos) && _GetDelimiterClassAt(nextPos, wordDelimiters) != initialDelimClass)
+ {
+ // if we changed delim class,
+ // apply the move and return
+ return nextPos;
+ }
+ }
+ return pos;
+}
+
// Method Description:
// - Get the til::point for the beginning of the word you are on
// Arguments:
@@ -1520,13 +1735,14 @@ til::point TextBuffer::GetGlyphStart(const til::point pos, std::optional 0)
+ if (resultPos > limit)
{
- resultPos = limit;
+ return limit;
}
- // limit is exclusive, so we need to move back to be within valid bounds
- if (resultPos != limit && GetCellDataAt(resultPos)->DbcsAttr() == DbcsAttribute::Trailing)
+ // if we're on a trailing byte, move to the leading byte
+ if (bufferSize.IsInBounds(resultPos) &&
+ GetCellDataAt(resultPos)->DbcsAttr() == DbcsAttribute::Trailing)
{
bufferSize.DecrementInBounds(resultPos, true);
}
@@ -1548,12 +1764,13 @@ til::point TextBuffer::GetGlyphEnd(const til::point pos, bool accessibilityMode,
const auto limit{ limitOptional.value_or(bufferSize.EndExclusive()) };
// Clamp pos to limit
- if (bufferSize.CompareInBounds(resultPos, limit, true) > 0)
+ if (resultPos > limit)
{
- resultPos = limit;
+ return limit;
}
- if (resultPos != limit && GetCellDataAt(resultPos)->DbcsAttr() == DbcsAttribute::Leading)
+ if (bufferSize.IsInBounds(resultPos) &&
+ GetCellDataAt(resultPos)->DbcsAttr() == DbcsAttribute::Leading)
{
bufferSize.IncrementInBounds(resultPos, true);
}
@@ -1610,6 +1827,31 @@ bool TextBuffer::MoveToNextGlyph(til::point& pos, bool allowExclusiveEnd, std::o
return success;
}
+bool TextBuffer::MoveToNextGlyph2(til::point& pos, std::optional limitOptional) const
+{
+ const auto bufferSize = GetSize();
+ const auto limit{ limitOptional.value_or(bufferSize.BottomInclusiveRightExclusive()) };
+
+ if (pos >= limit)
+ {
+ // Corner Case: we're on/past the limit
+ // Clamp us to the limit
+ pos = limit;
+ return false;
+ }
+
+ // Try to move forward, but if we hit the buffer boundary, we fail to move.
+ const bool success = bufferSize.IncrementInExclusiveBounds(pos);
+ if (success &&
+ bufferSize.IsInBounds(pos) &&
+ GetCellDataAt(pos)->DbcsAttr() == DbcsAttribute::Trailing)
+ {
+ // Move again if we're on a wide glyph
+ bufferSize.IncrementInExclusiveBounds(pos);
+ }
+ return success;
+}
+
// Method Description:
// - Update pos to be the beginning of the previous glyph/character. This is used for accessibility
// Arguments:
@@ -1642,6 +1884,31 @@ bool TextBuffer::MoveToPreviousGlyph(til::point& pos, std::optional
return success;
}
+bool TextBuffer::MoveToPreviousGlyph2(til::point& pos, std::optional limitOptional) const
+{
+ const auto bufferSize = GetSize();
+ const auto limit{ limitOptional.value_or(bufferSize.BottomInclusiveRightExclusive()) };
+
+ if (pos >= limit)
+ {
+ // Corner Case: we're on/past the limit
+ // Clamp us to the limit
+ pos = limit;
+ return false;
+ }
+
+ // Try to move backward, but if we hit the buffer boundary, we fail to move.
+ const bool success = bufferSize.DecrementInExclusiveBounds(pos);
+ if (success &&
+ bufferSize.IsInBounds(pos) &&
+ GetCellDataAt(pos)->DbcsAttr() == DbcsAttribute::Trailing)
+ {
+ // Move again if we're on a wide glyph
+ bufferSize.DecrementInExclusiveBounds(pos);
+ }
+ return success;
+}
+
// Method Description:
// - Determines the line-by-line rectangles based on two COORDs
// - expands the rectangles to support wide glyphs
@@ -1660,12 +1927,10 @@ const std::vector TextBuffer::GetTextRects(til::point start
{
std::vector textRects;
- const auto bufferSize = GetSize();
-
// (0,0) is the top-left of the screen
// the physically "higher" coordinate is closer to the top-left
// the physically "lower" coordinate is closer to the bottom-right
- const auto [higherCoord, lowerCoord] = bufferSize.CompareInBounds(start, end) <= 0 ?
+ const auto [higherCoord, lowerCoord] = start <= end ?
std::make_tuple(start, end) :
std::make_tuple(end, start);
@@ -1686,6 +1951,7 @@ const std::vector TextBuffer::GetTextRects(til::point start
}
else
{
+ const auto bufferSize = GetSize();
textRow.left = (row == higherCoord.y) ? higherCoord.x : bufferSize.Left();
textRow.right = (row == lowerCoord.y) ? lowerCoord.x : bufferSize.RightInclusive();
}
@@ -1710,7 +1976,7 @@ const std::vector TextBuffer::GetTextRects(til::point start
// - Else if a blockSelection, returns spans corresponding to each line in the block selection
// Arguments:
// - start: beginning of the text region of interest (inclusive)
-// - end: the other end of the text region of interest (inclusive)
+// - end: the other end of the text region of interest (exclusive)
// - blockSelection: when enabled, get spans for each line covered by the block
// - bufferCoordinates: when enabled, treat the coordinates as relative to
// the buffer rather than the screen.
@@ -1780,31 +2046,17 @@ void TextBuffer::_ExpandTextRow(til::inclusive_rect& textRow) const
// expand left side of rect
til::point targetPoint{ textRow.left, textRow.top };
- if (GetCellDataAt(targetPoint)->DbcsAttr() == DbcsAttribute::Trailing)
+ if (bufferSize.IsInBounds(targetPoint) && GetCellDataAt(targetPoint)->DbcsAttr() == DbcsAttribute::Trailing)
{
- if (targetPoint.x == bufferSize.Left())
- {
- bufferSize.IncrementInBounds(targetPoint);
- }
- else
- {
- bufferSize.DecrementInBounds(targetPoint);
- }
+ bufferSize.DecrementInExclusiveBounds(targetPoint);
textRow.left = targetPoint.x;
}
// expand right side of rect
targetPoint = { textRow.right, textRow.bottom };
- if (GetCellDataAt(targetPoint)->DbcsAttr() == DbcsAttribute::Leading)
+ if (bufferSize.IsInBounds(targetPoint) && GetCellDataAt(targetPoint)->DbcsAttr() == DbcsAttribute::Trailing)
{
- if (targetPoint.x == bufferSize.RightInclusive())
- {
- bufferSize.DecrementInBounds(targetPoint);
- }
- else
- {
- bufferSize.IncrementInBounds(targetPoint);
- }
+ bufferSize.IncrementInExclusiveBounds(targetPoint);
textRow.right = targetPoint.x;
}
}
@@ -1821,8 +2073,8 @@ size_t TextBuffer::SpanLength(const til::point coordStart, const til::point coor
// - Retrieves the plain text data between the specified coordinates.
// Arguments:
// - trimTrailingWhitespace - remove the trailing whitespace at the end of the result.
-// - start - where to start getting text (should be at or prior to "end")
-// - end - where to end getting text
+// - start - where to start getting text (should be at or prior to "end") (inclusive)
+// - end - where to end getting text (exclusive)
// Return Value:
// - Just the text.
std::wstring TextBuffer::GetPlainText(const til::point start, const til::point end) const
@@ -1851,7 +2103,7 @@ std::tuple TextBuffer::_RowCopyHelper(cons
const auto maxX = req.bufferCoordinates ? req.maxX : ScreenToBufferLineInclusive(til::point{ req.maxX, iRow }, lineRendition).x;
rowBeg = minX;
- rowEnd = maxX + 1; // +1 to get an exclusive end
+ rowEnd = maxX;
}
else
{
@@ -1860,7 +2112,7 @@ std::tuple TextBuffer::_RowCopyHelper(cons
const auto end = req.bufferCoordinates ? req.end : ScreenToBufferLineInclusive(req.end, lineRendition);
rowBeg = iRow != beg.y ? 0 : beg.x;
- rowEnd = iRow != end.y ? row.GetReadableColumnCount() : end.x + 1; // +1 to get an exclusive end
+ rowEnd = iRow != end.y ? row.GetReadableColumnCount() : end.x;
}
// Our selection mechanism doesn't stick to glyph boundaries at the moment.
@@ -1905,7 +2157,7 @@ std::wstring TextBuffer::GetPlainText(const CopyRequest& req) const
const auto& row = GetRowByOffset(iRow);
const auto& [rowBeg, rowEnd, addLineBreak] = _RowCopyHelper(req, iRow, row);
- // save selected text
+ // save selected text (exclusive end)
selectedText += row.GetText(rowBeg, rowEnd);
if (addLineBreak && iRow != req.end.y)
diff --git a/src/buffer/out/textBuffer.hpp b/src/buffer/out/textBuffer.hpp
index c97de9e752..775417caab 100644
--- a/src/buffer/out/textBuffer.hpp
+++ b/src/buffer/out/textBuffer.hpp
@@ -170,9 +170,15 @@ public:
void TriggerScroll();
void TriggerScroll(const til::point delta);
void TriggerNewTextNotification(const std::wstring_view newText);
+ void TriggerSelection();
til::point GetWordStart(const til::point target, const std::wstring_view wordDelimiters, bool accessibilityMode = false, std::optional limitOptional = std::nullopt) const;
til::point GetWordEnd(const til::point target, const std::wstring_view wordDelimiters, bool accessibilityMode = false, std::optional limitOptional = std::nullopt) const;
+
+ til::point GetWordStart2(til::point pos, const std::wstring_view wordDelimiters, bool includeWhitespace, std::optional limitOptional = std::nullopt) const;
+ til::point GetWordEnd2(til::point pos, const std::wstring_view wordDelimiters, bool includeWhitespace, std::optional limitOptional = std::nullopt) const;
+
+ bool IsWordBoundary(const til::point pos, const std::wstring_view wordDelimiters) const;
bool MoveToNextWord(til::point& pos, const std::wstring_view wordDelimiters, std::optional limitOptional = std::nullopt) const;
bool MoveToPreviousWord(til::point& pos, const std::wstring_view wordDelimiters) const;
@@ -180,6 +186,8 @@ public:
til::point GetGlyphEnd(const til::point pos, bool accessibilityMode = false, std::optional limitOptional = std::nullopt) const;
bool MoveToNextGlyph(til::point& pos, bool allowBottomExclusive = false, std::optional limitOptional = std::nullopt) const;
bool MoveToPreviousGlyph(til::point& pos, std::optional limitOptional = std::nullopt) const;
+ bool MoveToNextGlyph2(til::point& pos, std::optional limitOptional = std::nullopt) const;
+ bool MoveToPreviousGlyph2(til::point& pos, std::optional limitOptional = std::nullopt) const;
const std::vector GetTextRects(til::point start, til::point end, bool blockSelection, bool bufferCoordinates) const;
std::vector GetTextSpans(til::point start, til::point end, bool blockSelection, bool bufferCoordinates) const;
@@ -322,6 +330,8 @@ private:
void _SetFirstRowIndex(const til::CoordType FirstRowIndex) noexcept;
void _ExpandTextRow(til::inclusive_rect& selectionRow) const;
DelimiterClass _GetDelimiterClassAt(const til::point pos, const std::wstring_view wordDelimiters) const;
+ til::point _GetDelimiterClassRunStart(til::point pos, const std::wstring_view wordDelimiters) const;
+ til::point _GetDelimiterClassRunEnd(til::point pos, const std::wstring_view wordDelimiters) const;
til::point _GetWordStartForAccessibility(const til::point target, const std::wstring_view wordDelimiters) const;
til::point _GetWordStartForSelection(const til::point target, const std::wstring_view wordDelimiters) const;
til::point _GetWordEndForAccessibility(const til::point target, const std::wstring_view wordDelimiters, const til::point limit) const;
diff --git a/src/buffer/out/ut_textbuffer/UTextAdapterTests.cpp b/src/buffer/out/ut_textbuffer/UTextAdapterTests.cpp
index be9e941c75..81974fe83a 100644
--- a/src/buffer/out/ut_textbuffer/UTextAdapterTests.cpp
+++ b/src/buffer/out/ut_textbuffer/UTextAdapterTests.cpp
@@ -49,15 +49,15 @@ class UTextAdapterTests
return { { beg, 0 }, { end, 0 } };
};
- auto expected = std::vector{ s(0, 2), s(8, 10) };
+ auto expected = std::vector{ s(0, 3), s(8, 11) };
auto actual = buffer.SearchText(L"abc", SearchFlag::None);
VERIFY_ARE_EQUAL(expected, actual);
- expected = std::vector{ s(5, 5) };
+ expected = std::vector{ s(5, 6) };
actual = buffer.SearchText(L"𝒷", SearchFlag::None);
VERIFY_ARE_EQUAL(expected, actual);
- expected = std::vector{ s(12, 15) };
+ expected = std::vector{ s(12, 16) };
actual = buffer.SearchText(L"ネコ", SearchFlag::None);
VERIFY_ARE_EQUAL(expected, actual);
}
diff --git a/src/cascadia/LocalTests_TerminalApp/CommandlineTest.cpp b/src/cascadia/LocalTests_TerminalApp/CommandlineTest.cpp
index f3c0efa463..ff69ebf51e 100644
--- a/src/cascadia/LocalTests_TerminalApp/CommandlineTest.cpp
+++ b/src/cascadia/LocalTests_TerminalApp/CommandlineTest.cpp
@@ -8,7 +8,6 @@
#include "../TerminalApp/TerminalPage.h"
#include "../TerminalApp/AppLogic.h"
#include "../TerminalApp/AppCommandlineArgs.h"
-#include "../inc/WindowingBehavior.h"
using namespace WEX::Logging;
using namespace WEX::Common;
@@ -74,10 +73,6 @@ namespace TerminalAppLocalTests
TEST_METHOD(TestMultipleSplitPaneSizes);
- TEST_METHOD(TestFindTargetWindow);
- TEST_METHOD(TestFindTargetWindowHelp);
- TEST_METHOD(TestFindTargetWindowVersion);
-
private:
void _buildCommandlinesHelper(AppCommandlineArgs& appArgs,
const size_t expectedSubcommands,
@@ -1934,209 +1929,4 @@ namespace TerminalAppLocalTests
}
}
}
-
- void CommandlineTest::TestFindTargetWindow()
- {
- {
- Log::Comment(L"wt.exe with no args should always use the value from"
- L" the settings (passed as the second argument).");
-
- std::vector args{ L"wt.exe" };
- auto result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseNew);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseExisting, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseAnyExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseAnyExisting, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
- }
- {
- Log::Comment(L"-w -1 should always result in a new window");
-
- std::vector args{ L"wt.exe", L"-w", L"-1" };
- auto result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseNew);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseAnyExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
- }
- {
- Log::Comment(L"\"new\" should always result in a new window");
-
- std::vector args{ L"wt.exe", L"-w", L"new" };
- auto result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseNew);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseAnyExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
- }
- {
- Log::Comment(L"-w with a negative number should always result in a "
- L"new window");
-
- std::vector args{ L"wt.exe", L"-w", L"-12345" };
- auto result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseNew);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseAnyExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
- }
- {
- Log::Comment(L"-w with a positive number should result in us trying"
- L" to either make a new one or find an existing one "
- L"with that ID, depending on the provided argument");
-
- std::vector args{ L"wt.exe", L"-w", L"12345" };
- auto result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseNew);
- VERIFY_ARE_EQUAL(12345, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseExisting);
- VERIFY_ARE_EQUAL(12345, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseAnyExisting);
- VERIFY_ARE_EQUAL(12345, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
- }
- {
- Log::Comment(L"-w 0 should always use the \"current\" window");
-
- std::vector args{ L"wt.exe", L"-w", L"0" };
- auto result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseNew);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseCurrent, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseCurrent, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseAnyExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseCurrent, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
- }
- {
- Log::Comment(L"-w last should always use the most recent window on "
- L"this desktop");
-
- std::vector args{ L"wt.exe", L"-w", L"last" };
- auto result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseNew);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseExisting, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseExisting, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseAnyExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseExisting, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
- }
- {
- Log::Comment(L"Make sure we follow the provided argument when a "
- L"--window-id wasn't explicitly provided");
-
- std::vector args{ L"wt.exe", L"new-tab" };
- auto result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseNew);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseExisting, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseAnyExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseAnyExisting, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
- }
- {
- Log::Comment(L"Even if someone uses a subcommand as a window name, "
- L"that should work");
-
- std::vector args{ L"wt.exe", L"-w", L"new-tab" };
- auto result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseNew);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseName, result.WindowId());
- VERIFY_ARE_EQUAL(L"new-tab", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseName, result.WindowId());
- VERIFY_ARE_EQUAL(L"new-tab", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseAnyExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseName, result.WindowId());
- VERIFY_ARE_EQUAL(L"new-tab", result.WindowName());
- }
- }
-
- void CommandlineTest::TestFindTargetWindowHelp()
- {
- Log::Comment(L"--help should always create a new window");
-
- // This is a little helper to make sure that these args _always_ return
- // UseNew, regardless of the windowing behavior.
- auto testHelper = [](auto&& args) {
- auto result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseNew);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseAnyExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
- };
-
- testHelper(std::vector{ L"wt.exe", L"--help" });
- testHelper(std::vector{ L"wt.exe", L"new-tab", L"--help" });
- testHelper(std::vector{ L"wt.exe", L"-w", L"0", L"new-tab", L"--help" });
- testHelper(std::vector{ L"wt.exe", L"-w", L"foo", L"new-tab", L"--help" });
- testHelper(std::vector{ L"wt.exe", L"new-tab", L";", L"--help" });
- }
-
- void CommandlineTest::TestFindTargetWindowVersion()
- {
- Log::Comment(L"--version should always create a new window");
-
- // This is a little helper to make sure that these args _always_ return
- // UseNew, regardless of the windowing behavior.
- auto testHelper = [](auto&& args) {
- auto result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseNew);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
-
- result = appImpl::AppLogic::_doFindTargetWindow({ args }, WindowingMode::UseAnyExisting);
- VERIFY_ARE_EQUAL(WindowingBehaviorUseNew, result.WindowId());
- VERIFY_ARE_EQUAL(L"", result.WindowName());
- };
-
- testHelper(std::vector{ L"wt.exe", L"--version" });
- }
}
diff --git a/src/cascadia/LocalTests_TerminalApp/TabTests.cpp b/src/cascadia/LocalTests_TerminalApp/TabTests.cpp
index d21497a51d..477e6dcf0e 100644
--- a/src/cascadia/LocalTests_TerminalApp/TabTests.cpp
+++ b/src/cascadia/LocalTests_TerminalApp/TabTests.cpp
@@ -1288,12 +1288,6 @@ namespace TerminalAppLocalTests
END_TEST_METHOD_PROPERTIES()
auto page = _commonSetup();
- page->RenameWindowRequested([&page](auto&&, auto&&) {
- // In the real terminal, this would bounce up to the monarch and
- // come back down. Instead, immediately call back to tell the terminal it failed.
- page->RenameFailed();
- });
-
auto windowNameChanged = false;
page->PropertyChanged([&page, &windowNameChanged](auto&&, const winrt::WUX::Data::PropertyChangedEventArgs& args) mutable {
diff --git a/src/cascadia/Remoting/CommandlineArgs.cpp b/src/cascadia/Remoting/CommandlineArgs.cpp
deleted file mode 100644
index db76316932..0000000000
--- a/src/cascadia/Remoting/CommandlineArgs.cpp
+++ /dev/null
@@ -1,25 +0,0 @@
-#include "pch.h"
-
-#include "CommandlineArgs.h"
-#include "CommandlineArgs.g.cpp"
-using namespace winrt;
-using namespace winrt::Microsoft::Terminal;
-using namespace winrt::Windows::Foundation;
-
-namespace winrt::Microsoft::Terminal::Remoting::implementation
-{
- // LOAD BEARING CODE
- // If you try to move this into the header, you will experience P A I N
- // It must be defined after CommandlineArgs.g.cpp, otherwise the compiler
- // will give you just the most impossible template errors to try and
- // decipher.
- void CommandlineArgs::Commandline(const winrt::array_view& value)
- {
- _args = { value.begin(), value.end() };
- }
-
- winrt::com_array CommandlineArgs::Commandline()
- {
- return winrt::com_array{ _args.begin(), _args.end() };
- }
-}
diff --git a/src/cascadia/Remoting/CommandlineArgs.h b/src/cascadia/Remoting/CommandlineArgs.h
deleted file mode 100644
index 2f618e53ef..0000000000
--- a/src/cascadia/Remoting/CommandlineArgs.h
+++ /dev/null
@@ -1,46 +0,0 @@
-#pragma once
-
-#include "CommandlineArgs.g.h"
-
-namespace winrt::Microsoft::Terminal::Remoting::implementation
-{
- struct CommandlineArgs : public CommandlineArgsT
- {
- public:
- CommandlineArgs() :
- _args{},
- _cwd{ L"" }
- {
- }
-
- CommandlineArgs(const winrt::array_view& args,
- winrt::hstring currentDirectory,
- const uint32_t showWindowCommand,
- winrt::hstring envString) :
- _args{ args.begin(), args.end() },
- _cwd{ currentDirectory },
- _ShowWindowCommand{ showWindowCommand },
- CurrentEnvironment{ envString }
- {
- }
-
- winrt::hstring CurrentDirectory() { return _cwd; };
-
- void Commandline(const winrt::array_view& value);
- winrt::com_array Commandline();
-
- til::property CurrentEnvironment;
-
- WINRT_PROPERTY(uint32_t, ShowWindowCommand, SW_NORMAL); // SW_NORMAL is 1, 0 is SW_HIDE
-
- private:
- winrt::com_array _args;
- winrt::hstring _cwd;
- };
-
-}
-
-namespace winrt::Microsoft::Terminal::Remoting::factory_implementation
-{
- BASIC_FACTORY(CommandlineArgs);
-}
diff --git a/src/cascadia/Remoting/FindTargetWindowArgs.cpp b/src/cascadia/Remoting/FindTargetWindowArgs.cpp
deleted file mode 100644
index 1781c1c9c1..0000000000
--- a/src/cascadia/Remoting/FindTargetWindowArgs.cpp
+++ /dev/null
@@ -1,5 +0,0 @@
-// Copyright (c) Microsoft Corporation.
-// Licensed under the MIT license.
-#include "pch.h"
-#include "FindTargetWindowArgs.h"
-#include "FindTargetWindowArgs.g.cpp"
diff --git a/src/cascadia/Remoting/FindTargetWindowArgs.h b/src/cascadia/Remoting/FindTargetWindowArgs.h
deleted file mode 100644
index b6dfc7638f..0000000000
--- a/src/cascadia/Remoting/FindTargetWindowArgs.h
+++ /dev/null
@@ -1,35 +0,0 @@
-/*++
-Copyright (c) Microsoft Corporation
-Licensed under the MIT license.
-
-Class Name:
-- FindTargetWindowArgs.h
-
-Abstract:
-- This is a helper class for determining which window a specific commandline is
- intended for. The Monarch will create one of these, then toss it over to
- TerminalApp. TerminalApp actually contains the logic for parsing a
- commandline, as well as settings like the windowing behavior. Once the
- TerminalApp determines the correct window, it'll fill in the
- ResultTargetWindow property. The monarch will then read that value out to
- invoke the commandline in the appropriate window.
-
---*/
-
-#pragma once
-
-#include "FindTargetWindowArgs.g.h"
-
-namespace winrt::Microsoft::Terminal::Remoting::implementation
-{
- struct FindTargetWindowArgs : public FindTargetWindowArgsT
- {
- WINRT_PROPERTY(winrt::Microsoft::Terminal::Remoting::CommandlineArgs, Args, nullptr);
- WINRT_PROPERTY(int, ResultTargetWindow, -1);
- WINRT_PROPERTY(winrt::hstring, ResultTargetWindowName);
-
- public:
- FindTargetWindowArgs(winrt::Microsoft::Terminal::Remoting::CommandlineArgs args) :
- _Args{ args } {};
- };
-}
diff --git a/src/cascadia/Remoting/Microsoft.Terminal.RemotingLib.vcxproj b/src/cascadia/Remoting/Microsoft.Terminal.RemotingLib.vcxproj
deleted file mode 100644
index b5c7ada479..0000000000
--- a/src/cascadia/Remoting/Microsoft.Terminal.RemotingLib.vcxproj
+++ /dev/null
@@ -1,135 +0,0 @@
-
-
-
- {43ce4ce5-0010-4b99-9569-672670d26e26}
- Win32Proj
- Microsoft.Terminal.Remoting.Lib
- Microsoft.Terminal.Remoting
- Microsoft.Terminal.Remoting.Lib
- StaticLibrary
- Console
- true
- true
-
-
-
-
-
-
-
- Monarch.idl
-
-
- Monarch.idl
-
-
- Monarch.idl
-
-
- Monarch.idl
-
-
- Peasant.idl
-
-
- Peasant.idl
-
-
- Peasant.idl
-
-
-
-
- Peasant.idl
-
-
- WindowManager.idl
-
-
- Peasant.idl
-
-
-
-
-
- Monarch.idl
-
-
- Monarch.idl
-
-
- Monarch.idl
-
-
- Monarch.idl
-
-
- Peasant.idl
-
-
- Peasant.idl
-
-
- Peasant.idl
-
-
- Create
-
-
- Peasant.idl
-
-
- WindowManager.idl
-
-
- Peasant.idl
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- {CA5CAD1A-039A-4929-BA2A-8BEB2E4106FE}
- false
-
-
-
-
-
-
- pch.h
-
-
- WindowsApp.lib;user32.lib;shell32.lib;%(AdditionalDependencies)
-
-
- false
-
-
-
-
-
-
-
-
-
diff --git a/src/cascadia/Remoting/Monarch.cpp b/src/cascadia/Remoting/Monarch.cpp
deleted file mode 100644
index b986bfc863..0000000000
--- a/src/cascadia/Remoting/Monarch.cpp
+++ /dev/null
@@ -1,1114 +0,0 @@
-// Copyright (c) Microsoft Corporation.
-// Licensed under the MIT license.
-
-#include "pch.h"
-#include "../inc/WindowingBehavior.h"
-#include "Monarch.h"
-#include "CommandlineArgs.h"
-#include "FindTargetWindowArgs.h"
-#include "ProposeCommandlineResult.h"
-
-#include "Monarch.g.cpp"
-#include "WindowRequestedArgs.g.cpp"
-#include "../../types/inc/utils.hpp"
-
-using namespace winrt;
-using namespace winrt::Microsoft::Terminal;
-using namespace winrt::Windows::Foundation;
-using namespace ::Microsoft::Console;
-
-namespace winrt::Microsoft::Terminal::Remoting::implementation
-{
- Monarch::Monarch() :
- _ourPID{ GetCurrentProcessId() }
- {
- try
- {
- _desktopManager = winrt::create_instance(__uuidof(VirtualDesktopManager));
- }
- CATCH_LOG();
- }
-
- // This constructor is intended to be used in unit tests,
- // but we need to make it public in order to use make_self
- // in the tests. It's not exposed through the idl though
- // so it's not _truly_ fully public which should be acceptable.
- Monarch::Monarch(const uint64_t testPID) :
- _ourPID{ testPID }
- {
- }
-
- Monarch::~Monarch() = default;
-
- uint64_t Monarch::GetPID()
- {
- return _ourPID;
- }
-
- // Method Description:
- // - Add the given peasant to the list of peasants we're tracking. This
- // Peasant may have already been assigned an ID. If it hasn't, then give
- // it an ID.
- // - NB: this takes a unique_lock on _peasantsMutex.
- // Arguments:
- // - peasant: the new Peasant to track.
- // Return Value:
- // - the ID assigned to the peasant.
- uint64_t Monarch::AddPeasant(Remoting::IPeasant peasant)
- {
- try
- {
- // TODO:projects/5 This is terrible. There's gotta be a better way
- // of finding the first opening in a non-consecutive map of int->object
- const auto providedID = peasant.GetID();
-
- if (providedID == 0)
- {
- // Peasant doesn't currently have an ID. Assign it a new one.
- peasant.AssignID(_nextPeasantID++);
- }
- else
- {
- // Peasant already had an ID (from an older monarch). Leave that one
- // be. Make sure that the next peasant's ID is higher than it.
- // If multiple peasants are added concurrently we keep trying to update
- // until we get to set the new id.
- uint64_t current;
- do
- {
- current = _nextPeasantID.load(std::memory_order_relaxed);
- } while (current <= providedID && !_nextPeasantID.compare_exchange_weak(current, providedID + 1, std::memory_order_relaxed));
- }
-
- auto newPeasantsId = peasant.GetID();
-
- // Keep track of which peasant we are
- // SAFETY: this is only true for one peasant, and each peasant
- // is only added to a monarch once, so we do not need synchronization here.
- if (peasant.GetPID() == _ourPID)
- {
- _ourPeasantId = newPeasantsId;
- }
- // Add an event listener to the peasant's WindowActivated event.
- peasant.WindowActivated({ this, &Monarch::_peasantWindowActivated });
- peasant.IdentifyWindowsRequested({ this, &Monarch::_identifyWindows });
- peasant.RenameRequested({ this, &Monarch::_renameRequested });
-
- peasant.ShowNotificationIconRequested([this](auto&&, auto&&) { ShowNotificationIconRequested.raise(*this, nullptr); });
- peasant.HideNotificationIconRequested([this](auto&&, auto&&) { HideNotificationIconRequested.raise(*this, nullptr); });
-
- {
- std::unique_lock lock{ _peasantsMutex };
- _peasants[newPeasantsId] = peasant;
- }
-
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_AddPeasant",
- TraceLoggingUInt64(providedID, "providedID", "the provided ID for the peasant"),
- TraceLoggingUInt64(newPeasantsId, "peasantID", "the ID of the new peasant"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
-
- WindowCreated.raise(nullptr, nullptr);
- return newPeasantsId;
- }
- catch (...)
- {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_AddPeasant_Failed",
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
-
- // We can only get into this try/catch if the peasant died on us. So
- // the return value doesn't _really_ matter. They're not about to
- // get it.
- return -1;
- }
- }
-
- // Method Description:
- // - Gives the host process an opportunity to run any pre-close logic then
- // requests all peasants to close.
- // Arguments:
- // - used
- // Return Value:
- // -
- void Monarch::QuitAll()
- {
- if (_quitting.exchange(true, std::memory_order_relaxed))
- {
- return;
- }
-
- const auto callback = [&](const auto& id, const auto& p) {
- // We want to tell our peasant to quit last, so that we don't try
- // to perform a bunch of elections on quit.
- if (id != _ourPeasantId)
- {
- p.Quit();
- }
- };
- const auto onError = [&](const auto& id) {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_handleQuitAll_Failed",
- TraceLoggingInt64(id, "peasantID", "The ID of the peasant which we could not close"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- };
-
- _forEachPeasant(callback, onError);
-
- {
- std::shared_lock lock{ _peasantsMutex };
- const auto peasantSearch = _peasants.find(_ourPeasantId);
- if (peasantSearch != _peasants.end())
- {
- peasantSearch->second.Quit();
- }
- }
- }
-
- // Method Description:
- // - Tells the monarch that a peasant is being closed.
- // - NB: this (separately) takes unique locks on _peasantsMutex and
- // _mruPeasantsMutex.
- // Arguments:
- // - peasantId: the id of the peasant
- // Return Value:
- // -
- void Monarch::SignalClose(const uint64_t peasantId)
- {
- // If we are quitting we don't care about maintaining our list of
- // peasants anymore, and don't need to notify the host that something
- // changed.
- if (_quitting.load(std::memory_order_relaxed))
- {
- return;
- }
-
- _clearOldMruEntries({ peasantId });
- {
- std::unique_lock lock{ _peasantsMutex };
- _peasants.erase(peasantId);
- }
- WindowClosed.raise(nullptr, nullptr);
- }
-
- // Method Description:
- // - Counts the number of living peasants.
- // Arguments:
- // -
- // Return Value:
- // - the number of active peasants.
- uint64_t Monarch::GetNumberOfPeasants()
- {
- std::shared_lock lock{ _peasantsMutex };
- return _peasants.size();
- }
-
- // Method Description:
- // - Event handler for the Peasant::WindowActivated event. Used as an
- // opportunity for us to update our internal stack of the "most recent
- // window".
- // Arguments:
- // - sender: the Peasant that raised this event. This might be out-of-proc!
- // - args: a bundle of the peasant ID, timestamp, and desktop ID, for the activated peasant
- // Return Value:
- // -
- void Monarch::_peasantWindowActivated(const winrt::Windows::Foundation::IInspectable& /*sender*/,
- const Remoting::WindowActivatedArgs& args)
- {
- HandleActivatePeasant(args);
- }
-
- // Method Description:
- // - Lookup a peasant by its ID. If the peasant has died, this will also
- // remove the peasant from our list of peasants.
- // - NB: this (separately) takes unique locks on _peasantsMutex and
- // _mruPeasantsMutex.
- // Arguments:
- // - peasantID: The ID Of the peasant to find
- // - clearMruPeasantOnFailure: When true this function will handle clearing
- // from _mruPeasants if a peasant was not found, otherwise the caller is
- // expected to handle that cleanup themselves.
- // Return Value:
- // - the peasant if it exists in our map, otherwise null
- Remoting::IPeasant Monarch::_getPeasant(uint64_t peasantID, bool clearMruPeasantOnFailure)
- {
- try
- {
- IPeasant maybeThePeasant = nullptr;
- {
- std::shared_lock lock{ _peasantsMutex };
- const auto peasantSearch = _peasants.find(peasantID);
- maybeThePeasant = peasantSearch == _peasants.end() ? nullptr : peasantSearch->second;
- }
- // Ask the peasant for their PID. This will validate that they're
- // actually still alive.
- if (maybeThePeasant)
- {
- maybeThePeasant.GetPID();
- }
- return maybeThePeasant;
- }
- catch (...)
- {
- LOG_CAUGHT_EXCEPTION();
-
- // Remove the peasant from the list of peasants
- {
- std::unique_lock lock{ _peasantsMutex };
- _peasants.erase(peasantID);
- }
-
- if (clearMruPeasantOnFailure)
- {
- // Remove the peasant from the list of MRU windows. They're dead.
- // They can't be the MRU anymore.
- _clearOldMruEntries({ peasantID });
- }
- return nullptr;
- }
- }
-
- // Method Description:
- // - Find the ID of the peasant with the given name. If no such peasant
- // exists, then we'll return 0. If we encounter any peasants who have died
- // during this process, then we'll remove them from the set of _peasants
- // Arguments:
- // - name: The window name to look for
- // Return Value:
- // - 0 if we didn't find the given peasant, otherwise a positive number for
- // the window's ID.
- uint64_t Monarch::_lookupPeasantIdForName(std::wstring_view name)
- {
- if (name.empty())
- {
- return 0;
- }
- if (name == L"new")
- {
- return 0;
- }
-
- uint64_t result = 0;
-
- const auto callback = [&](const auto& id, const auto& p) {
- auto otherName = p.WindowName();
- if (otherName == name)
- {
- result = id;
- return false;
- }
- return true;
- };
-
- const auto onError = [&](const auto& id) {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_lookupPeasantIdForName_Failed",
- TraceLoggingInt64(id, "peasantID", "The ID of the peasant which we could not get the name of"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- };
-
- _forEachPeasant(callback, onError);
-
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_lookupPeasantIdForName",
- TraceLoggingWideString(std::wstring{ name }.c_str(), "name", "the name we're looking for"),
- TraceLoggingUInt64(result, "peasantID", "the ID of the peasant with that name"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- return result;
- }
-
- // Method Description:
- // - Handler for the `Peasant::WindowActivated` event. We'll make a in-proc
- // copy of the WindowActivatedArgs from the peasant. That way, we won't
- // need to worry about the origin process dying when working with the
- // WindowActivatedArgs.
- // - If the peasant process dies while we're making this copy, then we'll
- // just log it and do nothing. We certainly don't want to track a dead
- // peasant.
- // - We'll pass that copy of the WindowActivatedArgs to
- // _doHandleActivatePeasant, which will actually insert the
- // WindowActivatedArgs into the list we're using to track the most recent
- // peasants.
- // Arguments:
- // - args: the WindowActivatedArgs describing when and where the peasant was activated.
- // Return Value:
- // -
- void Monarch::HandleActivatePeasant(const Remoting::WindowActivatedArgs& args)
- {
- if (args == nullptr)
- {
- // MSFT:35731327, GH #12624. There's a chance that the way the
- // window gets set up for defterm, the ActivatedArgs haven't been
- // created for this window yet. Check here and just ignore them if
- // they're null. They'll come back with real args soon
- return;
- }
- // Start by making a local copy of these args. It's easier for us if our
- // tracking of these args is all in-proc. That way, the only thing that
- // could fail due to the peasant dying is _this first copy_.
- winrt::com_ptr localArgs{ nullptr };
- try
- {
- localArgs = winrt::make_self(args);
- // This method will actually do the hard work
- _doHandleActivatePeasant(localArgs);
- }
- catch (...)
- {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_HandleActivatePeasant_Failed",
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- }
- }
-
- // Method Description:
- // - Helper for removing a peasant from the list of MRU peasants. We want to
- // do this both when the peasant dies, and also when the peasant is newly
- // activated (so that we don't leave an old entry for it in the list).
- // - NB: This takes a unique lock on _mruPeasantsMutex.
- // Arguments:
- // - peasantIds: The list of peasant IDs to remove from the MRU list
- // Return Value:
- // -
- void Monarch::_clearOldMruEntries(const std::unordered_set& peasantIds)
- {
- if (peasantIds.size() == 0)
- {
- return;
- }
-
- std::unique_lock lock{ _mruPeasantsMutex };
- auto partition = std::remove_if(_mruPeasants.begin(), _mruPeasants.end(), [&](const auto& p) {
- const auto id = p.PeasantID();
- // remove the element if it was found in the list to erase.
- if (peasantIds.count(id) == 1)
- {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_RemovedPeasantFromDesktop",
- TraceLoggingUInt64(id, "peasantID", "The ID of the peasant"),
- TraceLoggingGuid(p.DesktopID(), "desktopGuid", "The GUID of the previous desktop the window was on"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- return true;
- }
- return false;
- });
-
- // Remove everything that was in the list
- _mruPeasants.erase(partition, _mruPeasants.end());
- }
-
- // Method Description:
- // - Actually handle inserting the WindowActivatedArgs into our list of MRU windows.
- // - NB: this takes a unique_lock on _mruPeasantsMutex.
- // Arguments:
- // - localArgs: an in-proc WindowActivatedArgs that we should add to our list of MRU windows.
- // Return Value:
- // -
- void Monarch::_doHandleActivatePeasant(const winrt::com_ptr& localArgs)
- {
- // We're sure that localArgs isn't null here, we checked before in our
- // one caller (in Monarch::HandleActivatePeasant)
-
- const auto newLastActiveTime = localArgs->ActivatedTime().time_since_epoch().count();
-
- // * Check all the current lists to look for this peasant.
- // remove it from any where it exists.
- _clearOldMruEntries({ localArgs->PeasantID() });
-
- // * If the current desktop doesn't have a vector, add one.
- const auto desktopGuid{ localArgs->DesktopID() };
-
- {
- std::unique_lock lock{ _mruPeasantsMutex };
- // * Add this args list. By using lower_bound with insert, we can get it
- // into exactly the right spot, without having to re-sort the whole
- // array.
- _mruPeasants.insert(std::lower_bound(_mruPeasants.begin(),
- _mruPeasants.end(),
- *localArgs,
- [](const auto& first, const auto& second) { return first.ActivatedTime() > second.ActivatedTime(); }),
- *localArgs);
- }
-
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_SetMostRecentPeasant",
- TraceLoggingUInt64(localArgs->PeasantID(), "peasantID", "the ID of the activated peasant"),
- TraceLoggingGuid(desktopGuid, "desktopGuid", "The GUID of the desktop the window is on"),
- TraceLoggingInt64(newLastActiveTime, "newLastActiveTime", "The provided localArgs->ActivatedTime()"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- }
-
- // Method Description:
- // - Retrieves the ID of the MRU peasant window. If requested, will limit
- // the search to windows that are on the current desktop.
- // - NB: This method will hold a shared lock on _mruPeasantsMutex and
- // potentially a unique_lock on _peasantsMutex at the same time.
- // Separately it might hold a unique_lock on _mruPeasantsMutex.
- // Arguments:
- // - limitToCurrentDesktop: if true, only return the MRU peasant that's
- // actually on the current desktop.
- // - ignoreQuakeWindow: if true, then don't return the _quake window when we
- // find it. This allows us to change our behavior for glomming vs
- // summoning. When summoning the window, this parameter should be true.
- // When glomming, this should be false, as to prevent glomming to the
- // _quake window.
- // Return Value:
- // - the ID of the most recent peasant, otherwise 0 if we could not find one.
- uint64_t Monarch::_getMostRecentPeasantID(const bool limitToCurrentDesktop, const bool ignoreQuakeWindow)
- {
- std::shared_lock lock{ _mruPeasantsMutex };
- if (_mruPeasants.empty())
- {
- // unlock the mruPeasants mutex to make sure we can't deadlock here.
- lock.unlock();
- // Only need a shared lock for read
- std::shared_lock peasantsLock{ _peasantsMutex };
- // We haven't yet been told the MRU peasant. Just use the first one.
- // This is just gonna be a random one, but really shouldn't happen
- // in practice. The WindowManager should set the MRU peasant
- // immediately as soon as it creates the monarch/peasant for the
- // first window.
- if (_peasants.size() > 0)
- {
- try
- {
- return _peasants.begin()->second.GetID();
- }
- catch (...)
- {
- // This shouldn't really happen. If we're the monarch, then the
- // first peasant should also _be us_. So we should be able to
- // get our own ID.
- return 0;
- }
- }
-
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_getMostRecentPeasantID_NoPeasants",
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- return 0;
- }
-
- // Here, there's at least one MRU peasant.
- //
- // We're going to iterate over these peasants until we find one that both:
- // 1. Is alive
- // 2. Meets our selection criteria (do we care if it is on this desktop?)
- //
- // If the peasant is dead, then we'll remove it, and try the next one.
- // Once we find one that's alive, we'll either:
- // * check if we only want a peasant on the current desktop, and if so,
- // check if this peasant is on the current desktop.
- // - If it isn't on the current desktop, we'll loop again, on the
- // following peasant.
- // * If we don't care, then we'll just return that one.
- uint64_t result = 0;
- std::unordered_set peasantsToErase{};
- for (const auto& mruWindowArgs : _mruPeasants)
- {
- // Try to get the peasant, but do not have _getPeasant clean up old
- // _mruPeasants because we are iterating here.
- // SAFETY: _getPeasant can take a unique_lock on _peasantsMutex if
- // it detects a peasant is dead. Currently _getMostRecentPeasantId
- // is the only method that holds a lock on both _mruPeasantsMutex and
- // _peasantsMutex at the same time so there cannot be a deadlock here.
- const auto peasant{ _getPeasant(mruWindowArgs.PeasantID(), false) };
- if (!peasant)
- {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_Collect_WasDead",
- TraceLoggingUInt64(mruWindowArgs.PeasantID(),
- "peasantID",
- "We thought this peasant was the MRU one, but it was actually already dead."),
- TraceLoggingGuid(mruWindowArgs.DesktopID(), "desktopGuid", "The GUID of the desktop the window is on"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- // We'll go through the loop again. We removed the current one
- // at positionInList, so the next one in positionInList will be
- // a new, different peasant.
- peasantsToErase.emplace(mruWindowArgs.PeasantID());
- continue;
- }
-
- if (ignoreQuakeWindow && peasant.WindowName() == QuakeWindowName)
- {
- // The _quake window should never be treated as the MRU window.
- // Skip it if we see it. Users can still target it with `wt -w
- // _quake`, which will hit `_lookupPeasantIdForName` instead.
- }
- else if (limitToCurrentDesktop && _desktopManager)
- {
- // Check if this peasant is actually on this desktop. We can't
- // simply get the GUID of the current desktop. We have to ask if
- // the HWND is on the current desktop.
- BOOL onCurrentDesktop{ false };
-
- // SUCCEEDED_LOG will log if it failed, and return true if it SUCCEEDED
- if (SUCCEEDED_LOG(_desktopManager->IsWindowOnCurrentVirtualDesktop(reinterpret_cast(mruWindowArgs.Hwnd()),
- &onCurrentDesktop)) &&
- onCurrentDesktop)
- {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_Collect",
- TraceLoggingUInt64(mruWindowArgs.PeasantID(),
- "peasantID",
- "the ID of the MRU peasant for a desktop"),
- TraceLoggingGuid(mruWindowArgs.DesktopID(),
- "desktopGuid",
- "The GUID of the desktop the window is on"),
- TraceLoggingBoolean(limitToCurrentDesktop,
- "limitToCurrentDesktop",
- "True if we should only search for a window on the current desktop"),
- TraceLoggingBool(onCurrentDesktop,
- "onCurrentDesktop",
- "true if this window was in fact on the current desktop"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- result = mruWindowArgs.PeasantID();
- break;
- }
- // If this window wasn't on the current desktop, another one
- // might be. We'll increment positionInList below, and try
- // again.
- }
- else
- {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_getMostRecentPeasantID_Found",
- TraceLoggingUInt64(mruWindowArgs.PeasantID(), "peasantID", "The ID of the MRU peasant"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
-
- result = mruWindowArgs.PeasantID();
- break;
- }
- }
-
- lock.unlock();
-
- if (peasantsToErase.size() > 0)
- {
- _clearOldMruEntries(peasantsToErase);
- }
-
- if (result == 0)
- {
- // Here, we've checked all the windows, and none of them was both alive
- // and the most recent (on this desktop). Just return 0 - the caller
- // will use this to create a new window.
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_getMostRecentPeasantID_NotFound",
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- }
-
- return result;
- }
-
- // Method Description:
- // - Try to handle a commandline from a new WT invocation. We might need to
- // hand the commandline to an existing window, or we might need to tell
- // the caller that they need to become a new window to handle it themselves.
- // Arguments:
- // -
- // Return Value:
- // - true if the caller should create a new window for this commandline.
- // False otherwise - the monarch should have dispatched this commandline
- // to another window in this case.
- Remoting::ProposeCommandlineResult Monarch::ProposeCommandline(const Remoting::CommandlineArgs& args)
- {
- // Raise an event, to ask how to handle this commandline. We can't ask
- // the app ourselves - we exist isolated from that knowledge (and
- // dependency hell). The WindowManager will raise this up to the app
- // host, which will then ask the AppLogic, who will then parse the
- // commandline and determine the provided ID of the window.
- auto findWindowArgs{ winrt::make_self(args) };
-
- // This is handled by some handler in-proc
- FindTargetWindowRequested.raise(*this, *findWindowArgs);
-
- // After the event was handled, ResultTargetWindow() will be filled with
- // the parsed result.
- const auto targetWindow = findWindowArgs->ResultTargetWindow();
- const auto targetWindowName = findWindowArgs->ResultTargetWindowName();
-
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_ProposeCommandline",
- TraceLoggingInt64(targetWindow, "targetWindow", "The window ID the args specified"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
-
- if (targetWindow == WindowingBehaviorUseNone)
- {
- // In this case, the targetWindow was UseNone, which means that we
- // want to make a message box, but otherwise not make a Terminal
- // window.
- return winrt::make(false);
- }
- // If there's a valid ID returned, then let's try and find the peasant
- // that goes with it. Alternatively, if we were given a magic windowing
- // constant, we can use that to look up an appropriate peasant.
- if (targetWindow >= 0 ||
- targetWindow == WindowingBehaviorUseName ||
- targetWindow == WindowingBehaviorUseExisting ||
- targetWindow == WindowingBehaviorUseAnyExisting)
- {
- uint64_t windowID = 0;
- switch (targetWindow)
- {
- case WindowingBehaviorUseCurrent:
- case WindowingBehaviorUseExisting:
- // TODO:projects/5 for now, just use the MRU window. Technically,
- // UseExisting and UseCurrent are different.
- // UseCurrent implies that we should try to do the WT_SESSION
- // lookup to find the window that spawned this process (then
- // fall back to sameDesktop if we can't find a match). For now,
- // it's good enough to just try to find a match on this desktop.
- //
- // GH#projects/5#card-60325142 - Don't try to glom to the quake window.
- windowID = _getMostRecentPeasantID(true, true);
- break;
- case WindowingBehaviorUseAnyExisting:
- windowID = _getMostRecentPeasantID(false, true);
- break;
- case WindowingBehaviorUseName:
- windowID = _lookupPeasantIdForName(targetWindowName);
- break;
- case WindowingBehaviorUseNone:
- // This should be impossible. The if statement above should have
- // prevented WindowingBehaviorUseNone from falling in here.
- // Explode, because this is a programming error.
- THROW_HR(E_UNEXPECTED);
- default:
- windowID = ::base::saturated_cast(targetWindow);
- break;
- }
-
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_ProposeCommandline",
- TraceLoggingInt64(windowID,
- "windowID",
- "The actual peasant ID we evaluated the window ID as"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
-
- // If_getMostRecentPeasantID returns 0 above, then we couldn't find
- // a matching window for that style of windowing. _getPeasant will
- // return nullptr, and we'll fall through to the "create a new
- // window" branch below.
-
- if (auto targetPeasant{ _getPeasant(windowID) })
- {
- auto result{ winrt::make_self(false) };
- try
- {
- // This will raise the peasant's ExecuteCommandlineRequested
- // event, which will then ask the AppHost to handle the
- // commandline, which will then pass it to AppLogic for
- // handling.
- targetPeasant.ExecuteCommandline(args);
- }
- catch (...)
- {
- // If we fail to propose the commandline to the peasant (it
- // died?) then just tell this process to become a new window
- // instead.
- result->WindowName(targetWindowName);
- result->ShouldCreateWindow(true);
-
- RequestNewWindow.raise(*this, *winrt::make_self(*result, args));
-
- // If this fails, it'll be logged in the following
- // TraceLoggingWrite statement, with succeeded=false
- }
-
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_ProposeCommandline_Existing",
- TraceLoggingUInt64(windowID,
- "peasantID",
- "the ID of the peasant the commandline waws intended for"),
- TraceLoggingBoolean(true, "foundMatch", "true if we found a peasant with that ID"),
- TraceLoggingBoolean(!result->ShouldCreateWindow(),
- "succeeded",
- "true if we successfully dispatched the commandline to the peasant"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- return *result;
- }
- else if (windowID > 0)
- {
- // In this case, an ID was provided, but there's no
- // peasant with that ID. Instead, we should tell the caller that
- // they should make a new window, but _with that ID_.
-
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_ProposeCommandline_Existing",
- TraceLoggingUInt64(windowID,
- "peasantID",
- "the ID of the peasant the commandline waws intended for"),
- TraceLoggingBoolean(false, "foundMatch", "true if we found a peasant with that ID"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
-
- auto result{ winrt::make_self(true) };
- result->Id(windowID);
- result->WindowName(targetWindowName);
-
- RequestNewWindow.raise(*this, *winrt::make_self(*result, args));
-
- return *result;
- }
- }
-
- // If we get here, we couldn't find an existing window. Make a new one.
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_ProposeCommandline_NewWindow",
- TraceLoggingInt64(targetWindow, "targetWindow", "The provided ID"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
-
- // In this case, no usable ID was provided. Return { true, nullopt }
- auto result = winrt::make_self(true);
- result->WindowName(targetWindowName);
-
- RequestNewWindow.raise(*this, *winrt::make_self(*result, args));
-
- return *result;
- }
-
- // Method Description:
- // - This is an event handler for the IdentifyWindowsRequested event. A
- // Peasant may raise that event if they want _all_ windows to identify
- // themselves.
- // - This will tell each and every peasant to identify themselves. This will
- // eventually propagate down to TerminalPage::IdentifyWindow.
- // Arguments:
- // -
- // Return Value:
- // -
- void Monarch::_identifyWindows(const winrt::Windows::Foundation::IInspectable& /*sender*/,
- const winrt::Windows::Foundation::IInspectable& /*args*/)
- {
- // Notify all the peasants to display their ID.
- const auto callback = [&](const auto& /*id*/, const auto& p) {
- p.DisplayWindowId();
- };
- const auto onError = [&](const auto& id) {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_identifyWindows_Failed",
- TraceLoggingInt64(id, "peasantID", "The ID of the peasant which we could not identify"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- };
-
- _forEachPeasant(callback, onError);
- }
-
- // Method Description:
- // - This is an event handler for the RenameRequested event. A
- // Peasant may raise that event when they want to be renamed to something else.
- // - We will check if there are any other windows with this name. If there
- // are, then we'll reject the rename by setting args.Succeeded=false.
- // - If there aren't any other windows with this name, then we'll set
- // args.Succeeded=true, allowing the window to keep this name.
- // Arguments:
- // - args: Contains the requested window name and a boolean (Succeeded)
- // indicating if the request was successful.
- // Return Value:
- // -
- void Monarch::_renameRequested(const winrt::Windows::Foundation::IInspectable& /*sender*/,
- const winrt::Microsoft::Terminal::Remoting::RenameRequestArgs& args)
- {
- auto successfullyRenamed = false;
-
- try
- {
- args.Succeeded(false);
- const auto name{ args.NewName() };
- // Try to find a peasant that currently has this name
- const auto id = _lookupPeasantIdForName(name);
- if (_getPeasant(id) == nullptr)
- {
- // If there is one, then oh no! The requestor is not allowed to
- // be renamed.
- args.Succeeded(true);
- successfullyRenamed = true;
- }
-
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_renameRequested",
- TraceLoggingWideString(name.c_str(), "name", "The newly proposed name"),
- TraceLoggingInt64(successfullyRenamed, "successfullyRenamed", "true if the peasant is allowed to rename themselves to that name."),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- }
- catch (...)
- {
- LOG_CAUGHT_EXCEPTION();
- // If this fails, we don't _really_ care. The peasant died, but
- // they're the only one who cares about the result.
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_renameRequested_Failed",
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- }
- }
-
- // Method Description:
- // - Attempt to summon a window. `args` contains information about which
- // window we should try to summon:
- // * if a WindowName is provided, we'll try to find a window with exactly
- // that name, and fail if there isn't one.
- // - Calls Peasant::Summon on the matching peasant (which might be an RPC call)
- // - This should only ever be called by the WindowManager in the monarch
- // process itself. The monarch is the one registering for global hotkeys,
- // so it's the one calling this method.
- // Arguments:
- // - args: contains information about the window that should be summoned.
- // Return Value:
- // -
- // - Sets args.FoundMatch when a window matching args is found successfully.
- void Monarch::SummonWindow(const Remoting::SummonWindowSelectionArgs& args)
- {
- const auto searchedForName{ args.WindowName() };
- try
- {
- args.FoundMatch(false);
-
- // If a WindowID is provided from the args, use that first.
- uint64_t windowId = 0;
- if (args.WindowID())
- {
- windowId = args.WindowID().Value();
- }
- else
- {
- // If no name was provided, then just summon the MRU window.
- if (searchedForName.empty())
- {
- // Use the value of the `desktop` arg to determine if we should
- // limit to the current desktop (desktop:onCurrent) or not
- // (desktop:any or desktop:toCurrent)
- windowId = _getMostRecentPeasantID(args.OnCurrentDesktop(), false);
- }
- else
- {
- // Try to find a peasant that currently has this name
- windowId = _lookupPeasantIdForName(searchedForName);
- }
- }
-
- if (auto targetPeasant{ _getPeasant(windowId) })
- {
- targetPeasant.Summon(args.SummonBehavior());
- args.FoundMatch(true);
-
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_SummonWindow_Success",
- TraceLoggingWideString(searchedForName.c_str(), "searchedForName", "The name of the window we tried to summon"),
- TraceLoggingUInt64(windowId, "peasantID", "The id of the window we tried to summon"),
- TraceLoggingBoolean(args.OnCurrentDesktop(), "OnCurrentDesktop", "true iff the window needs to be on the current virtual desktop"),
- TraceLoggingBoolean(args.SummonBehavior().MoveToCurrentDesktop(), "MoveToCurrentDesktop", "if true, move the window to the current virtual desktop"),
- TraceLoggingBoolean(args.SummonBehavior().ToggleVisibility(), "ToggleVisibility", "true if we should toggle the visibility of the window"),
- TraceLoggingUInt32(args.SummonBehavior().DropdownDuration(), "DropdownDuration", "the duration to dropdown the window"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- }
- else
- {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_SummonWindow_NoPeasant",
- TraceLoggingWideString(searchedForName.c_str(), "searchedForName", "The name of the window we tried to summon"),
- TraceLoggingUInt64(windowId, "peasantID", "The id of the window we tried to summon"),
- TraceLoggingBoolean(args.OnCurrentDesktop(), "OnCurrentDesktop", "true iff the window needs to be on the current virtual desktop"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- }
- }
- catch (...)
- {
- LOG_CAUGHT_EXCEPTION();
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_SummonWindow_Failed",
- TraceLoggingWideString(searchedForName.c_str(), "searchedForName", "The name of the window we tried to summon"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- }
- }
-
- // Method Description:
- // - This method creates a map of peasant IDs to peasant names
- // while removing dead peasants.
- // Arguments:
- // -
- // Return Value:
- // - A map of peasant IDs to their names.
- Windows::Foundation::Collections::IVectorView Monarch::GetPeasantInfos()
- {
- std::vector names;
- {
- std::shared_lock lock{ _peasantsMutex };
- names.reserve(_peasants.size());
- }
-
- const auto func = [&](const auto& id, const auto& p) -> void {
- names.push_back({ id, p.WindowName(), p.ActiveTabTitle() });
- };
-
- const auto onError = [&](const auto& id) {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_identifyWindows_Failed",
- TraceLoggingInt64(id, "peasantID", "The ID of the peasant which we could not identify"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- };
-
- _forEachPeasant(func, onError);
-
- return winrt::single_threaded_vector(std::move(names)).GetView();
- }
-
- bool Monarch::DoesQuakeWindowExist()
- {
- auto result = false;
- const auto func = [&](const auto& /*id*/, const auto& p) {
- if (p.WindowName() == QuakeWindowName)
- {
- result = true;
- }
- // continue if we didn't get a positive result
- return !result;
- };
-
- const auto onError = [&](const auto& id) {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_DoesQuakeWindowExist_Failed",
- TraceLoggingInt64(id, "peasantID", "The ID of the peasant which we could not ask for its name"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- };
-
- _forEachPeasant(func, onError);
- return result;
- }
-
- void Monarch::SummonAllWindows()
- {
- const auto func = [&](const auto& /*id*/, const auto& p) {
- SummonWindowBehavior args{};
- args.ToggleVisibility(false);
- p.Summon(args);
- };
-
- const auto onError = [&](const auto& id) {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_SummonAll_Failed",
- TraceLoggingInt64(id, "peasantID", "The ID of the peasant which we could not summon"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- };
-
- _forEachPeasant(func, onError);
- }
-
- void Monarch::RequestMoveContent(winrt::hstring window,
- winrt::hstring content,
- uint32_t tabIndex,
- const Windows::Foundation::IReference& windowBounds)
- {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_MoveContent_Requested",
- TraceLoggingWideString(window.c_str(), "window", "The name of the window we tried to move to"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
-
- uint64_t windowId = _lookupPeasantIdForName(window);
- if (windowId == 0)
- {
- // Try the name as an integer ID
- uint32_t temp;
- if (!Utils::StringToUint(window.c_str(), temp))
- {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_MoveContent_FailedToParseId",
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- }
- else
- {
- windowId = temp;
- }
- }
-
- if (auto targetPeasant{ _getPeasant(windowId) })
- {
- auto request = winrt::make_self(content, tabIndex);
- targetPeasant.AttachContentToWindow(*request);
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_MoveContent_Completed",
- TraceLoggingInt64(windowId, "windowId", "The ID of the peasant which we sent the content to"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- }
- else
- {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_MoveContent_NoWindow",
- TraceLoggingInt64(windowId, "windowId", "We could not find a peasant with this ID"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
-
- // In the case where window couldn't be found, then create a window
- // for that name / ID.
- //
- // Don't let the window literally be named "-1", because that's silly. Same with "new"
- const bool nameIsReserved = window == L"-1" || window == L"new";
- auto request = winrt::make_self(nameIsReserved ? L"" : window,
- content,
- windowBounds);
- RequestNewWindow.raise(*this, *request);
- }
- }
-
- // Very similar to the above. Someone came and told us that they were the target of a drag/drop, and they know who started it.
- // We will go tell the person who started it that they should send that target the content which was dragged.
- void Monarch::RequestSendContent(const Remoting::RequestReceiveContentArgs& args)
- {
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_SendContent_Requested",
- TraceLoggingUInt64(args.SourceWindow(), "source", "The window which started the drag"),
- TraceLoggingUInt64(args.TargetWindow(), "target", "The window which was the target of the drop"),
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
-
- if (auto senderPeasant{ _getPeasant(args.SourceWindow()) })
- {
- senderPeasant.SendContent(args);
-
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_SendContent_Completed",
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- }
- else
- {
- // We couldn't find the peasant that started the drag. Well that
- // sure is weird, but that would indicate that the sender closed
- // after starting the drag. No matter. We can just do nothing.
-
- TraceLoggingWrite(g_hRemotingProvider,
- "Monarch_SendContent_NoWindow",
- TraceLoggingLevel(WINEVENT_LEVEL_VERBOSE),
- TraceLoggingKeyword(TIL_KEYWORD_TRACE));
- }
- }
-}
diff --git a/src/cascadia/Remoting/Monarch.h b/src/cascadia/Remoting/Monarch.h
deleted file mode 100644
index 4cc74d0c5b..0000000000
--- a/src/cascadia/Remoting/Monarch.h
+++ /dev/null
@@ -1,237 +0,0 @@
-// Copyright (c) Microsoft Corporation.
-// Licensed under the MIT license.
-
-#pragma once
-
-#include "Monarch.g.h"
-#include "Peasant.h"
-#include "WindowActivatedArgs.h"
-#include "WindowRequestedArgs.g.h"
-#include
-
-// We sure different GUIDs here depending on whether we're running a Release,
-// Preview, or Dev build. This ensures that different installs don't
-// accidentally talk to one another.
-//
-// * Release: {06171993-7eb1-4f3e-85f5-8bdd7386cce3}
-// * Preview: {04221993-7eb1-4f3e-85f5-8bdd7386cce3}
-// * Canary: {09222022-7eb1-4f3e-85f5-8bdd7386cce3}
-// * Dev: {08302020-7eb1-4f3e-85f5-8bdd7386cce3}
-constexpr GUID Monarch_clsid
-{
-#if defined(WT_BRANDING_RELEASE)
- 0x06171993,
-#elif defined(WT_BRANDING_PREVIEW)
- 0x04221993,
-#elif defined(WT_BRANDING_CANARY)
- 0x09222022,
-#else
- 0x08302020,
-#endif
- 0x7eb1,
- 0x4f3e,
- {
- 0x85, 0xf5, 0x8b, 0xdd, 0x73, 0x86, 0xcc, 0xe4
- }
-};
-
-namespace RemotingUnitTests
-{
- class RemotingTests;
-};
-
-namespace winrt::Microsoft::Terminal::Remoting::implementation
-{
- struct WindowRequestedArgs : public WindowRequestedArgsT
- {
- public:
- WindowRequestedArgs(const Remoting::ProposeCommandlineResult& windowInfo, const Remoting::CommandlineArgs& command) :
- _Id{ windowInfo.Id() ? windowInfo.Id().Value() : 0 }, // We'll use 0 as a sentinel, since no window will ever get to have that ID
- _WindowName{ windowInfo.WindowName() },
- _args{ command.Commandline() },
- _CurrentDirectory{ command.CurrentDirectory() },
- _ShowWindowCommand{ command.ShowWindowCommand() },
- _CurrentEnvironment{ command.CurrentEnvironment() } {};
-
- WindowRequestedArgs(const winrt::hstring& window, const winrt::hstring& content, const Windows::Foundation::IReference& bounds) :
- _Id{ 0u },
- _WindowName{ window },
- _args{},
- _CurrentDirectory{},
- _Content{ content },
- _InitialBounds{ bounds } {};
-
- void Commandline(const winrt::array_view& value) { _args = { value.begin(), value.end() }; };
- winrt::com_array Commandline() { return winrt::com_array{ _args.begin(), _args.end() }; }
-
- WINRT_PROPERTY(uint64_t, Id);
- WINRT_PROPERTY(winrt::hstring, WindowName);
- WINRT_PROPERTY(winrt::hstring, CurrentDirectory);
- WINRT_PROPERTY(winrt::hstring, Content);
- WINRT_PROPERTY(uint32_t, ShowWindowCommand, SW_NORMAL);
- WINRT_PROPERTY(winrt::hstring, CurrentEnvironment);
- WINRT_PROPERTY(Windows::Foundation::IReference, InitialBounds);
-
- private:
- winrt::com_array _args;
- };
-
- struct Monarch : public MonarchT
- {
- Monarch();
- Monarch(const uint64_t testPID);
- ~Monarch();
-
- uint64_t GetPID();
-
- uint64_t AddPeasant(winrt::Microsoft::Terminal::Remoting::IPeasant peasant);
- void SignalClose(const uint64_t peasantId);
- void QuitAll();
-
- uint64_t GetNumberOfPeasants();
-
- winrt::Microsoft::Terminal::Remoting::ProposeCommandlineResult ProposeCommandline(const winrt::Microsoft::Terminal::Remoting::CommandlineArgs& args);
- void HandleActivatePeasant(const winrt::Microsoft::Terminal::Remoting::WindowActivatedArgs& args);
- void SummonWindow(const Remoting::SummonWindowSelectionArgs& args);
-
- void SummonAllWindows();
- bool DoesQuakeWindowExist();
- Windows::Foundation::Collections::IVectorView GetPeasantInfos();
-
- void RequestMoveContent(winrt::hstring window, winrt::hstring content, uint32_t tabIndex, const Windows::Foundation::IReference& windowBounds);
- void RequestSendContent(const Remoting::RequestReceiveContentArgs& args);
-
- til::typed_event FindTargetWindowRequested;
- til::typed_event<> ShowNotificationIconRequested;
- til::typed_event<> HideNotificationIconRequested;
- til::typed_event<> WindowCreated;
- til::typed_event<> WindowClosed;
-
- til::typed_event RequestNewWindow;
-
- private:
- uint64_t _ourPID;
-
- std::atomic _nextPeasantID{ 1 };
- uint64_t _ourPeasantId{ 0 };
-
- // When we're quitting we do not care as much about handling some events that we know will be triggered
- std::atomic _quitting{ false };
-
- winrt::com_ptr _desktopManager{ nullptr };
-
- std::unordered_map _peasants;
- std::vector _mruPeasants;
- // These should not be locked at the same time to prevent deadlocks
- // unless they are both shared_locks.
- std::shared_mutex _peasantsMutex{};
- std::shared_mutex _mruPeasantsMutex{};
-
- winrt::Microsoft::Terminal::Remoting::IPeasant _getPeasant(uint64_t peasantID, bool clearMruPeasantOnFailure = true);
- uint64_t _getMostRecentPeasantID(bool limitToCurrentDesktop, const bool ignoreQuakeWindow);
- uint64_t _lookupPeasantIdForName(std::wstring_view name);
-
- void _peasantWindowActivated(const winrt::Windows::Foundation::IInspectable& sender,
- const winrt::Microsoft::Terminal::Remoting::WindowActivatedArgs& args);
- void _doHandleActivatePeasant(const winrt::com_ptr& args);
- void _clearOldMruEntries(const std::unordered_set& peasantIds);
-
- void _forAllPeasantsIgnoringTheDead(std::function callback,
- std::function errorCallback);
-
- void _identifyWindows(const winrt::Windows::Foundation::IInspectable& sender,
- const winrt::Windows::Foundation::IInspectable& args);
-
- void _renameRequested(const winrt::Windows::Foundation::IInspectable& sender,
- const winrt::Microsoft::Terminal::Remoting::RenameRequestArgs& args);
-
- void _handleQuitAll(const winrt::Windows::Foundation::IInspectable& sender,
- const winrt::Windows::Foundation::IInspectable& args);
-
- // Method Description:
- // - Helper for doing something on each and every peasant.
- // - We'll try calling func on every peasant.
- // - If the return type of func is void, it will perform it for all peasants.
- // - If the return type is a boolean, we'll break out of the loop once func
- // returns false.
- // - If any single peasant is dead, then we'll call onError and then add it to a
- // list of peasants to clean up once the loop ends.
- // - NB: this (separately) takes unique locks on _peasantsMutex and
- // _mruPeasantsMutex.
- // Arguments:
- // - func: The function to call on each peasant
- // - onError: The function to call if a peasant is dead.
- // Return Value:
- // -
- template
- void _forEachPeasant(F&& func, T&& onError)
- {
- using Map = decltype(_peasants);
- using R = std::invoke_result_t;
- static constexpr auto IsVoid = std::is_void_v;
-
- std::unordered_set peasantsToErase;
- {
- std::shared_lock lock{ _peasantsMutex };
-
- for (const auto& [id, p] : _peasants)
- {
- try
- {
- if constexpr (IsVoid)
- {
- func(id, p);
- }
- else
- {
- if (!func(id, p))
- {
- break;
- }
- }
- }
- catch (const winrt::hresult_error& exception)
- {
- onError(id);
-
- if (exception.code() == 0x800706ba) // The RPC server is unavailable.
- {
- peasantsToErase.emplace(id);
- }
- else
- {
- LOG_CAUGHT_EXCEPTION();
- throw;
- }
- }
- }
- }
-
- if (peasantsToErase.size() > 0)
- {
- // Don't hold a lock on _peasants and _mruPeasants at the same
- // time to avoid deadlocks.
- {
- std::unique_lock lock{ _peasantsMutex };
- for (const auto& id : peasantsToErase)
- {
- _peasants.erase(id);
- }
- }
- _clearOldMruEntries(peasantsToErase);
-
- // A peasant died, let the app host know that the number of
- // windows has changed.
- WindowClosed.raise(nullptr, nullptr);
- }
- }
-
- friend class RemotingUnitTests::RemotingTests;
- };
-}
-
-namespace winrt::Microsoft::Terminal::Remoting::factory_implementation
-{
- BASIC_FACTORY(Monarch);
- BASIC_FACTORY(WindowRequestedArgs);
-}
diff --git a/src/cascadia/Remoting/Monarch.idl b/src/cascadia/Remoting/Monarch.idl
deleted file mode 100644
index ba00cf47cf..0000000000
--- a/src/cascadia/Remoting/Monarch.idl
+++ /dev/null
@@ -1,88 +0,0 @@
-// Copyright (c) Microsoft Corporation.
-// Licensed under the MIT license.
-
-import "Peasant.idl";
-
-namespace Microsoft.Terminal.Remoting
-{
-
- [default_interface] runtimeclass FindTargetWindowArgs {
- CommandlineArgs Args { get; };
- Int32 ResultTargetWindow;
- String ResultTargetWindowName;
- }
-
- [default_interface] runtimeclass ProposeCommandlineResult {
- Windows.Foundation.IReference Id { get; };
- String WindowName { get; };
- Boolean ShouldCreateWindow { get; }; // If you name this `CreateWindow`, the compiler will explode
- }
-
- [default_interface] runtimeclass WindowRequestedArgs {
- WindowRequestedArgs(ProposeCommandlineResult windowInfo, CommandlineArgs command);
-
- UInt64 Id { get; };
- String WindowName { get; };
-
- String[] Commandline { get; };
- String CurrentDirectory { get; };
- UInt32 ShowWindowCommand { get; };
- String CurrentEnvironment { get; };
-
- String Content { get; };
- Windows.Foundation.IReference InitialBounds { get; };
- }
-
- [default_interface] runtimeclass SummonWindowSelectionArgs {
- SummonWindowSelectionArgs();
- SummonWindowSelectionArgs(String windowName);
- String WindowName;
- Boolean OnCurrentDesktop;
- // TODO GH#8888 Other options:
- // * CurrentMonitor
-
- Boolean FoundMatch;
- SummonWindowBehavior SummonBehavior;
- Windows.Foundation.IReference WindowID;
- }
-
- struct PeasantInfo
- {
- UInt64 Id;
- String Name;
- String TabTitle;
- };
-
- interface IMonarch
- {
-
- UInt64 GetPID();
- UInt64 AddPeasant(IPeasant peasant);
- UInt64 GetNumberOfPeasants();
- ProposeCommandlineResult ProposeCommandline(CommandlineArgs args);
- void HandleActivatePeasant(WindowActivatedArgs args);
- void SummonWindow(SummonWindowSelectionArgs args);
- void SignalClose(UInt64 peasantId);
- void QuitAll();
-
- void SummonAllWindows();
- Boolean DoesQuakeWindowExist();
- Windows.Foundation.Collections.IVectorView GetPeasantInfos { get; };
-
- void RequestMoveContent(String window, String content, UInt32 tabIndex, Windows.Foundation.IReference bounds);
- void RequestSendContent(RequestReceiveContentArgs args);
-
- event Windows.Foundation.TypedEventHandler