public CompressedGrid CreateAnimation(string buttonText, Color boxColor, CoreTriggerAction animation)
        {
            var box = new BoxView()
            {
                HeightRequest   = 28,
                WidthRequest    = 28,
                BackgroundColor = boxColor
            };

            animation.Animation.Target = box;

            var trigger = new EventTrigger()
            {
                Event   = "Clicked",
                Actions = { animation }
            };

            var btn = new CoreButton()
            {
                Text     = buttonText,
                Style    = CoreStyles.LightOrange,
                Triggers = { trigger }
            };

            var grid = new CompressedGrid();

            grid.AddChild(box, 0, 0);
            grid.AddChild(btn, 0, 1);
            return(grid);
        }
        public CompressedGrid CreateDataTrigger()
        {
            var box = new BoxView()
            {
                HeightRequest   = 28,
                WidthRequest    = 28,
                BackgroundColor = Color.Crimson
            };

            var fadeAnimation = new CoreTriggerAction()
            {
                Animation = new CoreFadeToAnimation()
                {
                    Target   = box,
                    Duration = "300",
                    Opacity  = 0
                }
            };

            var trigger = new DataTrigger(typeof(Button))
            {
                Binding      = new Binding(path: "ClickCount", mode: BindingMode.TwoWay),
                Value        = 3,
                EnterActions = { fadeAnimation }
            };


            var btn = new CoreButton()
            {
                Text     = "Data Trigger (3)",
                Style    = CoreStyles.LightOrange,
                Triggers = { trigger }
            };

            btn.SetBinding(CoreButton.CommandProperty, "ClickEvent");

            var grid = new CompressedGrid();

            grid.AddChild(box, 0, 0);
            grid.AddChild(btn, 0, 1);
            return(grid);
        }
        public FontsCollectionViewCell()
        {
            Height = 75;
            var gd = new CompressedGrid();

            gd.ColumnDefinitions.Add(new ColumnDefinition()
            {
                Width = new GridLength(1, GridUnitType.Star)
            });
            gd.ColumnDefinitions.Add(new ColumnDefinition()
            {
                Width = new GridLength(1, GridUnitType.Star)
            });
            gd.ColumnDefinitions.Add(new ColumnDefinition()
            {
                Width = new GridLength(1, GridUnitType.Star)
            });

            col1 = new FontView()
            {
                VerticalOptions = LayoutOptions.Center
            };
            col2 = new FontView()
            {
                VerticalOptions = LayoutOptions.Center
            };
            col3 = new FontView()
            {
                VerticalOptions = LayoutOptions.Center
            };

            gd.AddChild(col1, 0, 0);
            gd.AddChild(col2, 0, 1);
            gd.AddChild(col3, 0, 2);

            View = gd;
        }