简体   繁体   中英

Multiple screen support Windows Phone 8

I used to develop for Android and iOS, and for multiple screen support we use to use mdpi, hdpi, xhdpi.

Now I want to develop for Windows Phone, I want to set a background to a button and I don't know how to define image size to support all screen sizes.

You dont need to provide different assets. See info from MSDN below. There is a way to support different assets/resources. But we have never done this bevore in our apps.

From MSDN:

Assets such as graphics, video, audio, and icons make up a large percentage of an app's size. Including assets for all resolutions in your app uses a lot of space in your app. For most apps, we recommend that you include only WXGA assets. WXGA assets have the highest quality, and they automatically scale to work well for other resolutions.

More info: Multi-resolution apps for Windows Phone 8

Multiple resolution handling is built-in with WP8.1. You simply need to name your images with the proper qualifier to ensure it is loaded properly by the device.

You can refer to the tutorial here for more info on how to properly name your image resources:

Quickstart: Using file or image resources

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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