diff --git a/src/AddIns/Uno.WinUI.Graphics2DSK/SKCanvasElement.cs b/src/AddIns/Uno.WinUI.Graphics2DSK/SKCanvasElement.cs index 5a35f636bda6..6ef25d3b601e 100644 --- a/src/AddIns/Uno.WinUI.Graphics2DSK/SKCanvasElement.cs +++ b/src/AddIns/Uno.WinUI.Graphics2DSK/SKCanvasElement.cs @@ -12,7 +12,7 @@ namespace Uno.WinUI.Graphics2DSK; /// This is only available on skia-based targets. public abstract class SKCanvasElement : FrameworkElement { - private protected override ShapeVisual CreateElementVisual() => new SKCanvasVisual(this, Compositor.GetSharedCompositor()); + private protected override ContainerVisual CreateElementVisual() => new SKCanvasVisual(this, Compositor.GetSharedCompositor()); /// /// Queue a rendering cycle that will call . @@ -30,7 +30,7 @@ public abstract class SKCanvasElement : FrameworkElement /// protected abstract void RenderOverride(SKCanvas canvas, Size area); - private class SKCanvasVisual(SKCanvasElement owner, Compositor compositor) : ShapeVisual(compositor) + private class SKCanvasVisual(SKCanvasElement owner, Compositor compositor) : ContainerVisual(compositor) { internal override void Paint(in PaintingSession session) { diff --git a/src/SamplesApp/SamplesApp.Windows/GlobalUsings.cs b/src/SamplesApp/SamplesApp.Windows/GlobalUsings.cs index 33219314662b..bf0942f4a277 100644 --- a/src/SamplesApp/SamplesApp.Windows/GlobalUsings.cs +++ b/src/SamplesApp/SamplesApp.Windows/GlobalUsings.cs @@ -1,2 +1,4 @@ global using Microsoft.UI; global using Microsoft.UI.Text; +global using Colors = Microsoft.UI.Colors; +global using FontWeights = Microsoft.UI.Text.FontWeights; diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_1.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_1.png new file mode 100644 index 000000000000..7e176be7b796 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_1.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_10.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_10.png new file mode 100644 index 000000000000..d8b0530a7e1a Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_10.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_100.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_100.png new file mode 100644 index 000000000000..d48cb1ac36bf Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_100.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_101.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_101.png new file mode 100644 index 000000000000..daea1cffaf4f Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_101.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_102.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_102.png new file mode 100644 index 000000000000..5bc1aad5a82c Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_102.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_103.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_103.png new file mode 100644 index 000000000000..7e176be7b796 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_103.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_104.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_104.png new file mode 100644 index 000000000000..f899be32f252 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_104.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_105.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_105.png new file mode 100644 index 000000000000..0ed10315a4bf Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_105.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_106.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_106.png new file mode 100644 index 000000000000..8e27fb9f93a8 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_106.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_107.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_107.png new file mode 100644 index 000000000000..860dc8e27e2d Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_107.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_108.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_108.png new file mode 100644 index 000000000000..0698f088ae0b Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_108.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_109.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_109.png new file mode 100644 index 000000000000..59609932fbb7 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_109.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_11.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_11.png new file mode 100644 index 000000000000..a4f30cb4e866 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_11.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_110.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_110.png new file mode 100644 index 000000000000..e85fa2230ebd Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_110.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_111.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_111.png new file mode 100644 index 000000000000..df2d9fe0e87f Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_111.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_112.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_112.png new file mode 100644 index 000000000000..f3f14a0f107d Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_112.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_113.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_113.png new file mode 100644 index 000000000000..d48cb1ac36bf Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_113.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_114.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_114.png new file mode 100644 index 000000000000..43956eaffd04 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_114.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_115.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_115.png new file mode 100644 index 000000000000..9ac687bd7e84 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_115.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_116.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_116.png new file mode 100644 index 000000000000..7e176be7b796 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_116.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_117.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_117.png new file mode 100644 index 000000000000..ed018c6e5787 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_117.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_118.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_118.png new file mode 100644 index 000000000000..96127eedddec Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_118.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_119.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_119.png new file mode 100644 index 000000000000..8e27fb9f93a8 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_119.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_12.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_12.png new file mode 100644 index 000000000000..91fcbc380dbd Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_12.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_120.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_120.png new file mode 100644 index 000000000000..bfb5296b6ee5 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_120.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_121.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_121.png new file mode 100644 index 000000000000..730e37a69f4e Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_121.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_122.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_122.png new file mode 100644 index 000000000000..c36e43ac5584 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_122.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_123.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_123.png new file mode 100644 index 000000000000..e85fa2230ebd Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_123.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_124.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_124.png new file mode 100644 index 000000000000..e3ce36eae246 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_124.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_125.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_125.png new file mode 100644 index 000000000000..73caa1403d7c Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_125.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_126.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_126.png new file mode 100644 index 000000000000..d48cb1ac36bf Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_126.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_127.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_127.png new file mode 100644 index 000000000000..be348a163cd3 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_127.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_128.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_128.png new file mode 100644 index 000000000000..2a4203cf57db Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_128.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_129.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_129.png new file mode 100644 index 000000000000..7e176be7b796 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_129.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_13.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_13.png new file mode 100644 index 000000000000..9ac687bd7e84 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_13.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_130.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_130.png new file mode 100644 index 000000000000..a5fe57b7958c Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_130.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_131.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_131.png new file mode 100644 index 000000000000..aa8eeeec230d Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_131.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_132.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_132.png new file mode 100644 index 000000000000..8e27fb9f93a8 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_132.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_133.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_133.png new file mode 100644 index 000000000000..a6c55e4dcf34 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_133.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_134.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_134.png new file mode 100644 index 000000000000..730e37a69f4e Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_134.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_135.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_135.png new file mode 100644 index 000000000000..59609932fbb7 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_135.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_136.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_136.png new file mode 100644 index 000000000000..b9e1fe572f9a Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_136.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_137.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_137.png new file mode 100644 index 000000000000..e3ce36eae246 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_137.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_138.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_138.png new file mode 100644 index 000000000000..f3f14a0f107d Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_138.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_139.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_139.png new file mode 100644 index 000000000000..9c84ff969da2 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_139.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_14.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_14.png new file mode 100644 index 000000000000..7e176be7b796 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_14.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_140.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_140.png new file mode 100644 index 000000000000..be348a163cd3 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_140.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_141.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_141.png new file mode 100644 index 000000000000..9ac687bd7e84 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_141.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_142.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_142.png new file mode 100644 index 000000000000..9f0a1366dd67 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_142.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_143.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_143.png new file mode 100644 index 000000000000..a5fe57b7958c Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_143.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_144.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_144.png new file mode 100644 index 000000000000..96127eedddec Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_144.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_15.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_15.png new file mode 100644 index 000000000000..ed018c6e5787 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_15.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_16.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_16.png new file mode 100644 index 000000000000..96127eedddec Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_16.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_17.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_17.png new file mode 100644 index 000000000000..8e27fb9f93a8 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_17.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_18.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_18.png new file mode 100644 index 000000000000..bfb5296b6ee5 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_18.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_19.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_19.png new file mode 100644 index 000000000000..2654dc4cc0ee Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_19.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_2.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_2.png new file mode 100644 index 000000000000..f899be32f252 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_2.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_20.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_20.png new file mode 100644 index 000000000000..61607efce299 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_20.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_21.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_21.png new file mode 100644 index 000000000000..d81456e80768 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_21.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_22.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_22.png new file mode 100644 index 000000000000..60525afa183e Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_22.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_23.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_23.png new file mode 100644 index 000000000000..d8b0530a7e1a Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_23.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_24.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_24.png new file mode 100644 index 000000000000..eaa251d35e61 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_24.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_25.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_25.png new file mode 100644 index 000000000000..be348a163cd3 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_25.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_26.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_26.png new file mode 100644 index 000000000000..2a4203cf57db Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_26.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_27.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_27.png new file mode 100644 index 000000000000..7e176be7b796 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_27.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_28.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_28.png new file mode 100644 index 000000000000..a5fe57b7958c Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_28.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_29.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_29.png new file mode 100644 index 000000000000..aa8eeeec230d Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_29.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_3.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_3.png new file mode 100644 index 000000000000..0ed10315a4bf Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_3.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_30.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_30.png new file mode 100644 index 000000000000..8e27fb9f93a8 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_30.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_31.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_31.png new file mode 100644 index 000000000000..519825db7363 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_31.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_32.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_32.png new file mode 100644 index 000000000000..08084658f4f6 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_32.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_33.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_33.png new file mode 100644 index 000000000000..61607efce299 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_33.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_34.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_34.png new file mode 100644 index 000000000000..df843bc00782 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_34.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_35.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_35.png new file mode 100644 index 000000000000..241e1eb2e28e Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_35.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_36.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_36.png new file mode 100644 index 000000000000..d8b0530a7e1a Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_36.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_37.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_37.png new file mode 100644 index 000000000000..9c84ff969da2 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_37.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_38.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_38.png new file mode 100644 index 000000000000..be348a163cd3 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_38.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_39.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_39.png new file mode 100644 index 000000000000..9ac687bd7e84 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_39.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_4.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_4.png new file mode 100644 index 000000000000..8e27fb9f93a8 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_4.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_40.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_40.png new file mode 100644 index 000000000000..9f0a1366dd67 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_40.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_41.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_41.png new file mode 100644 index 000000000000..a5fe57b7958c Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_41.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_42.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_42.png new file mode 100644 index 000000000000..96127eedddec Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_42.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_43.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_43.png new file mode 100644 index 000000000000..db22b381976d Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_43.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_44.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_44.png new file mode 100644 index 000000000000..519825db7363 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_44.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_45.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_45.png new file mode 100644 index 000000000000..2654dc4cc0ee Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_45.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_46.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_46.png new file mode 100644 index 000000000000..9cce4b382461 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_46.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_47.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_47.png new file mode 100644 index 000000000000..df843bc00782 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_47.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_48.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_48.png new file mode 100644 index 000000000000..60525afa183e Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_48.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_49.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_49.png new file mode 100644 index 000000000000..d48cb1ac36bf Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_49.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_5.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_5.png new file mode 100644 index 000000000000..860dc8e27e2d Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_5.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_50.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_50.png new file mode 100644 index 000000000000..daea1cffaf4f Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_50.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_51.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_51.png new file mode 100644 index 000000000000..5bc1aad5a82c Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_51.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_52.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_52.png new file mode 100644 index 000000000000..7e176be7b796 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_52.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_53.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_53.png new file mode 100644 index 000000000000..f899be32f252 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_53.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_54.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_54.png new file mode 100644 index 000000000000..0ed10315a4bf Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_54.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_55.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_55.png new file mode 100644 index 000000000000..8e27fb9f93a8 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_55.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_56.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_56.png new file mode 100644 index 000000000000..860dc8e27e2d Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_56.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_57.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_57.png new file mode 100644 index 000000000000..0698f088ae0b Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_57.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_58.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_58.png new file mode 100644 index 000000000000..61607efce299 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_58.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_59.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_59.png new file mode 100644 index 000000000000..c9ea09a9cbdb Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_59.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_6.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_6.png new file mode 100644 index 000000000000..0698f088ae0b Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_6.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_60.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_60.png new file mode 100644 index 000000000000..4a83494a78e2 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_60.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_61.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_61.png new file mode 100644 index 000000000000..f3f14a0f107d Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_61.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_62.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_62.png new file mode 100644 index 000000000000..d48cb1ac36bf Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_62.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_63.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_63.png new file mode 100644 index 000000000000..43956eaffd04 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_63.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_64.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_64.png new file mode 100644 index 000000000000..9ac687bd7e84 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_64.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_65.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_65.png new file mode 100644 index 000000000000..7e176be7b796 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_65.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_66.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_66.png new file mode 100644 index 000000000000..ed018c6e5787 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_66.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_67.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_67.png new file mode 100644 index 000000000000..96127eedddec Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_67.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_68.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_68.png new file mode 100644 index 000000000000..8e27fb9f93a8 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_68.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_69.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_69.png new file mode 100644 index 000000000000..bfb5296b6ee5 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_69.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_7.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_7.png new file mode 100644 index 000000000000..61607efce299 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_7.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_70.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_70.png new file mode 100644 index 000000000000..2654dc4cc0ee Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_70.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_71.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_71.png new file mode 100644 index 000000000000..61607efce299 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_71.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_72.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_72.png new file mode 100644 index 000000000000..d81456e80768 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_72.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_73.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_73.png new file mode 100644 index 000000000000..e3ce36eae246 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_73.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_74.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_74.png new file mode 100644 index 000000000000..73caa1403d7c Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_74.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_75.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_75.png new file mode 100644 index 000000000000..d48cb1ac36bf Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_75.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_76.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_76.png new file mode 100644 index 000000000000..be348a163cd3 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_76.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_77.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_77.png new file mode 100644 index 000000000000..2a4203cf57db Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_77.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_78.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_78.png new file mode 100644 index 000000000000..7e176be7b796 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_78.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_79.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_79.png new file mode 100644 index 000000000000..a5fe57b7958c Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_79.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_8.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_8.png new file mode 100644 index 000000000000..c9ea09a9cbdb Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_8.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_80.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_80.png new file mode 100644 index 000000000000..aa8eeeec230d Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_80.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_81.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_81.png new file mode 100644 index 000000000000..8e27fb9f93a8 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_81.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_82.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_82.png new file mode 100644 index 000000000000..519825db7363 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_82.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_83.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_83.png new file mode 100644 index 000000000000..08084658f4f6 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_83.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_84.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_84.png new file mode 100644 index 000000000000..61607efce299 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_84.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_85.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_85.png new file mode 100644 index 000000000000..b9e1fe572f9a Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_85.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_86.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_86.png new file mode 100644 index 000000000000..e3ce36eae246 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_86.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_87.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_87.png new file mode 100644 index 000000000000..f3f14a0f107d Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_87.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_88.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_88.png new file mode 100644 index 000000000000..9c84ff969da2 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_88.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_89.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_89.png new file mode 100644 index 000000000000..be348a163cd3 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_89.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_9.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_9.png new file mode 100644 index 000000000000..4a83494a78e2 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_9.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_90.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_90.png new file mode 100644 index 000000000000..9ac687bd7e84 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_90.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_91.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_91.png new file mode 100644 index 000000000000..9f0a1366dd67 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_91.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_92.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_92.png new file mode 100644 index 000000000000..a5fe57b7958c Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_92.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_93.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_93.png new file mode 100644 index 000000000000..96127eedddec Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_93.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_94.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_94.png new file mode 100644 index 000000000000..db22b381976d Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_94.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_95.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_95.png new file mode 100644 index 000000000000..519825db7363 Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_95.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_96.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_96.png new file mode 100644 index 000000000000..2654dc4cc0ee Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_96.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_97.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_97.png new file mode 100644 index 000000000000..e85fa2230ebd Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_97.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_98.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_98.png new file mode 100644 index 000000000000..5bc1aad5a82c Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_98.png differ diff --git a/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_99.png b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_99.png new file mode 100644 index 000000000000..df2d9fe0e87f Binary files /dev/null and b/src/SamplesApp/UITests.Shared/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/When_ShapeVisual_ViewBox_Shape_Combinations_99.png differ diff --git a/src/SamplesApp/UITests.Shared/UITests.Shared.projitems b/src/SamplesApp/UITests.Shared/UITests.Shared.projitems index 693e4d4dd1c4..4384624d9cb0 100644 --- a/src/SamplesApp/UITests.Shared/UITests.Shared.projitems +++ b/src/SamplesApp/UITests.Shared/UITests.Shared.projitems @@ -970,6 +970,10 @@ Designer MSBuild:Compile + + Designer + MSBuild:Compile + Designer MSBuild:Compile @@ -6204,6 +6208,9 @@ Clipping4273.xaml + + ShapeVisualClipping.xaml + Clipping652.xaml @@ -9707,6 +9714,7 @@ + diff --git a/src/SamplesApp/UITests.Shared/Windows_UI_Xaml/Clipping/ShapeVisualClipping.xaml b/src/SamplesApp/UITests.Shared/Windows_UI_Xaml/Clipping/ShapeVisualClipping.xaml new file mode 100644 index 000000000000..323f86b71862 --- /dev/null +++ b/src/SamplesApp/UITests.Shared/Windows_UI_Xaml/Clipping/ShapeVisualClipping.xaml @@ -0,0 +1,16 @@ + + + + + + + + diff --git a/src/SamplesApp/UITests.Shared/Windows_UI_Xaml/Clipping/ShapeVisualClipping.xaml.cs b/src/SamplesApp/UITests.Shared/Windows_UI_Xaml/Clipping/ShapeVisualClipping.xaml.cs new file mode 100644 index 000000000000..f31f41f99fde --- /dev/null +++ b/src/SamplesApp/UITests.Shared/Windows_UI_Xaml/Clipping/ShapeVisualClipping.xaml.cs @@ -0,0 +1,93 @@ +using System; +using System.Collections.Generic; +using System.Numerics; +using Microsoft.UI.Composition; +using Microsoft.UI.Xaml; +using Microsoft.UI.Xaml.Controls; +using Microsoft.UI.Xaml.Hosting; +using Microsoft.UI.Xaml.Media; +using Uno.UI.Samples.Controls; + +namespace UITests.Windows_UI_Xaml.Clipping; + +[Sample] +public sealed partial class ShapeVisualClipping : UserControl +{ + private readonly List _samples = new(); + private int _sampleIndex; + + public ShapeVisualClipping() + { + InitializeComponent(); + + foreach (var shapeVisualSize in (ReadOnlySpan)[20, 40, 80]) + { + foreach (var spriteOffset in (ReadOnlySpan)[-40, -20, 20, 40]) + { + foreach (var viewboxSize in (ReadOnlySpan)[20, 40, 80, 160]) + { + foreach (var viewboxOffset in (ReadOnlySpan)[20, 40, 80]) + { + var element = new Border + { + Height = 40, + Width = 40, + Background = new SolidColorBrush(Microsoft.UI.Colors.Red) + }; + + var elementVisual = ElementCompositionPreview.GetElementVisual(element); + var compositor = elementVisual.Compositor; + var shapeVisual = compositor.CreateShapeVisual(); + + var spriteShape = compositor.CreateSpriteShape(); + spriteShape.Geometry = compositor.CreateRectangleGeometry(); + ((CompositionRectangleGeometry)spriteShape.Geometry).Size = new Vector2(40, 40); + spriteShape.Offset = new Vector2(spriteOffset, spriteOffset); + spriteShape.FillBrush = compositor.CreateColorBrush(Microsoft.UI.Colors.Blue); + shapeVisual.Shapes.Add(spriteShape); + shapeVisual.Size = new Vector2(shapeVisualSize, shapeVisualSize); + shapeVisual.ViewBox = compositor.CreateViewBox(); + shapeVisual.ViewBox.Size = new Vector2(viewboxSize, viewboxSize); + shapeVisual.ViewBox.Offset = new Vector2(viewboxOffset, viewboxOffset); + ((ContainerVisual)elementVisual).Children.InsertAtTop(shapeVisual); + + _samples.Add(new StackPanel + { + VerticalAlignment = VerticalAlignment.Center, + HorizontalAlignment = HorizontalAlignment.Center, + Children = + { + new TextBlock + { + Text = + $""" + Sample [{_samples.Count + 1}] + shapeVisualSize = {shapeVisualSize} + spriteOffset = {spriteOffset} + viewboxSize = {viewboxSize} + viewboxOffset = {viewboxOffset} + """ + }, + element + } + }); + } + } + } + } + + border.Child = _samples[_sampleIndex]; + } + + private void Prev(object sender, RoutedEventArgs e) + { + _sampleIndex = Math.Max(0, _sampleIndex - 1); + border.Child = _samples[_sampleIndex]; + } + + private void Next(object sender, RoutedEventArgs e) + { + _sampleIndex = Math.Min(_samples.Count - 1, _sampleIndex + 1); + border.Child = _samples[_sampleIndex]; + } +} diff --git a/src/Uno.UI.Composition/Composition/BorderVisual.skia.cs b/src/Uno.UI.Composition/Composition/BorderVisual.skia.cs index ff87b806acef..d877fdfd9d8a 100644 --- a/src/Uno.UI.Composition/Composition/BorderVisual.skia.cs +++ b/src/Uno.UI.Composition/Composition/BorderVisual.skia.cs @@ -9,9 +9,9 @@ namespace Microsoft.UI.Composition; /// -/// A ShapeVisual that has a border and a background. +/// A Visual that has a border and a background. /// -internal class BorderVisual(Compositor compositor) : ShapeVisual(compositor) +internal class BorderVisual(Compositor compositor) : ContainerVisual(compositor) { // state set from outside and used inside the class private CornerRadius _cornerRadius; @@ -309,6 +309,6 @@ private static unsafe SKPath CreateBorderPath(SKRect innerArea, SKRect outerArea internal override bool HitTest(Point point) { UpdatePathsAndCornerClip(); - return (_borderShape?.HitTest(point) ?? false) || (_backgroundShape?.HitTest(point) ?? false) || base.HitTest(point); + return (_borderShape?.HitTest(point) ?? false) || (_backgroundShape?.HitTest(point) ?? false); } } diff --git a/src/Uno.UI.Composition/Composition/CompositionViewBox.skia.cs b/src/Uno.UI.Composition/Composition/CompositionViewBox.skia.cs deleted file mode 100644 index 2c4e7f4f71b2..000000000000 --- a/src/Uno.UI.Composition/Composition/CompositionViewBox.skia.cs +++ /dev/null @@ -1,24 +0,0 @@ -#nullable enable -using System; -using System.Linq; -using SkiaSharp; -using Windows.Foundation; - -namespace Microsoft.UI.Composition; - -public partial class CompositionViewBox -{ - /// - /// Layout clipping is usually applied in the element's coordinate space. - /// However, for Panels and ScrollViewer headers specifically, WinUI applies clipping in the parent's coordinate space. - /// So, this flag will be set to true for Panels and ScrollViewer headers, indicating that clipping is in parent's coordinate space. - /// - internal bool IsAncestorClip { get; set; } - - internal SKRect GetSKRect() - => new( - left: Offset.X, - top: Offset.Y, - right: Offset.X + Size.X, - bottom: Offset.Y + Size.Y); -} diff --git a/src/Uno.UI.Composition/Composition/ContainerVisual.skia.cs b/src/Uno.UI.Composition/Composition/ContainerVisual.skia.cs index c35a0ddef225..73f632ca2b8b 100644 --- a/src/Uno.UI.Composition/Composition/ContainerVisual.skia.cs +++ b/src/Uno.UI.Composition/Composition/ContainerVisual.skia.cs @@ -1,6 +1,9 @@ #nullable enable using System.Collections.Generic; using System.Linq; +using System.Numerics; +using Windows.Foundation; +using SkiaSharp; namespace Microsoft.UI.Composition; @@ -9,6 +12,19 @@ public partial class ContainerVisual : Visual private List? _childrenInRenderOrder; private bool _hasCustomRenderOrder; + private (Rect rect, bool isAncestorClip)? _layoutClip; + + /// + /// Layout clipping is usually applied in the element's coordinate space. + /// However, for Panels and ScrollViewer headers specifically, WinUI applies clipping in the parent's coordinate space. + /// So, isAncestorClip will be set to true for Panels and ScrollViewer headers, indicating that clipping is in parent's coordinate space. + /// + internal (Rect rect, bool isAncestorClip)? LayoutClip + { + get => _layoutClip; + set => SetObjectProperty(ref _layoutClip, value); + } + internal bool IsChildrenRenderOrderDirty { get; set; } partial void InitializePartial() @@ -43,6 +59,45 @@ internal void ResetRenderOrder() IsChildrenRenderOrderDirty = false; } + /// This does NOT take the clipping into account. + internal virtual bool HitTest(Point point) => new Rect(0, 0, Size.X, Size.Y).Contains(point); + + /// true if a ViewBox exists + internal bool GetArrangeClipPathInElementCoordinateSpace(SKPath dst) + { + if (LayoutClip is not { isAncestorClip: var isAncestorClip, rect: var rect }) + { + return false; + } + + dst.Rewind(); + var clipRect = rect.ToSKRect(); + dst.AddRect(clipRect); + if (isAncestorClip) + { + Matrix4x4.Invert(TotalMatrix, out var totalMatrixInverted); + var childToParentTransform = Parent!.TotalMatrix * totalMatrixInverted; + if (!childToParentTransform.IsIdentity) + { + dst.Transform(childToParentTransform.ToSKMatrix()); + } + } + + return true; + } + + private protected override void ApplyPrePaintingClipping(in SKCanvas canvas) + { + base.ApplyPrePaintingClipping(in canvas); + using (SkiaHelper.GetTempSKPath(out var prePaintingClipPath)) + { + if (GetArrangeClipPathInElementCoordinateSpace(prePaintingClipPath)) + { + canvas.ClipPath(prePaintingClipPath, antialias: true); + } + } + } + internal override bool SetMatrixDirty() { if (base.SetMatrixDirty()) diff --git a/src/Uno.UI.Composition/Composition/ShapeVisual.cs b/src/Uno.UI.Composition/Composition/ShapeVisual.cs index 814e23341fd5..1e02a3408884 100644 --- a/src/Uno.UI.Composition/Composition/ShapeVisual.cs +++ b/src/Uno.UI.Composition/Composition/ShapeVisual.cs @@ -18,7 +18,7 @@ public CompositionViewBox? ViewBox set => SetProperty(ref _viewBox, value); } - // This is lazy as we are using the `ShapeVisual` for UIElement, but lot of them are not creating shapes, reduce memory pressure. + // This is lazy as we are using the `ShapeVisual` for some UIElements, but lot of them are not creating shapes, reduce memory pressure. public CompositionShapeCollection Shapes { get diff --git a/src/Uno.UI.Composition/Composition/ShapeVisual.skia.cs b/src/Uno.UI.Composition/Composition/ShapeVisual.skia.cs index a0bb43f90f3d..4cd78cdeb23d 100644 --- a/src/Uno.UI.Composition/Composition/ShapeVisual.skia.cs +++ b/src/Uno.UI.Composition/Composition/ShapeVisual.skia.cs @@ -1,67 +1,51 @@ #nullable enable -using System; -using System.Numerics; using Windows.Foundation; using SkiaSharp; -using Uno.UI.Composition; namespace Microsoft.UI.Composition; public partial class ShapeVisual { - private protected override void ApplyPrePaintingClipping(in SKCanvas canvas) - { - base.ApplyPrePaintingClipping(in canvas); - using (SkiaHelper.GetTempSKPath(out var prePaintingClipPath)) - { - if (GetViewBoxPathInElementCoordinateSpace(prePaintingClipPath)) - { - canvas.ClipPath(prePaintingClipPath, antialias: true); - } - } - } - /// internal override void Paint(in PaintingSession session) { - if (_shapes is { Count: not 0 } shapes) + var canvas = session.Canvas; + + if (Size.X == 0 || Size.Y == 0) { - for (var i = 0; i < shapes.Count; i++) - { - shapes[i].Render(in session); - } + return; } - base.Paint(in session); - } + // TODO: ShapeVisuals should be clipping to the size rect. However, this breaks shapes for us because + // we implement them with ShapeVisuals and they don't clip anything. The problem is that + // the WinUI implementation doesn't use ShapeVisuals for shapes, but a combination of ContainerVisuals and + // SpriteVisuals. When_StrokeThickness_Is_GreaterThan_Or_Equals_Width and + // When_Border_CornerRadius_HitTesting fail when you uncomment the following line. + // canvas.ClipRect(new SKRect(0, 0, Size.X, Size.Y)); - /// true if a ViewBox exists - internal bool GetViewBoxPathInElementCoordinateSpace(SKPath dst) - { - if (ViewBox is not { } viewBox) + // TODO: ViewBox.Stretch, ViewBox.HorizontalAlignmentRatio and ViewBox.VerticalAlignmentRatio + if (ViewBox is not null) { - return false; + canvas.Scale( + ViewBox.Size.X > 0 ? Size.X / ViewBox.Size.X : 1, + ViewBox.Size.Y > 0 ? Size.Y / ViewBox.Size.Y : 1); + canvas.Translate(-ViewBox.Offset.X, -ViewBox.Offset.Y); // translate before scaling } - dst.Rewind(); - var clipRect = new SKRect(viewBox.Offset.X, viewBox.Offset.Y, viewBox.Offset.X + viewBox.Size.X, viewBox.Offset.Y + viewBox.Size.Y); - dst.AddRect(clipRect); - if (viewBox.IsAncestorClip) + if (_shapes is { Count: not 0 } shapes) { - Matrix4x4.Invert(TotalMatrix, out var totalMatrixInverted); - var childToParentTransform = Parent!.TotalMatrix * totalMatrixInverted; - if (!childToParentTransform.IsIdentity) + for (var i = 0; i < shapes.Count; i++) { - dst.Transform(childToParentTransform.ToSKMatrix()); + shapes[i].Render(in session); } } - return true; + base.Paint(in session); } /// This does NOT take the clipping into account. - internal virtual bool HitTest(Point point) + internal override bool HitTest(Point point) { if (_shapes is null) { diff --git a/src/Uno.UI.Composition/Composition/SkiaHelper.skia.cs b/src/Uno.UI.Composition/Composition/SkiaHelper.skia.cs index bd650dfc4e61..ad80f7ea120c 100644 --- a/src/Uno.UI.Composition/Composition/SkiaHelper.skia.cs +++ b/src/Uno.UI.Composition/Composition/SkiaHelper.skia.cs @@ -9,8 +9,8 @@ namespace Microsoft.UI.Composition { internal static class SkiaHelper { - private static readonly ObjectPool _paintPool = new(() => new SKPaint(), 8); - private static readonly ObjectPool _pathPool = new(() => new SKPath(), 8); + private static readonly ObjectPool _paintPool = new(() => new SKPaint()); + private static readonly ObjectPool _pathPool = new(() => new SKPath()); public static DisposableStruct GetTempSKPath(out SKPath path) { diff --git a/src/Uno.UI.Composition/Composition/Visual.skia.cs b/src/Uno.UI.Composition/Composition/Visual.skia.cs index 216a801973f0..5d8ef29c59ff 100644 --- a/src/Uno.UI.Composition/Composition/Visual.skia.cs +++ b/src/Uno.UI.Composition/Composition/Visual.skia.cs @@ -299,7 +299,7 @@ private Vector3 GetTotalOffset() private protected virtual void ApplyPrePaintingClipping(in SKCanvas canvas) { // Apply the clipping defined on the element - // (Only the Clip property, clipping applied by parent for layout constraints reason it's managed by the ShapeVisual through the ViewBox) + // (Only the Clip property, clipping applied by parent for layout constraints reason it's managed by the ContainerVisual through the LayoutClip) // Note: The Clip is applied after the transformation matrix, so it's also transformed. Clip?.Apply(canvas, this); } diff --git a/src/Uno.UI.RuntimeTests/Tests/Windows_UI_Composition/Given_ShapeVisual.cs b/src/Uno.UI.RuntimeTests/Tests/Windows_UI_Composition/Given_ShapeVisual.cs new file mode 100644 index 000000000000..efac09bd3a0b --- /dev/null +++ b/src/Uno.UI.RuntimeTests/Tests/Windows_UI_Composition/Given_ShapeVisual.cs @@ -0,0 +1,87 @@ +using System; +using System.Numerics; +using System.Threading.Tasks; +using Microsoft.UI.Composition; +using Microsoft.UI.Xaml.Controls; +using Microsoft.UI.Xaml.Hosting; +using Microsoft.UI.Xaml.Media; +using Uno.UI.RuntimeTests.Helpers; + +namespace Uno.UI.RuntimeTests.Tests.Windows_UI_Composition; + +[TestClass] +[RunsOnUIThread] +public class Given_ShapeVisual +{ +#if __SKIA__ + [RequiresFullWindow] + [TestMethod] + public async Task When_ShapeVisual_ViewBox_Shape_Combinations() + { + // runtime test version of the ShapeVisualClipping sample + + // The reference images are currently not very accurate due to the commented clipping line in ShapeVisual.Paint. + // Restoring that line gives results identical to WinUI. + var counter = 1; + foreach (var shapeVisualSize in (int[])[20, 40, 80]) + { + foreach (var spriteOffset in (int[])[-40, -20, 20, 40]) + { + foreach (var viewboxSize in (int[])[20, 40, 80, 160]) + { + foreach (var viewboxOffset in (int[])[20, 40, 80]) + { + var element = new Border + { + Height = 40, + Width = 40, + Background = new SolidColorBrush(Microsoft.UI.Colors.Red) + }; + + var elementVisual = ElementCompositionPreview.GetElementVisual(element); + var compositor = elementVisual.Compositor; + var shapeVisual = compositor.CreateShapeVisual(); + + var spriteShape = compositor.CreateSpriteShape(); + spriteShape.Geometry = compositor.CreateRectangleGeometry(); + ((CompositionRectangleGeometry)spriteShape.Geometry).Size = new Vector2(40, 40); + spriteShape.Offset = new Vector2(spriteOffset, spriteOffset); + spriteShape.FillBrush = compositor.CreateColorBrush(Microsoft.UI.Colors.Blue); + shapeVisual.Shapes.Add(spriteShape); + shapeVisual.Size = new Vector2(shapeVisualSize, shapeVisualSize); + shapeVisual.ViewBox = compositor.CreateViewBox(); + shapeVisual.ViewBox.Size = new Vector2(viewboxSize, viewboxSize); + shapeVisual.ViewBox.Offset = new Vector2(viewboxOffset, viewboxOffset); + ((ContainerVisual)elementVisual).Children.InsertAtTop(shapeVisual); + + var border = new Border + { + Width = 500, + Height = 500, + Background = new SolidColorBrush(Microsoft.UI.Colors.Green), + Child = element + }; + await UITestHelper.Load(border); + + var screenShot1 = await UITestHelper.ScreenShot(border); + var filename = $"When_ShapeVisual_ViewBox_Shape_Combinations_{counter++}.png"; + // To generate the images + // await screenShot1.Save(filename); + + var referenceImage = new Image + { + Width = 500, + Height = 500, + Source = new Uri($"ms-appx:/Assets/When_ShapeVisual_ViewBox_Shape_Combinations/{filename}") + }; + + await UITestHelper.Load(referenceImage); + var screenShot2 = await UITestHelper.ScreenShot(referenceImage); + await ImageAssert.AreEqualAsync(screenShot1, screenShot2); + } + } + } + } + } +#endif +} diff --git a/src/Uno.UI.RuntimeTests/Tests/Windows_UI_Xaml/Given_UIElement.cs b/src/Uno.UI.RuntimeTests/Tests/Windows_UI_Xaml/Given_UIElement.cs index fa8acc766dd1..ddb0c380ab13 100644 --- a/src/Uno.UI.RuntimeTests/Tests/Windows_UI_Xaml/Given_UIElement.cs +++ b/src/Uno.UI.RuntimeTests/Tests/Windows_UI_Xaml/Given_UIElement.cs @@ -1312,10 +1312,10 @@ public async Task When_Explicit_Size_Clip_Changes() var clip = new Rect(0, 0, 50, 50); sut.ArrangeVisual(rect, clip); - Assert.IsNotNull(sut.Visual.ViewBox); + Assert.IsNotNull(sut.Visual.LayoutClip); sut.ArrangeVisual(rect, null); - Assert.IsNull(sut.Visual.ViewBox); + Assert.IsNull(sut.Visual.LayoutClip); } #endif diff --git a/src/Uno.UI/Helpers/SkiaRenderHelper.skia.cs b/src/Uno.UI/Helpers/SkiaRenderHelper.skia.cs index eb3988b5f6f4..af45096d5f56 100644 --- a/src/Uno.UI/Helpers/SkiaRenderHelper.skia.cs +++ b/src/Uno.UI/Helpers/SkiaRenderHelper.skia.cs @@ -17,7 +17,7 @@ internal static class SkiaRenderHelper /// /// Does a rendering cycle and returns a path that represents the total area that was drawn /// - public static void RenderRootVisualAndClearNativeAreas(int width, int height, ShapeVisual rootVisual, SKSurface surface) + public static void RenderRootVisualAndClearNativeAreas(int width, int height, ContainerVisual rootVisual, SKSurface surface) { var path = RenderRootVisualAndReturnPath(width, height, rootVisual, surface); if (path is { }) @@ -38,7 +38,7 @@ public static void RenderRootVisualAndClearNativeAreas(int width, int height, Sh /// Does a rendering cycle and returns a path that represents the total area that was drawn /// or null if the entire window is drawn. /// - public static SKPath? RenderRootVisualAndReturnPath(int width, int height, ShapeVisual rootVisual, SKSurface surface) + public static SKPath? RenderRootVisualAndReturnPath(int width, int height, ContainerVisual rootVisual, SKSurface surface) { if (!ContentPresenter.HasNativeElements()) { diff --git a/src/Uno.UI/Microsoft/UI/Xaml/Controls/ScrollPresenter/ScrollPresenter.Uno.cs b/src/Uno.UI/Microsoft/UI/Xaml/Controls/ScrollPresenter/ScrollPresenter.Uno.cs index 48ded86c05d9..4c029717ef1b 100644 --- a/src/Uno.UI/Microsoft/UI/Xaml/Controls/ScrollPresenter/ScrollPresenter.Uno.cs +++ b/src/Uno.UI/Microsoft/UI/Xaml/Controls/ScrollPresenter/ScrollPresenter.Uno.cs @@ -20,7 +20,7 @@ partial void InitializePartial() #endif #if UNO_HAS_BORDER_VISUAL - private protected override ShapeVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateBorderVisual(); + private protected override ContainerVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateBorderVisual(); #endif Brush IBorderInfoProvider.Background => Background; diff --git a/src/Uno.UI/UI/Xaml/Controls/Border/Border.cs b/src/Uno.UI/UI/Xaml/Controls/Border/Border.cs index 6f5422ae0d7f..db368da9ffb4 100644 --- a/src/Uno.UI/UI/Xaml/Controls/Border/Border.cs +++ b/src/Uno.UI/UI/Xaml/Controls/Border/Border.cs @@ -55,7 +55,7 @@ public Border() #endif #if UNO_HAS_BORDER_VISUAL - private protected override ShapeVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateBorderVisual(); + private protected override ContainerVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateBorderVisual(); #endif /// diff --git a/src/Uno.UI/UI/Xaml/Controls/CalendarView/CalendarViewBaseItemChrome.uno.cs b/src/Uno.UI/UI/Xaml/Controls/CalendarView/CalendarViewBaseItemChrome.uno.cs index 1b86ca74bf85..c357fe20f29d 100644 --- a/src/Uno.UI/UI/Xaml/Controls/CalendarView/CalendarViewBaseItemChrome.uno.cs +++ b/src/Uno.UI/UI/Xaml/Controls/CalendarView/CalendarViewBaseItemChrome.uno.cs @@ -57,7 +57,7 @@ internal override void OnArrangeVisual(Rect rect, Rect? clip) #endif #if UNO_HAS_BORDER_VISUAL - private protected override ShapeVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateBorderVisual(); + private protected override ContainerVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateBorderVisual(); #endif private void UpdateChromeIfNeeded(Rect rect) diff --git a/src/Uno.UI/UI/Xaml/Controls/ContentPresenter/ContentPresenter.cs b/src/Uno.UI/UI/Xaml/Controls/ContentPresenter/ContentPresenter.cs index e97e77de9573..95db2ec166db 100644 --- a/src/Uno.UI/UI/Xaml/Controls/ContentPresenter/ContentPresenter.cs +++ b/src/Uno.UI/UI/Xaml/Controls/ContentPresenter/ContentPresenter.cs @@ -88,7 +88,7 @@ public ContentPresenter() public BrushTransition BackgroundTransition { get; set; } #if UNO_HAS_BORDER_VISUAL - private protected override ShapeVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateBorderVisual(); + private protected override ContainerVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateBorderVisual(); #endif partial void InitializePlatform(); diff --git a/src/Uno.UI/UI/Xaml/Controls/Image/Image.crossruntime.cs b/src/Uno.UI/UI/Xaml/Controls/Image/Image.crossruntime.cs index f54a168df1c7..efb0bc2638c4 100644 --- a/src/Uno.UI/UI/Xaml/Controls/Image/Image.crossruntime.cs +++ b/src/Uno.UI/UI/Xaml/Controls/Image/Image.crossruntime.cs @@ -10,9 +10,4 @@ partial class Image : FrameworkElement private void OnStretchChanged(Stretch newValue, Stretch oldValue) => InvalidateArrange(); internal override bool IsViewHit() => Source != null || base.IsViewHit(); - -#if !__NETSTD_REFERENCE__ - private protected override Rect? GetClipRect(bool needsClipToSlot, Point visualOffset, Rect finalRect, Size maxSize, Thickness margin) - => base.GetClipRect(needsClipToSlot, visualOffset, finalRect, maxSize, margin) ?? new Rect(default, RenderSize); -#endif } diff --git a/src/Uno.UI/UI/Xaml/Controls/Page/Page.cs b/src/Uno.UI/UI/Xaml/Controls/Page/Page.cs index 43d5874fffa2..6257564fd402 100644 --- a/src/Uno.UI/UI/Xaml/Controls/Page/Page.cs +++ b/src/Uno.UI/UI/Xaml/Controls/Page/Page.cs @@ -22,7 +22,7 @@ public Page() } #if UNO_HAS_BORDER_VISUAL - private protected override ShapeVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateBorderVisual(); + private protected override ContainerVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateBorderVisual(); #endif #if !UNO_HAS_BORDER_VISUAL diff --git a/src/Uno.UI/UI/Xaml/Controls/Panel/Panel.cs b/src/Uno.UI/UI/Xaml/Controls/Panel/Panel.cs index 3c0581f7f71d..706e5e92779e 100644 --- a/src/Uno.UI/UI/Xaml/Controls/Panel/Panel.cs +++ b/src/Uno.UI/UI/Xaml/Controls/Panel/Panel.cs @@ -55,7 +55,7 @@ public Panel() public BrushTransition BackgroundTransition { get; set; } #if UNO_HAS_BORDER_VISUAL - private protected override ShapeVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateBorderVisual(); + private protected override ContainerVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateBorderVisual(); #endif private protected override void OnLoaded() diff --git a/src/Uno.UI/UI/Xaml/FrameworkElement.Layout.crossruntime.cs b/src/Uno.UI/UI/Xaml/FrameworkElement.Layout.crossruntime.cs index 14fb83ac82e8..e5c7d1b244a5 100644 --- a/src/Uno.UI/UI/Xaml/FrameworkElement.Layout.crossruntime.cs +++ b/src/Uno.UI/UI/Xaml/FrameworkElement.Layout.crossruntime.cs @@ -964,7 +964,7 @@ private void ArrangeNative(Point offset, Rect? clippedFrame) #if __SKIA__ // clippedFrame here is the one calculated by FrameworkElement.GetClipRect - // which propagates to ShapeVisual.ViewBox. + // which propagates to ContainerVisual.LayoutClip. // The UIElement.Clip public property isn't considered here on Skia because // it's propagated to Visual.Clip and is set when UIElement.Clip changes. ArrangeVisual(newRect, clippedFrame); diff --git a/src/Uno.UI/UI/Xaml/Media/VisualTreeHelper.cs b/src/Uno.UI/UI/Xaml/Media/VisualTreeHelper.cs index a897299dcd4d..7fabfc05fa15 100644 --- a/src/Uno.UI/UI/Xaml/Media/VisualTreeHelper.cs +++ b/src/Uno.UI/UI/Xaml/Media/VisualTreeHelper.cs @@ -520,7 +520,7 @@ internal static (UIElement? element, Branch? stale) SearchDownForTopMostElementA Rect clippingBounds; using (SkiaHelper.GetTempSKPath(out var viewBoxPath)) { - clippingBounds = element.Visual.GetViewBoxPathInElementCoordinateSpace(viewBoxPath) + clippingBounds = element.Visual.GetArrangeClipPathInElementCoordinateSpace(viewBoxPath) ? transformToElement.Transform(viewBoxPath.TightBounds.ToRect()) : Rect.Infinite; } diff --git a/src/Uno.UI/UI/Xaml/Shapes/Shape.skia.cs b/src/Uno.UI/UI/Xaml/Shapes/Shape.skia.cs index 480ff11e543d..5e9bd556f695 100644 --- a/src/Uno.UI/UI/Xaml/Shapes/Shape.skia.cs +++ b/src/Uno.UI/UI/Xaml/Shapes/Shape.skia.cs @@ -1,20 +1,7 @@ #nullable enable -using System; -using System.Collections.Generic; -using System.Collections.Immutable; -using System.Collections.Specialized; -using System.Globalization; -using System.Linq; -using System.Threading; using Windows.Foundation; -using Microsoft.UI.Xaml.Controls; -using Microsoft.UI.Xaml.Media; -using Uno.Extensions; using Microsoft.UI.Composition; -using Uno.Disposables; -using System.IO.Compression; -using SkiaSharp; using System.Numerics; namespace Microsoft.UI.Xaml.Shapes @@ -35,12 +22,14 @@ public Shape() _shape.Comment = "#path"; #endif - visual.Shapes.Add(_shape); + ((ShapeVisual)visual).Shapes.Add(_shape); } private Rect GetPathBoundingBox(SkiaGeometrySource2D path) => path.Geometry.TightBounds.ToRect(); + private protected override ContainerVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateShapeVisual(); + private protected void Render(Microsoft.UI.Composition.SkiaGeometrySource2D? path, double? scaleX = null, double? scaleY = null, double? renderOriginX = null, double? renderOriginY = null) { if (path is null) diff --git a/src/Uno.UI/UI/Xaml/UIElement.skia.cs b/src/Uno.UI/UI/Xaml/UIElement.skia.cs index a8adcbe674b2..ea5427c5b61d 100644 --- a/src/Uno.UI/UI/Xaml/UIElement.skia.cs +++ b/src/Uno.UI/UI/Xaml/UIElement.skia.cs @@ -33,7 +33,7 @@ namespace Microsoft.UI.Xaml { public partial class UIElement : DependencyObject, IVisualElement, IVisualElement2 { - private protected ShapeVisual _visual; + private protected ContainerVisual _visual; private Rect _lastFinalRect; private Rect? _lastClippedFrame; @@ -76,7 +76,7 @@ private void UpdateOpacity() Visual.Opacity = Visibility == Visibility.Visible ? (float)Opacity : 0; } - internal ShapeVisual Visual + internal ContainerVisual Visual { get { @@ -95,7 +95,7 @@ internal ShapeVisual Visual } } - private protected virtual ShapeVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateShapeVisual(); + private protected virtual ContainerVisual CreateElementVisual() => Compositor.GetSharedCompositor().CreateContainerVisual(); /// The point being tested, in element coordinates (i.e. top-left of element is (0,0) if not RTL) /// This does NOT take the clipping into account. @@ -327,21 +327,15 @@ internal virtual void OnArrangeVisual(Rect rect, Rect? clip) _renderTransform?.UpdateFlowDirectionTransform(); - // The clipping applied by our parent due to layout constraints are pushed to the visual through the ViewBox property - // This allows special handling of this clipping by the compositor (cf. ShapeVisual.Render). + // The clipping applied by our parent due to layout constraints are pushed to the visual through the LayoutClip property + // This allows special handling of this clipping by the compositor (cf. ContainerVisual.Render). if (clip is null) { - visual.ViewBox = null; + visual.LayoutClip = null; } else { - var viewBox = visual.Compositor.CreateViewBox(); - viewBox.IsAncestorClip = ShouldApplyLayoutClipAsAncestorClip(); - - viewBox.Offset = clip.Value.Location.ToVector2(); - viewBox.Size = clip.Value.Size.ToVector2(); - - visual.ViewBox = viewBox; + visual.LayoutClip = (clip.Value, ShouldApplyLayoutClipAsAncestorClip()); } }