private Android.Views.View ConvertToNative(Context context, IVisualElementRenderer renderer, VisualElement view)
        {
            View nativeView = renderer.View;

            float density = context.Resources.DisplayMetrics.Density;

            double viewWidth = view.Width * density;

            double viewHeight = view.Height * density;

            (_, _, double width, double height) = new Xamarin.Forms.Rectangle(0, 0, viewWidth, viewHeight);

            ViewGroup.LayoutParams layoutParams = new Android.Views.ViewGroup.LayoutParams((int)width, (int)height);

            nativeView.LayoutParameters = layoutParams;

            nativeView.Layout(0, 0, (int)width, (int)height);

            layoutParams.Dispose();

            return(nativeView);
        }