diff --git a/src/cascadia/CascadiaPackage/Package-Can.appxmanifest b/src/cascadia/CascadiaPackage/Package-Can.appxmanifest
index 66564e799ff..164ce0bca43 100644
--- a/src/cascadia/CascadiaPackage/Package-Can.appxmanifest
+++ b/src/cascadia/CascadiaPackage/Package-Can.appxmanifest
@@ -40,6 +40,7 @@
+
@@ -93,7 +94,7 @@
Description="Console host built from microsoft/terminal open source repository"
PublicFolder="Public">
- {1F9F2BF5-5BC3-4F17-B0E6-912413F1F451}
+ {A854D02A-F2FE-44A5-BB24-D03F4CF830D4}
@@ -104,7 +105,7 @@
Description="Terminal host built from microsoft/terminal open source repository"
PublicFolder="Public">
- {051F34EE-C1FD-4B19-AF75-9BA54648434C}
+ {1706609C-A4CE-4C0D-B7D2-C19BF66398A5}
diff --git a/src/cascadia/CascadiaPackage/Package-Dev.appxmanifest b/src/cascadia/CascadiaPackage/Package-Dev.appxmanifest
index d8ceefaeef6..53fc49c7833 100644
--- a/src/cascadia/CascadiaPackage/Package-Dev.appxmanifest
+++ b/src/cascadia/CascadiaPackage/Package-Dev.appxmanifest
@@ -39,6 +39,7 @@
+
diff --git a/src/cascadia/CascadiaPackage/Package-Pre.appxmanifest b/src/cascadia/CascadiaPackage/Package-Pre.appxmanifest
index 3a7bf26e0f7..c7956c34576 100644
--- a/src/cascadia/CascadiaPackage/Package-Pre.appxmanifest
+++ b/src/cascadia/CascadiaPackage/Package-Pre.appxmanifest
@@ -40,6 +40,7 @@
+
diff --git a/src/cascadia/CascadiaPackage/Package.appxmanifest b/src/cascadia/CascadiaPackage/Package.appxmanifest
index f04863da27c..98c10c860a0 100644
--- a/src/cascadia/CascadiaPackage/Package.appxmanifest
+++ b/src/cascadia/CascadiaPackage/Package.appxmanifest
@@ -40,6 +40,7 @@
+
diff --git a/src/common.build.pre.props b/src/common.build.pre.props
index a1cf37adbda..17d4b603927 100644
--- a/src/common.build.pre.props
+++ b/src/common.build.pre.props
@@ -131,8 +131,12 @@
C26456: Operator 'A' hides a non-virtual operator 'B' (c.128)
I think these rules are for when you fully bought into OOP?
We didn't and it breaks WRL and large parts of conhost code.
+ C26478: Don't use std::move on constant variables. (es.56).
+ This diagnostic is broken in VS 17.7 which our CI currently uses. It's fixed in 17.8.
+ C26494: Variable 'index' is uninitialized. Always initialize an object (type. 5).
+ This diagnostic is broken in VS 17.7 which our CI currently uses. It's fixed in 17.8.
-->
- 4201;4312;4467;5105;26434;26445;26456;%(DisableSpecificWarnings)
+ 4201;4312;4467;5105;26434;26445;26456;26478;26494;%(DisableSpecificWarnings)
_WINDOWS;EXTERNAL_BUILD;_SILENCE_STDEXT_ARR_ITERS_DEPRECATION_WARNING;%(PreprocessorDefinitions)
true
precomp.h
diff --git a/src/renderer/dx/DxFontInfo.cpp b/src/renderer/dx/DxFontInfo.cpp
index b1d4844a601..b0f79cde39a 100644
--- a/src/renderer/dx/DxFontInfo.cpp
+++ b/src/renderer/dx/DxFontInfo.cpp
@@ -126,44 +126,52 @@ void DxFontInfo::SetFromEngine(const std::wstring_view familyName,
try
{
face = _FindFontFace(localeName);
+ }
+ CATCH_LOG();
- if (!face)
+ if constexpr (Feature_NearbyFontLoading::IsEnabled())
+ {
+ try
{
- // If we missed, try looking a little more by trimming the last word off the requested family name a few times.
- // Quite often, folks are specifying weights or something in the familyName and it causes failed resolution and
- // an unexpected error dialog. We theoretically could detect the weight words and convert them, but this
- // is the quick fix for the majority scenario.
- // The long/full fix is backlogged to GH#9744
- // Also this doesn't count as a fallback because we don't want to annoy folks with the warning dialog over
- // this resolution.
- while (!face && !_familyName.empty())
+ if (!face)
{
- const auto lastSpace = _familyName.find_last_of(UNICODE_SPACE);
-
- // value is unsigned and npos will be greater than size.
- // if we didn't find anything to trim, leave.
- if (lastSpace >= _familyName.size())
- {
- break;
- }
-
- // trim string down to just before the found space
- // (space found at 6... trim from 0 for 6 length will give us 0-5 as the new string)
- _familyName = _familyName.substr(0, lastSpace);
-
- // Try to find it with the shortened family name
+ _fontCollection = FontCache::GetCached();
face = _FindFontFace(localeName);
}
}
+ CATCH_LOG();
}
- CATCH_LOG();
- if constexpr (Feature_NearbyFontLoading::IsEnabled())
+ if (!face)
{
- if (!face)
+ // If we missed, try looking a little more by trimming the last word off the requested family name a few times.
+ // Quite often, folks are specifying weights or something in the familyName and it causes failed resolution and
+ // an unexpected error dialog. We theoretically could detect the weight words and convert them, but this
+ // is the quick fix for the majority scenario.
+ // The long/full fix is backlogged to GH#9744
+ // Also this doesn't count as a fallback because we don't want to annoy folks with the warning dialog over
+ // this resolution.
+ while (!face && !_familyName.empty())
{
- _fontCollection = FontCache::GetCached();
- face = _FindFontFace(localeName);
+ const auto lastSpace = _familyName.find_last_of(UNICODE_SPACE);
+
+ // value is unsigned and npos will be greater than size.
+ // if we didn't find anything to trim, leave.
+ if (lastSpace >= _familyName.size())
+ {
+ break;
+ }
+
+ // trim string down to just before the found space
+ // (space found at 6... trim from 0 for 6 length will give us 0-5 as the new string)
+ _familyName = _familyName.substr(0, lastSpace);
+
+ try
+ {
+ // Try to find it with the shortened family name
+ face = _FindFontFace(localeName);
+ }
+ CATCH_LOG();
}
}
@@ -176,7 +184,12 @@ void DxFontInfo::SetFromEngine(const std::wstring_view familyName,
{
_familyName = fallbackFace;
- face = _FindFontFace(localeName);
+ try
+ {
+ face = _FindFontFace(localeName);
+ }
+ CATCH_LOG();
+
if (face)
{
_didFallback = true;