The Windows App SDK empowers all Windows desktop apps with modern Windows UI, APIs, and platform features, including back-compat support, shipped via NuGet.
I have a clean install of windows 10 18363. I found out my svg image used in a toast notification will fail to render (only showing a background color but not the shape) when it is shown the first time. This is extremely bothering.
Successive notification will show up correctly as expected.
Steps to reproduce the bug
Create a new packaged winui3 C++ project
In the button handler, use this code
void MainWindow::myButton_Click(IInspectable const&, RoutedEventArgs const&)
{
winrt::Windows::Data::Xml::Dom::XmlDocument doc;
doc.LoadXml(LR"(
<toast launch="action=viewFriendRequest&userId=49183">
<visual>
<binding template="ToastGeneric">
<text>Matt sent you a friend request</text>
<text>Hey, wanna dress up as wizards and ride around on our hoverboards together?</text>
<image placement="appLogoOverride" hint-crop="circle" src="ms-appx:///Assets/mi-icon-success.svg"/>
</binding>
</visual>
<actions>
<action content="Accept" activationType="background" arguments="action=acceptFriendRequest&userId=49183"/>
<action content="Decline" activationType="background" arguments="action=declineFriendRequest&userId=49183"/>
</actions>
</toast>
)");
winrt::Windows::UI::Notifications::ToastNotification notification{doc};
winrt::Windows::UI::Notifications::ToastNotificationManager::CreateToastNotifier()
.Show(
notification
);
}
Describe the bug
I have a clean install of windows 10 18363. I found out my svg image used in a toast notification will fail to render (only showing a background color but not the shape) when it is shown the first time. This is extremely bothering. Successive notification will show up correctly as expected.
Steps to reproduce the bug
In the button handler, use this code
The svg I am using:
Expected behavior
No response
Screenshots
https://github.com/user-attachments/assets/5bc9d157-b7f8-4f52-b94f-4c1e3623c91c
NuGet package version
Windows App SDK 1.5.5: 1.5.240627000
Packaging type
Packaged (MSIX)
Windows version
Windows 10 version 1909 (18363, November 2019 Update)
IDE
Visual Studio 2022
Additional context
No response