Repository: microsoft/terminal (language: cpp)

Issue:
A very long title causes only half of the progress ring to be visible
<!-- 
🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨

I ACKNOWLEDGE THE FOLLOWING BEFORE PROCEEDING:
1. If I delete this entire template and go my own path, the core team may close my issue without further explanation or engagement.
2. If I list multiple bugs/concerns in this one issue, the core team may close my issue without further explanation or engagement.
3. If I write an issue that has many duplicates, the core team may close my issue without further explanation or engagement (and without necessarily spending time to find the exact duplicate ID number).
4. If I leave the title incomplete when filing the issue, the core team may close my issue without further explanation or engagement.
5. If I file something completely blank in the body, the core team may close my issue without further explanation or engagement.

All good? Then proceed!
-->

<!--
This bug tracker is monitored by Windows Terminal development team and other technical folks.

**Important: When reporting BSODs or security issues, DO NOT attach memory dumps, logs, or traces to Github issues**.
Instead, send dumps/traces to secure@microsoft.com, referencing this GitHub issue.

If this is an application crash, please also provide a Feedback Hub submission link so we can find your diagnostic data on the backend. Use the category "Apps > Windows Terminal (Preview)" and choose "Share My Feedback" after submission to get the link.

Please use this form and describe your issue, concisely but precisely, with as much detail as possible.

-->

# Environment

```none
Windows build number: [run `[Environment]::OSVersion` for powershell, or `ver` for cmd] 19042
Windows Terminal version (if applicable): 1.6 preview

Any other software?
```

# Steps to reproduce

<!-- A description of how to trigger this bug. -->

I was trying the `bcz.cmd` and found only half of the progress ring is shown.

Here's my profile:

```json
            {
                "name" : "Developer Command Prompt for VS 2019",
                "commandline" : "cmd.exe /k \"C:/\"Program Files (x86)\"/\"Microsoft Visual Studio\"/2019/Enterprise/Common7/Tools/VsDevCmd.bat\"",
                "startingDirectory" : "%USERPROFILE%",
                "colorScheme": "Chalk"
            }
```

# Expected behavior

<!-- A description of what you're expecting, possibly containing screenshots or reference material. -->

The ring. The whole ring. The HALO.

# Actual behavior

![image](https://user-images.githubusercontent.com/4710575/105975152-9803a200-60c9-11eb-97d2-9e08b534aa84.png)

<!-- What's actually happening? -->

<hr>

I'm only seeing this in the VS cmd profile. All other profiles work fine:


![image](https://user-images.githubusercontent.com/4710575/105976002-9ab2c700-60ca-11eb-9846-e330db7dd872.png)



Discussion / hints:
Okay, I'm testing this out. It doesn't look like it's the fallback icon that causes this. I think it's the title length. If you set the tab title to something really long, like `Developer Command Prompt A really really really long title`, then it seems to push the spinner halfway into oblivion.

That's real bizarre, because there's definitely space for it, but the tab view is still cropping it. Weird. 

Fix patch:
diff --git a/src/cascadia/TerminalApp/TabHeaderControl.xaml b/src/cascadia/TerminalApp/TabHeaderControl.xaml
index abfd7e5a254..80889eabb8c 100644
--- a/src/cascadia/TerminalApp/TabHeaderControl.xaml
+++ b/src/cascadia/TerminalApp/TabHeaderControl.xaml
@@ -20,16 +20,11 @@
                           Height="15"
                           MinWidth="0"
                           MinHeight="0"
-                          Margin="-7.5,0,8,0"
+                          Margin="3,0,8,0"
                           IsActive="{x:Bind TabStatus.IsProgressRingActive, Mode=OneWay}"
                           IsIndeterminate="{x:Bind TabStatus.IsProgressRingIndeterminate, Mode=OneWay}"
                           Visibility="{x:Bind TabStatus.IsProgressRingActive, Mode=OneWay}"
                           Value="{x:Bind TabStatus.ProgressValue, Mode=OneWay}" />
-        <!--
-            We want the progress ring to 'replace' the tab icon, but we don't have control
-            over the tab icon here (the tab view item does) - so we hide the tab icon there
-            and use a negative margin for the progress ring here to put it where the icon would be
-        -->
         <FontIcon x:Name="HeaderBellIndicator"
                   Margin="0,0,8,0"
                   FontFamily="{ThemeResource SymbolThemeFontFamily}"
diff --git a/src/cascadia/TerminalApp/TerminalTab.cpp b/src/cascadia/TerminalApp/TerminalTab.cpp
index 292ae7c410f..8cd4ae86acd 100644
--- a/src/cascadia/TerminalApp/TerminalTab.cpp
+++ b/src/cascadia/TerminalApp/TerminalTab.cpp
@@ -15,6 +15,7 @@ using namespace winrt::Windows::UI::Xaml;
 using namespace winrt::Windows::UI::Core;
 using namespace winrt::Microsoft::Terminal::Control;
 using namespace winrt::Microsoft::Terminal::Settings::Model;
+using namespace winrt::Microsoft::UI::Xaml::Controls;
 using namespace winrt::Windows::System;
 
 namespace winrt
@@ -316,7 +317,7 @@ namespace winrt::TerminalApp::implementation
                 if (hide)
                 {
                     Icon({});
-                    TabViewItem().IconSource(IconPathConverter::IconSourceMUX({}));
+                    TabViewItem().IconSource(IconSource{ nullptr });
                 }
                 else
                 {


Test patch: