Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 75885

Button.Image - Sizing of button to size of image not working in IOS

$
0
0

Really simple problem. Android will properly set the size of the Button to the size of the Image.
iOS does not. Is this a known issue? Setting the LayoutOptions of the Button doesn't change anything either.

        _btnSearch.Image = new Button();
        _btnSearch.Image = ImageSource.FromFile("search.png") as FileImageSource;

        this.Content = new StackLayout
        {
                VerticalOptions = LayoutOptions.FillAndExpand,
                Children =
            {
                    _btnSearch
            }
        };

Viewing all articles
Browse latest Browse all 75885

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>