xamarin.forms - Xamarin Forms ContentPage background image tiling -


im trying set contentspage backgroundimage on large screened devices image keeps tiling.

does here know how stop images tiling?

edited

here image of whats happening on ipads.

enter image description here

this looks on phone:

enter image description here

mainpage.cs

namespace application.views {     public partial class mainpage : contentpage     {         registerdevice registerdevice;         menuanimations menuanimations;          private double width;          public mainpage()         {             initializecomponent();              registerdevice = new registerdevice();             menuanimations = new menuanimations();              toolbaritems.add(new toolbaritem             {                 icon = "menubtn.png",                 order = toolbaritemorder.primary             });         }          protected override void onsizeallocated(double width, double height)         {               backgroundimage = "bg_portrait.png";         }     } } 

mainpage.xaml

<?xml version="1.0" encoding="utf-8" ?> <contentpage xmlns="http://xamarin.com/schemas/2014/forms"              xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"              x:class="application.views.mainpage">   <contentpage.content>   </contentpage.content> </contentpage> 

in respect backgroundimage property of type string i'm not able use properties of <image>, aspect instance. better in xaml:

<contentpage xmlns="http://xamarin.com/schemas/2014/forms"          xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"          x:class="superforms.samples.page1">   <contentview>     <image source="https://i.stack.imgur.com/ajyco.png"            aspect="aspectfill"/>   </contentview> </contentpage> 

Comments

Popular posts from this blog

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -