diff --git a/samples/ControlCatalog/Converter/MathSubtractConverter.cs b/samples/ControlCatalog/Converter/MathSubtractConverter.cs new file mode 100644 index 0000000000..009a56c0ec --- /dev/null +++ b/samples/ControlCatalog/Converter/MathSubtractConverter.cs @@ -0,0 +1,18 @@ +using System; +using System.Globalization; +using Avalonia.Data.Converters; + +namespace ControlCatalog.Converter; + +public class MathSubtractConverter : IValueConverter +{ + public object Convert(object value, Type targetType, object parameter, CultureInfo culture) + { + return (double)value - (double)parameter; + } + + public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) + { + throw new NotSupportedException(); + } +} diff --git a/samples/ControlCatalog/MainView.xaml b/samples/ControlCatalog/MainView.xaml index facce2aa82..f3b52428ca 100644 --- a/samples/ControlCatalog/MainView.xaml +++ b/samples/ControlCatalog/MainView.xaml @@ -145,6 +145,9 @@ + + + diff --git a/samples/ControlCatalog/Pages/TransitioningContentControlPage.axaml b/samples/ControlCatalog/Pages/TransitioningContentControlPage.axaml new file mode 100644 index 0000000000..a410577d27 --- /dev/null +++ b/samples/ControlCatalog/Pages/TransitioningContentControlPage.axaml @@ -0,0 +1,82 @@ + + + + + + + + + + + + + 8 + + + + + The TransitioningContentControl control allows you to show a page transition whenever the Content changes. + + + + + + + + + + + + + + + + + + + +