简体   繁体   English

Xamarin形式的可扩展ios初始图像

[英]scalable ios splash image in xamarin forms

I am working with xamarin forms and now I am seting the IOS splash image in the splash.storyboard... I followed some tutorials and I setted "W any x H any" and "generic" in the configurations required...The image appears, it is a background image. 我正在使用xamarin表单,现在我在splash.storyboard中设置IOS启动图像...我遵循了一些教程,并在所需的配置中设置了“ W any x H any”和“ generic” ...图像出现,它是背景图像。 The problems is: If I select the GENERIC option, the image is too large and in the iphone it doesnt seem good...I need a Scalable Splah image, how can I do that? 问题是:如果我选择了“ GENERIC”(通用)选项,则图像太大,而在iphone中似乎效果不佳...我需要可伸缩的Splah图像,该怎么办? I am using windows for it...but I can use a mac too. 我正在使用Windows ...但是我也可以使用Mac。

在此处输入图片说明

You can add an ImageView into the ViewController instead of setting the BackgroundImage of the root view. 您可以将ImageView添加到ViewController中,而不用设置根视图的BackgroundImage。 With this, you can have the flexibility to set constraint according to your needs. 这样,您可以灵活地根据需要设置约束。 You can learn more about auto layout HERE . 您可以在此处了解有关自动布局的更多信息。

In addition, you can also set image with different resolution in iPhone and iPad inside your asset catalog. 此外,您还可以在资产目录中的iPhone和iPad中设置不同分辨率的图像。 在此处输入图片说明

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM